473,385 Members | 1,641 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,385 software developers and data experts.

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

Oct 31 '06 #1
3 1168
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 <js******@swbell.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

Oct 31 '06 #2
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 <js******@swbell.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
Oct 31 '06 #3
On Tue, 31 Oct 2006 23:53:40 GMT, salad <oi*@vinegar.comwrote:
>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 <js******@swbell.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


Nov 1 '06 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

5
by: eagletender | last post by:
I am simply trying to pass a variable to another page. I know my second page can do Request("str") to retrieve that variable, but how do I pass it in the first place? I tried...
24
by: Charles Crume | last post by:
Hello; My "index.htm" page has 3 frames (content, navigation bar, and logo). I set the "SRC" of the "logo" frame to a blank gif image and then want to change it's contents after the other two...
4
by: Chris Beall | last post by:
If you want your code to be bulletproof, do you have to explicitly check for the existence of any possibly-undefined variable? Example: window.outerHeight is defined by some browsers, but not...
2
by: Grzegorz Kaczor | last post by:
Hello, I have an ASP.NET application in my website in virtual folder A. This folder contains the application itself. I also have a data virtual directory B which contains data that can be seen...
3
by: Tor Inge Rislaa | last post by:
How to use a public variable In VB.6.0 I could in the declaration part of a form declare a public variable, then assign a value to the variable, open a new form and address the variable and read...
32
by: deko | last post by:
I have a popup form with a textbox that is bound to a memo field. I've been warned about memo fields so I'm wondering if I should use this code. Is there any risk with changing the form's...
11
by: Miro | last post by:
I am banging my head around something that I think I just dont understand what I am reading in the helps. Its gotta be so simple but I just cant figure out what im reading. ( vb 2003 ) Lets...
2
by: boyleyc | last post by:
Hi all the following code works perfectly well. Basically it populates a series of check boxes on my form, depending on whether dlookup finds an associated record. The problem i have is that...
4
by: Robson Siqueira | last post by:
Folks, I am facing a problem. I am trying to manipulate the HTML data (thru the Document and DocumentText properties) of the WebBrowser object (System.Windows.Forms). The problem is that the...
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
by: ryjfgjl | last post by:
In our work, we often need to import Excel data into databases (such as MySQL, SQL Server, Oracle) for data analysis and processing. Usually, we use database tools like Navicat or the Excel import...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.