I asked why using a variable name in an include statement doesn't work. Jaques and Eric both pointed out that Include statements are executed at compilation time, not when the mbx is run - so a variable name can't be used to build an Include, since it is only 'read' at execution time.
Thanks to them both, and for very speedy responses too Frank -----Original Question----- >Subject: MI-L Include statement > >I'm confused... > >Why does this work: > >Include "C:\Documents and Settings\frank\Application >Data\MapInfo\MapInfo\Professional\700\test.def" > > >but not this, which won't even compile: > >myFile = chr$(34) + "C:\Documents and Settings\frank\Application >Data\MapInfo\MapInfo\Professional\700\test.def" + chr$(34) >Include myFile > > >This doesn't work either: > >myFile = chr$(34) + "C:\Documents and Settings\frank\Application >Data\MapInfo\MapInfo\Professional\700\test.def" + chr$(34) >myCommand = "Include " + myFile >run command myCommand > > >Any comments? All my variables are strings. > >TIA > >Frank --------------------------------------------------------------------- List hosting provided by Directions Magazine | www.directionsmag.com | To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] Message number: 2838
