SPONSORS:






User Tag List

Thanks Thanks:  0
Likes Likes:  0
Dislikes Dislikes:  0
Results 1 to 2 of 2
  1. #1
    Member
    Join Date
    Apr 2005
    Posts
    84
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Total Downloaded
    0

    Getting attached text from value in WebRadioGroup

    For a test that I'm working on, webradiogroups use dynamic values and the attached text for each selection does not usually match the submitted value (select 'Males only' option and the 'submit' button passes 'M', etc).

    I've gotten all of the values from the radiogroup based on the code presented in another thread... but aside from running a for/next loop to determine the attached text (based on the 'selected item index' value), I can't seem to figure out a faster way to directly determine the attached text for the selected value. I'm hoping that someone has an idea that will make my code run a little faster.

    What I'm looking for is a way to directly determine the attached text of the selection so that I can build a reusable function to pass a text string to the function and check that the text passed is the selected value.

    Any assistance would be greatly appreciated.

  2. #2
    Senior Member
    Join Date
    Sep 2006
    Location
    CA, USA
    Posts
    425
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Total Downloaded
    0

    Re: Getting attached text from value in WebRadioGroup

    Use dictionary to make text and value a pair:
    Set d = CreateObject("Scripting.Dictionary")
    d.Add "M", "Males only" ' Add some keys and items.



    or use 2 arrays
    arrText ("M", "F", "B")
    arrValue ("Males only", "Females only", "Both")

 

 

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Search Engine Optimisation provided by DragonByte SEO v2.0.36 (Pro) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
Resources saved on this page: MySQL 11.54%
vBulletin Optimisation provided by vB Optimise v2.6.4 (Pro) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
User Alert System provided by Advanced User Tagging v3.2.8 (Pro) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
vBNominate (Lite) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
Feedback Buttons provided by Advanced Post Thanks / Like (Pro) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
Username Changing provided by Username Change (Free) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
BetaSoft Inc.
Digital Point modules: Sphinx-based search
All times are GMT -8. The time now is 07:01 PM.

Copyright BetaSoft Inc.