Indigo Rose Software

Professional Software Development Tools

 
+ Reply to Thread
Results 1 to 2 of 2
  1. #1
    Join Date
    Dec 2006
    Location
    Colombia
    Posts
    62

    Help with the creation of an object and respond to the option On Click

    I think this OBJECT_BUTTON of the form:
    tblButtonPos = {};
    tblButtonPos.Opacity = 75;
    tblButtonPos.Left = 300;
    tblButtonPos.Top = 15;
    tblButtonPos.GetState = BTN_UP;
    tblButtonPos.Enabled = true;
    tblButtonPos.Visible = true;
    tblButtonPos.X = 160;
    tblButtonPos.Y = 20;
    tblButtonPos.Width = 500;
    tblButtonPos.Height = 25;
    tblButtonPos.Cursor = HAND;

    for n=1, 4 do
    -- Create the 4 object Button
    Page.CreateObject(OBJECT_BUTTON, "XPBarButton"..n, tblButtonPos);

    end

    I can I respond to the following code?:


    if Button.GetState("XPBarButton"..n) == BTN_DOWN then
    SetGroupVisible("grp"..n, true)
    else
    SetGroupVisible("grp"..n, false)
    end

    ---I would be very grateful for their collaboration

  2. #2
    Join Date
    Jul 2002
    Location
    Just South of Reality
    Posts
    778
    homes

    You probably want to use the Page.SetObjectScript(ObjectName, EventName, Script) for each object right after creating the buttons. That could set the OnClick event for the buttons...

    I hope that's what you're looking for...

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts