RSS Forums RSS
Please support our ASP.NET advertiser: Lunarpages ASP Web Hosting
Views: 8619 | Replies: 1
Reply
Join Date: Sep 2004
Posts: 7
Reputation: jchamel is an unknown quantity at this point 
Rep Power: 0
Solved Threads: 0
jchamel's Avatar
jchamel jchamel is offline Offline
Newbie Poster

can't concatenate variables and add text

  #1  
Oct 4th, 2004
The first part of my asp file is working, but I have to concatenate the variables and add text to read this. My name is Joe Blow. I live at 123 easy street in Pine Bluff, AR 71601. My phone number is (870) 123-4567 and my Email address is jblow@seark.edu. I do not know where to put what. I think I have part of it figured out and I am using the book Beginning Active Server Pages 3.0. Can someone take a look at this soon. It is due tonight by midnight. I think I almost have it but do not know how to make a space. The book says to do this & " " . But if you load it on the server it doesn't have the space. I need to add the address, phone and email to this also to concatenate the rest of the variables.
Thanks for your help.
Ok here is my file.

<%Option Explicit%>


<html>
<head>
<title> Five variables</title>
</head>
<body bgcolor="ffffcc">

<%
Dim strfullname, straddress, strcitystatezip, strphone,

strEmail
strfullname = ("Joe Blow")
straddress = ("123 Easy Street")
strcitystatezip = ("Pine Bluff, Arkansas 71601")
strphone = ("(870) 123-4567")
strphone = ("jblow@seark.edu")

Response.write "<br>"
Response.write strfullname
Response.write "<br>"
Response.write straddress
Response.write "<br>"
Response.write strcitystatezip
Response.write "<br>"
Response.write strphone
Response.write "<br>"
Response.write strEmail
Response.write "<br>"
Response.write("My name is" & " " & strfullname )
%>


</body>
</html>
AddThis Social Bookmark Button
Reply With Quote  
Join Date: Oct 2004
Posts: 15
Reputation: clartsonly is an unknown quantity at this point 
Rep Power: 5
Solved Threads: 0
clartsonly clartsonly is offline Offline
Newbie Poster

Re: can't concatenate variables and add text

  #2  
Oct 4th, 2004
Response.write "<br>"
Response.write strfullname
Response.write "<br>"
Response.write straddress
Response.write "<br>"
Response.write strcitystatezip
Response.write "<br>"
Response.write strphone
Response.write "<br>"
Response.write strEmail
Response.write "<br>"
Response.write("My name is" & " " & strfullname )

yeah thats right in simple terms (again not sure about the use of brackets, it is not a function response.write is a procedure)

mMessage = "My Name is " & strFullname & " I Live at " & straddress & " in " & strcitystatezip etc etc....

response.write mMessage

strEmail
strfullname = ("Joe Blow")
straddress = ("123 Easy Street")
strcitystatezip = ("Pine Bluff, Arkansas 71601")
strphone = ("(870) 123-4567")
strphone = ("jblow@seark.edu")

although that looks a bit messy you are not even defining strEmail, and I have never used brackets.

strEmail = "joe@blow.com"
strfullname = "Joe Blow"
straddress = "123 Easy Street"
strcitystatezip = "Pine Bluff, Arkansas 71601"
strphone = "(870) 123-4567"
strphone = "jblow@seark.edu"
Reply With Quote  
Reply

Only community members can participate in forum threads. You must register or log in to contribute.

Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)

 

Thread Tools Display Modes
Forums | Blogs | Tutorials | Code Snippets | Whitepapers | RSS Feeds | Advertising
All times are GMT -4. The time now is 2:58 pm.
Newsletter Archive - Sitemap - Privacy Statement - Acceptable Use Policy - Contact Us
Forum system based on vBulletin Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
©2003 - 2008 DaniWeb® LLC