Mike:
Here is a little snippet of the Web Service. If I instantiate it and run the login method 8 times from the VFP command window, on the 8th try it bombs. Thanx for helping. Finally getting my first opportunity to do a web app so I'm running into some snags.
DEFINE CLASS WSMain AS SESSION OLEPUBLIC
PROCEDURE INIT
LOCAL cHomedir
cHomeDir = IIF(_VFP.StartMode = 5, JUSTPATH(_vfp.ServerName), SUBSTR(JUSTPATH(SYS(16, 0)), 22))
SET DEFAULT TO (cHomedir)
SET PATH TO (cHomedir + '\data')
SET PROCEDURE TO Procfile
OPEN DATABASE ATS SHARED
USE Acat IN 0
USE Acat2 IN 0
USE Aap IN 0
USE Login IN 0
ENDPROC
PROCEDURE DESTROY
CLOSE DATABASE ALL
ENDPROC
PROCEDURE Error(nError, cMethod, nLine)
LOCAL cMessage
cMessage = 'Error: ' + TRANSFORM(nError) + ' - ' + MESSAGE()
COMRETURNERROR(cMethod, cMessage)
ENDPROC
*=========*
*- Login -*
*=========*
FUNCTION Login (cUsername AS STRING, cPassword AS STRING) AS BOOLEAN
SELECT Login
LOCATE FOR UPPER(ALLTRIM(Login.username)) = UPPER(ALLTRIM(cUsername)) ;
.AND. UPPER(ALLTRIM(Login.PASSWORD)) = UPPER(ALLTRIM(cPassword))
IF FOUND()
RETURN .T.
ELSE
RETURN .F.
ENDIF
ENDFUNC
Précédent
Suivant
Répondre
Voir le fil de ce thread
Voir le fil de ce thread à partir de ce message seulement
Voir tous les messages de ce thread
Voir tous les messages de ce thread à partir de ce message seulement