M
Mark Sargent
Hi All,
been away from developing, if you can call what I do that, and am stumped
already..lol..see code below. I'm trying to get each row to display, based
on the if statements. Hope you can help me here. Cheers.
P.S. ? will appear in place of Japanese characters. Thanx for your
understanding.
Mark Sargent.
Error Type:
Microsoft VBScript compilation (0x800A0400)
Expected statement
/Classifieds/UploadScript.asp, line 63
<td>File Type Error</td>
...........................................................................
Error code is identified here
...........................................................................
<table align="center" bgcolor="#00FF00">
<tr>
<td width="55%">
<p align="center"><br>
<%
Dim strPath
strPath = "/Classifieds/ImageUploads"
Set Upload = Server.CreateObject("Persits.Upload")
Upload.OverwriteFiles = False
Count = Upload.SaveVirtual(strPath)
If Err <> 0 Then
Response.write ("Err.Description")
End if
For Each File in Upload.Files
If File.ImageType <> "JPG" Then
WrongFileType = "????.jpeg??????????????????????????????"
File.Delete
End If
If File.Size > 50000 Then
FileTooBig = "????????????50000??????????(" &File.Size&"bytes).
?????????????????????????????."
File.Delete
End If
Next
Dim ImageWidth
Dim ImageHeight
Dim FilePath
For Each File in Upload.Files
FilePath = File.Path
ImageWidth = File.ImageWidth
ImageHeight = File.ImageHeight
Next
FilePath = replace(FilePath, "\", "/")
FilePath = replace(FilePath, "RemovedForSecurity", "")
%>
</td>
</tr>
<tr> <%If WrongFileType <> "" Then
.............................................................................
.............................................................................
..........................................................
<td>File Type Error</td>
.............................................................................
.............................................................................
...........................................................
<td>Response.Write WrongFileType &"<br>" %>
<a href="ClassifiedUploadImage.asp"><font color="#000000"><b>Try
Again</b></font></a>
<td width="55%"></td>
<%
ElseIf FileTooBig <> "" Then
<td>File Too Big</td>
<td>Response.Write "<font face=""MS P????, MS P??, MS UI Gothic,
MS ????, MS ??"">" &FileTooBig &"</font><br>"%>
<a href="ClassifiedUploadImage.asp"><font color="#000000"><b>Try
Again</b></font></a>
<td width="45%"></td>
</tr>
<%
Else
For Each File in Upload.Files
<tr>
<td>File Name</td>
<td> Response.Write File.FileName & "(" & File.Size & "bytes)
uploaded to easyboarder. <BR>"</td></tr>
Next
<tr>
<td>Image Width</td>
<td>Response.Write "Image Width:"&ImageWidth &"<br>"</td>
<tr>
<td>Image Height</td>
<td>Response.Write "Image Height:"&ImageHeight &"<br>"%>
<td width="55%"></td>
<tr>
<td width="55%"> <font color="#FFFFFF" size="2" face="MS P????, MS P??,
MS UI Gothic, MS ????, MS ??"><b>????????????????????????????????</b></font>
<td width="45%"><font color="#FFFFFF" size="2" face="MS P????, MS P??,
MS UI Gothic, MS ????, MS ??"><b><a
href="ClassifiedImageResize.asp?FilePath=<%=FilePath%>"><font
color="#000000"><b>Resize
Image</b></font></a></b></font>
<p align="center"><font color="#FFFFFF" size="2" face="MS P????, MS
P??, MS UI Gothic, MS ????, MS ??"><b>
</b></font>
<p align="center">
<p align="center"></td>
<form name="form2" method="post" action="ClassifiedNewDetails.asp">
<input type="submit" name="Submit" value="Continue">
<br>
<input type="hidden" name="FilePath" value="<%= FilePath%>">
<br>
<input type="hidden" name="hiddenField2" value="<%=
Session("MM_Username")%>">
<%
End If
%>
</form>
</tr>
</table>
been away from developing, if you can call what I do that, and am stumped
already..lol..see code below. I'm trying to get each row to display, based
on the if statements. Hope you can help me here. Cheers.
P.S. ? will appear in place of Japanese characters. Thanx for your
understanding.
Mark Sargent.
Error Type:
Microsoft VBScript compilation (0x800A0400)
Expected statement
/Classifieds/UploadScript.asp, line 63
<td>File Type Error</td>
...........................................................................
Error code is identified here
...........................................................................
<table align="center" bgcolor="#00FF00">
<tr>
<td width="55%">
<p align="center"><br>
<%
Dim strPath
strPath = "/Classifieds/ImageUploads"
Set Upload = Server.CreateObject("Persits.Upload")
Upload.OverwriteFiles = False
Count = Upload.SaveVirtual(strPath)
If Err <> 0 Then
Response.write ("Err.Description")
End if
For Each File in Upload.Files
If File.ImageType <> "JPG" Then
WrongFileType = "????.jpeg??????????????????????????????"
File.Delete
End If
If File.Size > 50000 Then
FileTooBig = "????????????50000??????????(" &File.Size&"bytes).
?????????????????????????????."
File.Delete
End If
Next
Dim ImageWidth
Dim ImageHeight
Dim FilePath
For Each File in Upload.Files
FilePath = File.Path
ImageWidth = File.ImageWidth
ImageHeight = File.ImageHeight
Next
FilePath = replace(FilePath, "\", "/")
FilePath = replace(FilePath, "RemovedForSecurity", "")
%>
</td>
</tr>
<tr> <%If WrongFileType <> "" Then
.............................................................................
.............................................................................
..........................................................
<td>File Type Error</td>
.............................................................................
.............................................................................
...........................................................
<td>Response.Write WrongFileType &"<br>" %>
<a href="ClassifiedUploadImage.asp"><font color="#000000"><b>Try
Again</b></font></a>
<td width="55%"></td>
<%
ElseIf FileTooBig <> "" Then
<td>File Too Big</td>
<td>Response.Write "<font face=""MS P????, MS P??, MS UI Gothic,
MS ????, MS ??"">" &FileTooBig &"</font><br>"%>
<a href="ClassifiedUploadImage.asp"><font color="#000000"><b>Try
Again</b></font></a>
<td width="45%"></td>
</tr>
<%
Else
For Each File in Upload.Files
<tr>
<td>File Name</td>
<td> Response.Write File.FileName & "(" & File.Size & "bytes)
uploaded to easyboarder. <BR>"</td></tr>
Next
<tr>
<td>Image Width</td>
<td>Response.Write "Image Width:"&ImageWidth &"<br>"</td>
<tr>
<td>Image Height</td>
<td>Response.Write "Image Height:"&ImageHeight &"<br>"%>
<td width="55%"></td>
<tr>
<td width="55%"> <font color="#FFFFFF" size="2" face="MS P????, MS P??,
MS UI Gothic, MS ????, MS ??"><b>????????????????????????????????</b></font>
<td width="45%"><font color="#FFFFFF" size="2" face="MS P????, MS P??,
MS UI Gothic, MS ????, MS ??"><b><a
href="ClassifiedImageResize.asp?FilePath=<%=FilePath%>"><font
color="#000000"><b>Resize
Image</b></font></a></b></font>
<p align="center"><font color="#FFFFFF" size="2" face="MS P????, MS
P??, MS UI Gothic, MS ????, MS ??"><b>
</b></font>
<p align="center">
<p align="center"></td>
<form name="form2" method="post" action="ClassifiedNewDetails.asp">
<input type="submit" name="Submit" value="Continue">
<br>
<input type="hidden" name="FilePath" value="<%= FilePath%>">
<br>
<input type="hidden" name="hiddenField2" value="<%=
Session("MM_Username")%>">
<%
End If
%>
</form>
</tr>
</table>