Link to home
Start Free TrialLog in
Avatar of JSW21
JSW21Flag for United States of America

asked on

Dim string * 9

Dim Response As String * 9
Dim Correct As String * 9
Dim Buffer As String * 128

Hi gurus
I want to convert this to this to vb.net, can somebody give some guideline?
Thanks,
ASKER CERTIFIED SOLUTION
Avatar of dqmq
dqmq
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
SOLUTION
Avatar of Anil Golamari
Anil Golamari
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
But, if you really need fixed length strings :>(, then your syntax is fine.  What issue are you having
Avatar of JSW21

ASKER

It said
"missing line break" and "end of statement expected"

SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of JSW21

ASKER

Thanks guys
I followed and added these line to make sure I get what I wanted.

correct = Left(correct, 8)
One consequence of this reimplementation of strings is that VB .NET does not have fixed-length strings, as does VB 6. Thus, the following code is illegal:

Dim Name As String * 30
Note, though, that strings in VB .NET are immutable. That is, although you do not have to declare a string's length in advance, once a value is assigned to a string, its length cannot change. If you change that string, the .NET Common Language Runtime actually gives you a reference to a new String object.

http://ondotnet.com/pub/a/dotnet/excerpt/vbnetnut_appa/index.html?page=2

Good Luck.