How to use the TaskManager control of the Visible Properties Button

  1. #1

    How to use the TaskManager control of the Visible Properties Button

    How to use the TaskManager control of the Visible Properties Button?

    this is My Code:
    <ext:Button ID="btnJATS" runat="server" Text="Please Click" Icon="Accept" Visible="false">
        <AjaxEvents>
            <Click OnEvent="btnJATS_Click" >
                <EventMask ShowMask="true" Msg="361°..." />
            </Click>
        </AjaxEvents>
    </ext:Button>
    
    <ext:TaskManager ID="TaskManager1" runat="server">
        <Tasks>
            <ext:Task TaskID="UpCenter" Interval="6000">
                <AjaxEvents>
                    <Update OnEvent="RefreshCenter">
                    </Update>
                </AjaxEvents>
            </ext:Task>
        </Tasks>
    </ext:TaskManager>
    
    protected void RefreshCenter(object sender, AjaxEventArgs e)
    {
        string Isok = getIsok();
        if (Isok == "ok")
        {
            btnJATS.Visible = true;
        }
        else
        {
            btnJATS.Visible = false;
        }
    }








    </PRE></PRE>
  2. #2

    RE: How to use the TaskManager control of the Visible Properties Button

    Hi wkcode,

    You should only have to change the .Visible property to .Hidden.

    Then you can tighten up your event handler as well.

    Example

    protected void RefreshCenter(object sender, AjaxEventArgs e)
    {
        btnJATS.Hidden = !(getIsok() == "ok");
    }
    Hope this helps.

    Geoffrey McGill
    Founder

Similar Threads

  1. Replies: 2
    Last Post: Aug 10, 2010, 4:27 PM
  2. [CLOSED] How to use the taskmanager control
    By alexkay in forum 1.x Legacy Premium Help
    Replies: 3
    Last Post: Jun 14, 2010, 3:56 PM
  3. Replies: 1
    Last Post: Oct 30, 2009, 3:21 PM
  4. Properties: Visible vs Hidden
    By tnwheeler in forum 1.x Help
    Replies: 2
    Last Post: Sep 23, 2009, 12:23 PM
  5. Set button visible to false
    By glenh in forum 1.x Help
    Replies: 2
    Last Post: Aug 24, 2009, 10:44 AM

Posting Permissions