Hi,
I get a script error when starting a custom application in ArcPad 10. This occurs at the login screen. This same script ran without any error in ArcPad 8. This is the error I get:
Script Error 800A01A8
Error Source Unavailable
Error Description
Unavailable
[Line: 65, Column :5]
Source Text Unavailable
After I hit ok on the error box it disappears and I can enter my login info and everything else functions well. This happens on both a Trimble GeoXH 2008 and a GeoXH600, both with ArcPad 10.
This is the beginning of the script (Line 65 mentioned in the error is in bold text):
Option Explicit
On error resume next
'exit flag
Dim g_DoExit
g_DoExit = False
''' <summary>
''' This sub launches when ArcPad opens, to get the master path to the ArcPad location
''' and and also laucnhes the log in form
''' </summary>
Sub StartupArcPad
'Get the Path to the ArcPad application
Dim strArcPadPath
strArcPadPath = Application.Filepath
'Strip off ArcPad.exe
dim strApplicationPath
strApplicationPath = Left(strArcPadPath,InStrRev(strArcPadPath,"\"))
'Set the path to a global varaible for further use
Application.UserProperties("AppPath") = strApplicationPath
'Launch the log in form
Forms("Login").show
'if exit flag is set - then quit
If (True = g_DoExit) Then
Application.Quit
Exit Sub
End If
End Sub
''' <summary>
''' Sets up the form for for the Login information
''' </summary>
Sub Loadform
'Get the deviceID form the suplyed text file
Dim strSystemPath
Dim objDeviceFile
Dim strDeviceID
strSystemPath = Application.UserProperties("AppPath") & "System\"
Set objDeviceFile = Application.CreateAppObject("file")
'Check to see if the DeviceID.txt file is on the devide
if objDeviceFile.Exists(strSystemPath & "DeviceID.txt") then
'Read the file and set the Device ID
objDeviceFile.Open strSystemPath & "DeviceID.txt"
strDeviceID = objDeviceFile.ReadLine
Else
'The File is missing Set the Device ID to missing
strDeviceID = "Device ID Missing See GIS Dept."
End if
'get the form and load the Device ID to the correct field
'get a refference to this form
Dim objLoginform
Set objLoginform = Forms("Login")
'Get a refference to the page and controls
Dim objPage1
Set objPage1 = objLoginform.Pages("PAGE1")
'set the DeviceID controll to the proper value
objPage1.Controls("txtDeviceID").Value = strDeviceID
End Sub
Thanks for any help solving this!
Regards
Raj1339