Hey I'm a Newb and i do software at school, im currently working on a vb 6.0 remote connection program. I need to change the length of a string at runtime, i'v already looked at redim for arrays, or using another string but i cant dimesion it with a variable.
Example i need to do this
Expand|Select|Wrap|Line Numbers
dim a as string * variable
or to some how redim.
any help with this or an alternate method would be much appreciated thanks.
Hey I'm a Newb and i do software at school, im currently working on a vb 6.0 remote connection program. I need to change the length of a string at runtime, i'v already looked at redim for arrays, or using another string but i cant dimesion it with a variable.
Example i need to do this
Expand|Select|Wrap|Line Numbers
dim a as string * variable
or to some how redim.
any help with this or an alternate method would be much appreciated thanks.
Hello, chezz!
If you have not already searched here, I would suggest you do. Answers to this have been already added.
I think it's fair to say that if you define a fixed-length string in VB, the length is fixed - hence the name. Hint: this is not the only type of string.
Hey i know that you can leave string undemensioned but im using a specific algorithm (mid$ function) to strip excess spaces out of a string. But don't worry i figured out a way around it. Thx anyway
One thing to keep in mind. I'm pretty sure Mid$() function doesn't mind if you go beyond the end of a variable-length string - it just doesn't return anything. So you don't need to worry about crashing because you overran the end, or anything.
In any case, I'm guessing the Len() function is probably your saviour.