Close parent windows from loading url

  1. #1

    Close parent windows from loading url


    Number 1 :

    I've load url to a create window on desktop using this code :
        [DirectMethod(ShowMask = true)]
        public void createwinappme(string idmn, string wtitle, string waction, int wheight, int wwidth)
            Desktop.GetInstance().CreateWindow(new Window
                ID = idmn,
                Height = wheight,
                Width = wwidth,
                Maximizable = false,
                Resizable = false,
                Title = wtitle,
                Icon = Icon.TableGear,
                CloseAction = CloseAction.Destroy,
                Modal = false,
                Layout = "FitLayout",
                Loader = new ComponentLoader
                    Url= waction,
                    Mode = LoadMode.Frame,
                    LoadMask =
                        ShowMask = true
    idmn --> the created windows ID
    waction ---> loading url

    on the waction i've put button to close the windows parent

                            <ext:Button ID="btnClose" runat="server" AutoPostBack="false" Text="Exit" Icon="DoorOpen">
                                    <Click Handler=" " />
    Is there any solution to close parent windows using button on loading url ...???

    Number 2 :

    I've try to hide desktop start button using this code :
       <Ready Handler="Ext.get('ux-taskbar-start').addClass('x-hide-display');" />
    but i've got my desktop blank like below

    Click image for larger version. 

Name:	blank_desktop.png 
Views:	31 
Size:	13.4 KB 
ID:	25360

    Is there any solution to hide start button ... ??

    Thank you ...
  2. #2
    Hi. For your first question, can you create simplified sample that demonstrates how we can reproduce the scenario locally?

    Tips for creating simplified code samples:

    Please start a new forum thread for your second unrelated question.
    Geoffrey McGill
  3. #3

    re : Close parent windows from loading url

    Hello, Geoffrey ...
    Thank you ...

    For Number 1 question , I've already search on forum and below the function to close
            var closeWKIBA = function () {
                if (App.e_kdsensus.getValue() == '1')
                    window.parent.App.mnsKIBA.close();   /*this make window parent close*/
                    window.parent.App.mnKIBA.close();    /*this make window parent close*/
    and for the 'closeButton'

                            <ext:Button ID="btnClose" runat="server" Text="Exit" Icon="DoorOpen" >
                                    <Click Handler="closeWKIBA();" />
    with mnsKIBA and mnKIBA as a parent window

    You can close number 1 question

    and for the number 2 question I'll create new thread

    Thank you ....

Similar Threads

  1. [CLOSED] Close windows on click in UserControl loaded dynamically
    By Mario in forum 2.x Legacy Premium Help
    Replies: 7
    Last Post: Dec 16, 2014, 10:54 AM
  2. [CLOSED] Loading windows' IFRAME url BEFORE showing window..
    By rthiney in forum 2.x Legacy Premium Help
    Replies: 1
    Last Post: Mar 14, 2014, 4:05 AM
  3. How to close windows from a child iFrame button?
    By metallica87 in forum 2.x Help
    Replies: 2
    Last Post: Nov 14, 2012, 4:30 AM
  4. Replies: 0
    Last Post: Jan 08, 2009, 11:31 AM
    By wkcode in forum 1.x Help
    Replies: 1
    Last Post: Oct 14, 2008, 12:45 PM

Posting Permissions