|
-
Aug 3rd, 2000, 07:46 AM
#1
Thread Starter
Member
I have the following code which there is a problem with,
There is some code below, which is causing the problem,
'The code which is about 70 lines down starting 'ReStr' in for testing purposes only, and this was working before, but now since this is commented out, the code is erroring, can you see what the problem is?
That bit of code commented out causes the following error to appear, I dont know if this is the cause as the program was working before:-
<font face="Arial" size=2>
<p>Microsoft VBScript runtime </font> <font face="Arial" size=2>error '800a000d'</font>
<p>
<font face="Arial" size=2>Type mismatch: 'Session(...).RequestMap'</font>
<p>
<font face="Arial" size=2>/yeoman/GisDispatcher.asp</font><font face="Arial" size=2>, line 8</font>
"CAN YOU PLEASE ENLIGHTEN ME ON THIS, AS TO WHAT IS CAUSING THIS TYPE MISMATCH ERROR"
<% @Language = "VBScript" %>
<%option explicit%>
<%response.buffer = "true"%>
<%
Dim Msg
Dim Lat
Dim Lon
Dim Userid
Dim Map
Msg = Map & "," & Lon &"," & Lat
Lat=Request.QueryString("Lt")
Lon=Request.QueryString("Ln")
' Map=Request.QueryString("Map")
Map = "OS2000.Map"
userid="1"
'Lat = "50.748867"
'Lon = "-001.554733"
Dim finalm
Set finalm = Server.CreateObject("DLLCall.Geomanconv")
ReStr=finalm.GEOMANCODE(Lat,Lon,Map)
Dim ReStr
Dim arrWork1
Dim arrWork2
Dim i ' a loop counter
Dim MapO
Dim Lat1
Dim Lat2
DIm Lat3
Dim Lat4
Dim Lon1
Dim Lon2
Dim Lon3
Dim Lon4
Dim Page
Dim XCur
Dim YCur
Dim Col
Dim Row
Dim vbCfrl
Dim sValue
Dim Topleftx
Dim Toplefty
Dim brightx
Dim brighty
'The following code was put in for testing purposes only, and this was working before, but now since this is commented out, the code is erroring, can you see what the problem is?
' ReStr = "Res=Map=OS2000.Map, MapO=2, Lat1=50.708286, " & _
' "Lat2=50.798220, " & vbcrlf & _
' "Lat3=50.797615, Lat4=50.707683, Lon1=-001.575082, " & _
' "Lon2=-001.574267, " & vbcrlf & _
' "Lon3=-001.432362, Lon4=-001.433449 , Page=7, XCur=14, " & _
' "YCur=45, Col= H, " & vbcrlf & _
' "Row= 5 , Page=12, XCur=14, YCur=45, Col= G, Row= 7"
'next, remove all of the carriage returns and line feeds
ReStr = Replace(ReStr, vbCfrl, "")
'split the string into an array at each comma
arrWork1 = Split(ReStr, ",")
For i = LBound(arrWork1) to UBound(arrWork1)
arrWork2 = Split(arrWork1(i), "=", 2)
sValue = Trim(arrWork2(UBound(arrWork2)))
Select Case Trim(arrWork2(LBound(arrWork2)))
Case "Map"
Map = sValue
Case "MapO"
MapO = sValue
Case "Lat1"
Lat1 = sValue
Case "Lat2"
Lat2 = sValue
Case "Lat3"
Lat3 = sValue
Case "Lat4"
Lat4 = sValue
Case "Lon1"
Lon1 = sValue
Case "Lon2"
Lon2 = sValue
Case "Lon3"
Lon3 = sValue
Case "Lon4"
Lon4 = sValue
Case "Page"
Page = sValue
Case "XCur"
XCur = sValue
Case "YCur"
YCur = sValue
Case "Col"
Col = sValue
Case "Row"
Row = sValue
End Select
Erase arrWork2 ' clear the array
next
Erase arrWork1 ' clear the array
response.redirect("bmpfull.asp?userid=1&topleftX="&Lon2&"&topleftY="&Lat2&"&brightx="&Lat1&"&brighty ="&Lon1)
%>
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|