Get Help:Ask a Question in our Forums|Report a Bug|More Help Resources
Last post May 23, 2012 01:29 PM by bbcompent1
May 23, 2012 01:22 PM|LINK
The .inc files are coded with VBScript for asp page. Now we have to convert those asp pages to aspx, at the same time, i have to change the VBScript code to C# code in .inc file.
How could i do this one?
pls help me
May 23, 2012 01:29 PM|LINK
Ok, what you do in asp.net in this case is you rewrite your .inc files as .cs after converting your vbscript functions over to c#. Then, when you call from your aspx code behind page, you put your converted code inside a class wrapper. When you need that
function, you call the class from code behind:
// say you name your code file oldcode and make the class named oldcode, you do it like this:
Using is in this case the include command commonly seen in vbscript. However, the file must be in true C# or you could have errors so test relentlessly.