Indigo Rose Software

Professional Software Development Tools

 
Results 1 to 6 of 6
  1. #1
    Join Date
    Sep 2004
    Posts
    9

    Having Button Text Stay A Certain Color

    I'm creating a walk-though of certain features of our program. I have several buttons on the left side of the window. Once a user has clicked on a button, I want the text on a button to remain a different color to show the user he has already reviewed the text or activities on that particular button.

    I've changed the style on the button to be toggle - up. I've also entered the command Button.SetState("ToggleButton1", BTN_DOWN); on the click, enter, and leave tabs. ("ToggleButton1" was changed to match the object.)

    When I click the first button it turns the color I want, but when I click the second button, all button return to their original color. When I click back to the first button, the buttons then turn to the color I expected.

    Help. Am I using the correct command?

  2. #2
    Join Date
    Aug 2003
    Posts
    2,427
    You can do this by setting a variable and then using it to set the button state in the On Enter and On Leave events like this -

  3. #3
    Join Date
    Sep 2004
    Posts
    9

    Something still wrong.

    I appreciate your direction. Followed your instructions but I'm still getting sporadic results. Want to take a look at my file and see if you can see anything?

    Yours worked great!

    ----------------

    I'll have to keep working on this. I see this file did not come across as I expected.
    Last edited by webnc1; 10-04-2004 at 10:08 AM. Reason: Oops. I see the file did not come across as I intended.

  4. #4
    Join Date
    Sep 2004
    Posts
    9

    Update

    It appears the text does not want to stay as BTN_DOWN as you move from page to page. If I have 12 different pages, doesn't the command have to be on the ENTER and LEAVE tab on every button?

    Hope someone can point me in the right direction.

    if (clicked1==1) then Button.SetState("Button1", BTN_DOWN) end
    if (clicked2==1) then Button.SetState("Button2", BTN_DOWN) end
    if (clicked3==1) then Button.SetState("Button3", BTN_DOWN) end
    if (clicked4==1) then Button.SetState("Button4", BTN_DOWN) end
    if (clicked5==1) then Button.SetState("Button5", BTN_DOWN) end
    if (clicked6==1) then Button.SetState("Button6", BTN_DOWN) end
    if (clicked7==1) then Button.SetState("Button7", BTN_DOWN) end
    if (clicked8==1) then Button.SetState("Button8", BTN_DOWN) end
    if (clicked9==1) then Button.SetState("Button9", BTN_DOWN) end
    if (clicked10==1) then Button.SetState("Button10", BTN_DOWN) end
    if (clicked11==1) then Button.SetState("Button11", BTN_DOWN) end
    if (clicked12==1) then Button.SetState("Button12", BTN_DOWN) end

  5. #5
    Join Date
    Jun 2002
    Location
    Israel
    Posts
    1,843
    In your case, I would suggest you to use images instead of button objects. It may be more preparation work, but at the end of the day, you can pretty much do anything visual design wise for the images. Just have images for each state and use Image.Load action to load the relevant image into your object. You could also set a label text on top of a fixed image, have a different opacity, use a shape pluging object semi transparent on top of your image, use a flash object...anything really.
    Good luck
    Yossi

  6. #6
    Join Date
    Aug 2003
    Posts
    2,427
    Quote Originally Posted by webnc1
    If I have 12 different pages, doesn't the command have to be on the ENTER and LEAVE tab on every button?
    You only need to design the global parts of a page once.

    If the buttons on all the pages each link to the same target which presumably they must do, you can use the Page Inherit Objects in the properties inspector. Or just do a page duplicate.

    The variable is global.

Similar Threads

  1. Noob ? for toggling text on a button
    By Robfr in forum AutoPlay Media Studio 5.0
    Replies: 4
    Last Post: 06-04-2005, 02:39 PM
  2. Example: Loading Paragraph Text Using a Timer
    By Jonas DK in forum AutoPlay Media Studio 5.0 Examples
    Replies: 7
    Last Post: 11-25-2004, 05:10 PM
  3. Example: Creating an on/off button to toggle background audio
    By Jonas DK in forum AutoPlay Media Studio 5.0 Examples
    Replies: 0
    Last Post: 07-10-2004, 02:54 PM
  4. Button with text
    By big0gie in forum AutoPlay Media Studio 5.0
    Replies: 1
    Last Post: 02-09-2004, 11:53 AM
  5. How I can opy text from button or other text
    By PWRoot in forum AutoPlay Media Studio 4.0
    Replies: 2
    Last Post: 10-08-2003, 12:00 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