Drstein99 Posted September 30, 2003 Posted September 30, 2003 I'm porting an application from FoxPro 2.5, to .net 2003. At many points in the application, I'm translating string to variable. For example: esString1 = "BlowFish" esString2 = "esString1" print "string 1: " + esstring1 print "string 2: " + esstring2 print "REFERENCE string2:" + &esstring2 esString1 = "Changed" print "REFERENCE again string2:" + &esstring2 --------- Program Output --------------- string1: BlowFish string2: esString1 REFERENCE string2: BlowFish REFERENCE again string2: Changed ---------------------------------------------- Putting "&" in front of any string will cause the program to access the value of that string instead. Does anybody know how this works in Visual Basic .net? If I'm not being clear, please ask to clairify - thanks. Quote www.DRSTEIN99.com www.RAIDGEAR.net www.THERE.com -> Tell them DrStein99 sent ya!
*Experts* mutant Posted September 30, 2003 *Experts* Posted September 30, 2003 Im not really sure what you are trying to do, both things will print the same thing anyway. You are accessing the value of string, it is the text that is in it. Sorry If im completely misunderstanding you :) Quote
Drstein99 Posted September 30, 2003 Author Posted September 30, 2003 "&" If I put & in front of any string in foxpro, it will translate to the value of the string. NOT the numeric value, but the referenced value. so, if s1 = "examples1", and s2="s1", s1=&s2 Understand? Quote www.DRSTEIN99.com www.RAIDGEAR.net www.THERE.com -> Tell them DrStein99 sent ya!
Drstein99 Posted September 30, 2003 Author Posted September 30, 2003 The functionality I'm looking for is called "macro expansion" Quote www.DRSTEIN99.com www.RAIDGEAR.net www.THERE.com -> Tell them DrStein99 sent ya!
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.