changing all the variable links on forms

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • sparks

    changing all the variable links on forms

    We have a database with 152 variables.
    Now they want to change this and add 8 new variables

    they have them on seperate forms (thats ok)
    the variables are named Q1something thru Q152something
    they are inserting Q25-Q31 so now we will have to change the table
    variables to go from Q1something to Q160 something..

    so how can I parse out the numbers after the Q so I can find out
    the length of the number

    The only thing I can't understand is parsing thru this string how I
    can tell if its a number or text.

    pos = 0
    Num = mid(fld.name, pos + 1,numbercount)

    something like this maybe if I can figure out how to count numbers
    imbedded in the string



  • sparks

    #2
    Re: changing all the variable links on forms

    DOH never mind I can just use ascii values.....man I feel stupid
    (FEEL??) lol



    On Tue, 31 Oct 2006 19:17:05 GMT, sparks <jstalnak@swbel l.netwrote:
    >We have a database with 152 variables.
    >Now they want to change this and add 8 new variables
    >
    >they have them on seperate forms (thats ok)
    >the variables are named Q1something thru Q152something
    >they are inserting Q25-Q31 so now we will have to change the table
    >variables to go from Q1something to Q160 something..
    >
    >so how can I parse out the numbers after the Q so I can find out
    >the length of the number
    >
    >The only thing I can't understand is parsing thru this string how I
    >can tell if its a number or text.
    >
    >pos = 0
    >Num = mid(fld.name, pos + 1,numbercount)
    >
    >something like this maybe if I can figure out how to count numbers
    >imbedded in the string
    >
    >

    Comment

    • salad

      #3
      Re: changing all the variable links on forms

      sparks wrote:
      DOH never mind I can just use ascii values.....man I feel stupid
      (FEEL??) lol
      >
      >
      >
      On Tue, 31 Oct 2006 19:17:05 GMT, sparks <jstalnak@swbel l.netwrote:
      >
      >
      >>We have a database with 152 variables.
      >>Now they want to change this and add 8 new variables
      >>
      >>they have them on seperate forms (thats ok)
      >>the variables are named Q1something thru Q152something
      >>they are inserting Q25-Q31 so now we will have to change the table
      >>variables to go from Q1something to Q160 something..
      >>
      >>so how can I parse out the numbers after the Q so I can find out
      >>the length of the number
      >>
      >>The only thing I can't understand is parsing thru this string how I
      >>can tell if its a number or text.
      >>
      >>pos = 0
      >>Num = mid(fld.name, pos + 1,numbercount)
      >>
      >>something like this maybe if I can figure out how to count numbers
      >>imbedded in the string
      >>
      >>
      >
      >
      There's Left, Right, and Mid.
      left(Field,1) = "Q"
      Right(Field,Len (Field)-1) = number
      Mid(Field,2) = Number

      Comment

      • sparks

        #4
        Re: changing all the variable links on forms

        On Tue, 31 Oct 2006 23:53:40 GMT, salad <oil@vinegar.co mwrote:
        >sparks wrote:
        >DOH never mind I can just use ascii values.....man I feel stupid
        >(FEEL??) lol
        >>
        >>
        >>
        >On Tue, 31 Oct 2006 19:17:05 GMT, sparks <jstalnak@swbel l.netwrote:
        >>
        >>
        >>>We have a database with 152 variables.
        >>>Now they want to change this and add 8 new variables
        >>>
        >>>they have them on seperate forms (thats ok)
        >>>the variables are named Q1something thru Q152something
        >>>they are inserting Q25-Q31 so now we will have to change the table
        >>>variables to go from Q1something to Q160 something..
        >>>
        >>>so how can I parse out the numbers after the Q so I can find out
        >>>the length of the number
        >>>
        >>>The only thing I can't understand is parsing thru this string how I
        >>>can tell if its a number or text.
        >>>
        >>>pos = 0
        >>>Num = mid(fld.name, pos + 1,numbercount)
        >>>
        >>>something like this maybe if I can figure out how to count numbers
        >>>imbedded in the string
        >>>
        >>>
        >>
        >>
        >There's Left, Right, and Mid.
        > left(Field,1) = "Q"
        > Right(Field,Len (Field)-1) = number
        > Mid(Field,2) = Number
        yes but you don't know the length of the number till you count it.

        and I went ahead and made it so in the future it would check for stuff
        like ABC123defg

        I just didn't like to break out if i ran out of letters and started
        finding numbers but could think of no other way






        Comment

        Working...