Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

<b>How do you declare variables in one line?</b>

Status
Not open for further replies.

jonathanx

Programmer
Jul 10, 2001
27
US
Hello,

I simply want to know how to declare variables in one line instead of using 2 like so:
<%
Dim Name
Name=&quot;Dave&quot;
%>

I have seen stuff somewhat like this:
<%
Dim Name As String &quot;Dave&quot;
%>

But I'm sure that, that is not correct.

I would appreciate any explanation or just a posting of a brief code declaring Strings and Integers. I thank you in advanced.

Regards,

Jonathan
 
Unfortunately, you'll have to use ASP.Net to accomplish what you want. This version of asp allows you declare variables of certain datatypes while regular asp just allows you to declare variants.

In asp.net you're could be:

Dim Name As String = &quot;Dave&quot;

Jeff
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top