Indigo Rose Software

Professional Software Development Tools

 
Results 1 to 2 of 2
  1. #1
    Join Date
    Oct 2005
    Posts
    16

    Page.CreateObject COMBOBOX

    I've created a combobox with code:

    tblComboProps = {};
    tblComboProps.FontName = "Arial";
    tblComboProps.FontSize = 12;
    tblComboProps.FontItalic = false;
    tblComboProps.FontStrikeout = false;
    tblComboProps.FontAntiAlias = true;
    tblComboProps.FontWeight = FW_NORMAL;
    tblComboProps.FontUnderline = false;
    tblComboProps.FontScript = ANSI_CHARSET;
    tblComboProps.TextColor = Math.HexColorToNumber("000000");
    tblComboProps.ComboStyle = DROPDOWN_LIST;
    tblComboProps.LinesToDisplay = 4;
    tblComboProps.Sort = false;
    tblComboProps.BackgroundColor = Math.HexColorToNumber("FFFFFF");
    tblComboProps.Enabled = true;
    tblComboProps.Visible = true;
    tblComboProps.Width = 200;
    tblComboProps.Height = 26;
    tblComboProps.Y = 220;
    tblComboProps.X = 220;
    tblComboProps.TooltipText = "";

    Page.CreateObject(OBJECT_COMBOBOX, "ComboBox_Object", tblComboProps);

    how can I continue this code for adding items and actions to those items too ?
    an example will help....
    thank you

  2. #2
    Join Date
    Oct 2005
    Posts
    16
    I discovered the answer:

    tblComboProps = {};
    tblComboProps.FontName = "Arial";
    tblComboProps.FontSize = 12;
    tblComboProps.FontItalic = false;
    tblComboProps.FontStrikeout = false;
    tblComboProps.FontAntiAlias = true;
    tblComboProps.FontWeight = FW_NORMAL;
    tblComboProps.FontUnderline = false;
    tblComboProps.FontScript = ANSI_CHARSET;
    tblComboProps.TextColor = Math.HexColorToNumber("000000");
    tblComboProps.ComboStyle = DROPDOWN_LIST;
    tblComboProps.LinesToDisplay = 3;
    tblComboProps.Sort = false;
    tblComboProps.BackgroundColor = Math.HexColorToNumber("FFFFFF");
    tblComboProps.Enabled = true;
    tblComboProps.Visible = true;
    tblComboProps.Width = 200;
    tblComboProps.Height = 26;
    tblComboProps.Y = 220;
    tblComboProps.X = 220;
    tblComboProps.TooltipText = "";

    Page.CreateObject(OBJECT_COMBOBOX, "ComboBox_Object", tblComboProps);

    ComboBox.AddItem("ComboBox_Object", "Arata1", "");
    ComboBox.AddItem("ComboBox_Object", "Arata2", "");

    selected_index = ComboBox.GetSelected("ComboBox_Object");

    if (selected_index == 1) then
    Dialog.Message("Selected Index","The currently selected item has an index of "..selected_index, MB_OK, MB_ICONEXCLAMATION, MB_DEFBUTTON1);
    else
    etc......

Similar Threads

  1. Not understanding ComboBox very well
    By RodB in forum AutoPlay Media Studio 6.0
    Replies: 28
    Last Post: 04-16-2007, 09:00 AM
  2. Need ComboBox To Update Image Object
    By octane6228 in forum AutoPlay Media Studio 5.0
    Replies: 2
    Last Post: 09-21-2006, 12:10 AM
  3. ComboBox Reset
    By azmanar in forum AutoPlay Media Studio 6.0
    Replies: 2
    Last Post: 12-29-2005, 12:46 PM
  4. ComboBox problem
    By andrewr in forum AutoPlay Media Studio 5.0
    Replies: 5
    Last Post: 05-06-2005, 09:49 AM
  5. ComboBox display current
    By pjhiggins in forum AutoPlay Media Studio 5.0
    Replies: 4
    Last Post: 05-21-2004, 12:14 PM

Posting Permissions

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