ASP Pro Code ClinicAs of Oct 5, 2005, this forum is now locked. No posts have been deleted. Please use "Classic ASP Professional" at: http://p2p.wrox.com/forum.asp?FORUM_ID=56 for discussions similar to the old ASP Pro Code Clinic or one of the other many remaining ASP and ASP.NET forums here.
Welcome to the p2p.wrox.com Forums.
You are currently viewing the ASP Pro Code Clinic section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
Dear All,
I've got a Constant defined as a base URL, and am trying to use that in conjunction with some filenames to create other constants as follows :
For some reason I get an error on the second line, even though I am using a Constant and not a Variable to create the second Constant. Has anyone got a workaround to this, apart from using Variables for NewImg ?
This is one of the things that bugs me about VBScript. Basically I don't think that there is a workaround other than using variables. Of course if anyone knows of one I am very keen to hear about it.
The way I read it is that VBScript demands that constants are not made up of other constants. In other words the compiler is too lazy to check if the word you included as part of the constant is actually a constant rather than a variable or function.
This really bugs me, particularly when you compare it to the kind of stuff you can do in C and C++ with #define.