compose variables

Discussion in 'ASP General' started by Jochen Scheire, Oct 13, 2004.

  1. Hello,

    I have a list with a lot of variables. The variables all start with
    Langstring, followed by a number.

    Langstring1 = "text1"
    Langstring2 = "text2"...

    I have a database with only numbers in it. Now I want to use these
    variables in a dropdown box as selected item. Is it possible to compose
    variables out of two parts?

    I tried response.write(Taalstr&RSItems("Testfield"))

    It gave me Langstring1 because the number in the field was one. I want
    it to return 'text1'. Is it possible?

    *** Sent via Developersdex http://www.developersdex.com ***
    Don't just participate in USENET...get rewarded for it!
    Jochen Scheire, Oct 13, 2004
    #1
    1. Advertising

  2. Well, while it is possible if you use something like the Eval function, but
    I personally incredibly rarely ever find this to be a good idea. Have you
    considered using an array perhaps?

    Ray at work



    "Jochen Scheire" <> wrote in message
    news:%...
    > Hello,
    >
    > I have a list with a lot of variables. The variables all start with
    > Langstring, followed by a number.
    >
    > Langstring1 = "text1"
    > Langstring2 = "text2"...
    >
    > I have a database with only numbers in it. Now I want to use these
    > variables in a dropdown box as selected item. Is it possible to compose
    > variables out of two parts?
    >
    > I tried response.write(Taalstr&RSItems("Testfield"))
    >
    > It gave me Langstring1 because the number in the field was one. I want
    > it to return 'text1'. Is it possible?
    >
    > *** Sent via Developersdex http://www.developersdex.com ***
    > Don't just participate in USENET...get rewarded for it!
    Ray Costanzo [MVP], Oct 13, 2004
    #2
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. [XaToA]

    compose date

    [XaToA], Aug 8, 2003, in forum: Java
    Replies:
    1
    Views:
    408
    Roedy Green
    Aug 8, 2003
  2. Replies:
    2
    Views:
    1,628
    Adrienne Boswell
    Jul 28, 2006
  3. DaVinci

    how to compose the two expression to one?

    DaVinci, Apr 6, 2006, in forum: C Programming
    Replies:
    4
    Views:
    321
    Duncan Muirhead
    Apr 6, 2006
  4. aspineux
    Replies:
    0
    Views:
    232
    aspineux
    Sep 16, 2011
  5. Replies:
    0
    Views:
    78
Loading...

Share This Page