OutFront Forums
     Home    Register     Search      Help      Login    

Follow Us
On Facebook
On Twitter
RSS
Via Email

Recent Posts
Todays Posts
Most Active posts
Posts since last visit
My Recent Posts
Mark posts read

Sponsors
Shopping Cart Software
Ecommerce software integrated into Frontpage, Dreamweaver and Golive templates. No monthly fees and available in ASP and PHP versions.
Website Templates
We also have a wide selection of Dreamweaver, Expression Web and Frontpage templates as well as webmaster tools and CSS layouts.
Frontpage website templates
Creative Website Templates for FrontPage, Dreamweaver, Flash, SwishMax

 

Microsoft VBScript compilation error '800a03f6' Expected 'End'

 
View related threads: (in this forum | in all forums)

Logged in as: Guest
Users viewing this topic: none
Printable Version 

All Forums >> Web Development >> ASP, PHP, and Database >> Microsoft VBScript compilation error '800a03f6' Expected 'End'
Page: [1]
 
watle

 

Posts: 6
Joined: 6/29/2009
Status: offline

 
Microsoft VBScript compilation error '800a03f6' Expec... - 7/4/2009 7:40:05   
I get this Error when i tried to run my code.
Please help. I get a long code 250 linie. thank you so so much in advance


<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="de" lang="de" dir="ltr">
<!-- #include file = "Sample_DB.inc" -->
<!-- #included file = "adovbs.inc" -->
<head>
<title>Update Data</title>
	<meta name="author" content="Sylvain Fami" />
	<meta name="email" content="fls_1@hotmail.com" />
	<meta name="keywords" content="church in Wuerzburg, church in Germany, merciful God church, webprogramming, university wuerzburg" />
	<meta name="description" content="Basic (X)HTML" />
	<meta name="reply-to" content="fls_1@hotmail.com" /> 
	<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
	<link rel="stylesheet" href="../styles/church.css" />
	<link href="../image/favicon.ico" rel="shortcut icon" type="image/x-icon" />
	<script type="text/javascript" src="../scripts/script.js"></script>
</head>
<body class="all">
<% if request.form("submitbutton") <> "Update" then %>

	<%set lrs = server.createObject("adodb.recordset")%>
	<% 
	
	dim id
	id =  Request.QueryString("id")
	lsSql = "Select * from registration WHERE ID = "& id & ""
	lrs.open lsSql, strDSN
	%>
<form id="registration" action="asp_update.asp" method="post">	
<!-- the formular looks better with table. That's why i use table -->
<table width="700" border="0" cellspacing="2" cellpadding="2" class="registration_table">
	<tr>
		<td colspan="4"><h2 class="header_registration"><br /> Mercifuly God Church - Registration<br /></h2>
		</td>
	</tr>
<!-- First section with fieldset=title the section=1. Tell us about yourself... -->
	<tr>
		<td class="td_registration">First Name</td>
		<td> <input name="vorname" type="text" id="vorname" size="30" maxlength="30" value="<% response.write lrs.Fields("Firstname") %>"/></td>
		<td class="td_registration">Last Name</td>
		<td><input name="nachname" type="text" id="nachname" size="30" maxlength="30" value="<% response.write lrs.Fields("Lastname") %>"/></td>
	</tr>
	<tr>
		<td class="td_registration">City</td>
<td><input name="city" type="text" id="city" size="30" maxlength="30" value="<% response.write lrs.Fields("City")%>"/></td>
		<td class="td_registration">Street </td>
		<td><input name="street" type="text" id="street" size="30" maxlength="30" value="<% response.write lrs.Fields("Street")%>"/></td>
	</tr>
	<tr>
		<td class="td_registration">Zip Code</td>
		<td><input name="plz" type="text" id="plz" size="30" maxlength="30" value="<% response.write lrs.Fields("PLZ")%>" /></td>
		<td class="td_registration">State</td>
		<td><input name="state" type="text" id="state" size="30" maxlength="30" value="<% response.write lrs.Fields("State")%>" /></td>
	</tr>
	<tr>
		<td class="td_registration">Homephone</td>
		<td><input name="homephone" type="text" id="homephone" size="30" maxlength="30" value="<% response.write lrs.Fields("Homephone")%>" /></td>
		<td class="td_registration">Cellphone</td>
		<td><input name="cellphone" type="text" id="cellphone" size="30" maxlength="30" value="<% response.write lrs.Fields("Cellphone")%>" /></td>
	</tr>
	<tr>
		<td class="td_registration">Age</td>
		<td><input name="birthdate" type="text" id="birthdate" size="2" maxlength="3" value="<% response.write lrs.Fields("Age")%>" /></td>
		<td class="td_registration">Gender</td>
		<td><select name="gender" id="gender">
						<% 
  // Two variables to preselect the Gender Field
  dim femaleselected
  dim maleselected
  if lrs.fields("Sex") = "female" then
  femaleselected="SELECTED"
  else
    maleselected="SELECTED"
  end if
  %>
		<option <% response.write femaleselected %> value="female">Female</option>
		<option <% response.write maleselected %> value="male">Male</option>
		</select></td>
	</tr>

	<!-- End first section ---- Begin second section with fieldset too--=title=2. What' s about your interest?...-->
	<tr>
		<td colspan="4">
		<p><strong>Interested in:</strong></p>
		<ul>
			<li> 
			<% 
  // Five variables to preselect what you are Interested In
  dim interestedprayer
  dim interestedworship
  dim interesteddownload
  dim interesteddonation
  dim interestedother
  
  If lrs.fields("Interested_Prayer") = "True" Then
  interestedprayer = "checked='checked'"
  End if
  
  if lrs.fields("Interested_Worship") = "True" Then
  interestedworship = "checked='checked'"
  end if
  
  If lrs.fields("Interested_Download") = "True" Then
  interesteddownload = "checked='checked'"
  End if
  
  If lrs.fields("Interested_Donation") = "True" Then
  interesteddonation = "checked='checked'"
  End if
  
  If lrs.fields("Interested_Request") = "True" Then
  interestedother = "checked='checked'"
  End if
  %>
			<input name="prayer" type="checkbox" id="prayer" value="prayer"<% response.write interestedprayer %>/>
			Prayer - contact us or see our weekly schedule -</li>
			<li> <input name="worship_together" type="checkbox" id="worship_together" value="Worship with us" <% response.write interestedworship %> />
			Worship with us - see our weekly schedule -</li>
			<li> <input name="download" type="checkbox" id="download" value="download" <% response.write interesteddownload %> />
			Download</li>
			<li> <input name="donation" type="checkbox" id="donation" value="donation" <% response.write interesteddonation %> />
			Donation</li>
			<li> <input name="other" type="checkbox" id="other" value="other" <% response.write interestedother %> />
			make a request/other</li>
		</ul></td>
	</tr>
<!-- End second section ---- Beginn third section with fieldset toooooo=title=3. Any questions/comments/requests/other?...-->
	<tr>
		<td colspan="4">
		<p><strong>Questions / Comments / Request / Others:</strong><br/>
		<textarea name="questions" cols="50" rows="6" id="questions"><% response.write lrs.Fields ("Additional") %>
		</textarea></p>
		</td>
	<tr>
		<td colspan="4">
		<p>How this page look out for you?</p>
		<p><% 
  // Two variables to preselect the Appreciation type
  dim looksgreat
  dim looksgood
  if lrs.fields("Appreciation") = "great" then
  looksgreat="checked='checked'"
  else
  looksgood="checked='checked'"
  end if
  %>
	<input type="radio" name="appreciation" id="appreciation" value="great" <% response.write looksgreat %> />
	look great
	<input type="radio" name="appreciation" id="appreciation_" value="good" <% response.write looksgood %> />
	look good 
		<p>	Please enter your email-adresse
	<input type="text" name="emailadresse1" id="emailadresse1" value="<% response.write lrs.Fields ("Email") %>"/> 
		</p>
	<br />
		<p>
		<input type="submit" name="submitbutton" id="submitbutton" value="Update"/>
		<input type="button" name="return" id="return" onClick="window.location.href='asp_read.asp'" value="Return" />
		<input type="hidden" name="id" value="<% response.write (id) %>" />
		</p>
		</td>
	</tr>
</table>
<!-- End third section ----- Next ligns end form, Verification-icon, end.......... -->
</form>
	<a href="#" onclick="window.scrollTo(0,0); return false">
	Back to Top</a><br/><br/><br/><br/>
	<!-- back to top-->
	<p>
		<a href="http://validator.w3.org/check?uri=referer">
		<img src="http://www.w3.org/Icons/valid-xhtml10" alt="Valid XHTML 1.0 Strict" height="31" width="88" /></a>      
		<a href="http://jigsaw.w3.org/css-validator/check/referer">
		<img style="border:0;width:88px;height:31px" src="http://jigsaw.w3.org/css-validator/images/vcss" alt="CSS ist valide!" /></a>
	</p>
		
<% else %>

	<% set Conn = server.createobject("adodb.connection") %>
	<% Conn.open strDSN %>	
	<% set lrs = server.createObject("adodb.recordset") %>
	<% lrs.open "registration", strDSN, adOpenStatic, adLockOptimistic, adCmdTable
	 
	 dim firstname
	 dim lastname
	 dim city
	 dim street
	 dim plz
	 dim state
	 dim homephone
	 dim cellphone
	 dim birthdate
	 dim gender
	 dim prayer
	 dim worship_together
	 dim download
	 dim donation
	 dim other
	 dim questions
	 dim appreciation
	 dim emailadresse1
	 
	firstname = request.form("vorname") (1)
	lastname = request.form("nachname") (1)
	city = request.form("city") (1)
	street = request.form("street") (1)
	plz = request.form("plz") (1)
	state = request.form("state") (1)
	homephone = request.form("homephone") (1)
	cellphone = request.form("cellphone") (1)
	birthdate = request.form("birthdate") (1)
	gender = request.form("gender") (1)
		
	if request.form("prayer")="prayer" then 
	prayer=True
	else 
	prayer=False
	end if
	
	if request.form("download")="download" then 
	download=True
	else
	download=False
	end if
  
	if request.form("donation")="donation" then 
	donation=True
	else
	donation=False
	end if
  
	if request.form("other")="other" then 
	other=True
	else
	other=False
	end if
  	questions = request.form("questions") (1)
	appreciation = request.form("appreciation") (1)
	emailadresse1 = request.form("emailadresse1") (1)
  id = request.form("id") (1)
//Update Statement
		sql = "UPDATE registration SET Firstname = '" & firstname & "', Lastname = '" & lastname & "', City = '" & city & "', Street = '" & street & "', PLZ ='" & plz & "', State ='" & state & "', Homephone='"& homephone & "', Cellphone='" & cellphone & "', Age='" & birthdate & "', Gender='" & gender & "', Interested_Prayer=" & prayer & ", Interested_Worship=" & worship_together & ", Interested_Download=" & download & ", Interested_Donation=" & donation & ", Interested_Request=" & request & ", Additional='" & questions & "',  Appreciation=" & appreciation & ", Email='" & emailadresse1 & "', WHERE ID = " & id & ";" 

		set lrs = conn.Execute(sql)
		%>
		<h3>Your data was updated sucessfully</h3>
		<a href="asp_read.asp" style="color:#FBIFBI;">[<] Back</a>
	

<% set lrs = Nothing %>
<% end if %>

	</body>
</html>


< Message edited by Spooky -- 7/11/2009 5:33:13 >
OscarSierra

 

Posts: 181
Joined: 5/14/2004
From: Norway
Status: offline

 
RE: Microsoft VBScript compilation error '800a03f6' E... - 7/7/2009 10:19:54   
quote:

<% end if %>
Suppose you need another <% end if %> or more... count them :)

(in reply to watle)
Page:   [1]

All Forums >> Web Development >> ASP, PHP, and Database >> Microsoft VBScript compilation error '800a03f6' Expected 'End'
Page: [1]
Jump to: 1





New Messages No New Messages
Hot Topic w/ New Messages Hot Topic w/o New Messages
Locked w/ New Messages Locked w/o New Messages
 Post New Thread
 Reply to Message
 Post New Poll
 Submit Vote
 Delete My Own Post
 Delete My Own Thread
 Rate Posts