GoOnline Method
Class: FTP_SERVICE
Description:Brings up a dialog to the user requesting permission to go the requested URL
Brings up a dialog to the user requesting permission to go the requested URL.
=
Object.GoOnline
(lcURL)
Parameter
lcURL
URL
Type Character
Direction Input
The URL program is requesting to go to.
Return value Boolean
The return value is .T. if is test suscesfull or .F. is not.
Remarks
Assumed from MSDN.
Example
LOCAL loFTP SET PROCEDURE TO ftp.prg ADDITIVE loFTP=CREATEOBJECT('ftp_service') IF loFTP.OpenInternet("ABONNE", "PWD", "10.10.10.10", "21") IF !loFTP.GetFTPFile("anyt.xt","local.txt") IF loFTP.IsGlobalOffline()=1 && Offline mode IF loFTP.GoOnline("ftp://10.10.10.10/any.txt") IF loFTP.GetFTPFile("any.txt","local.txt") ?STRTRAN("File %File% downloaded","%File%","local.txt") ENDIF ENDIF ENDIF ENDIF =loFTP.CloseInternet() ENDIF RELEASE PROCEDURE ftp.prg
See also
Expand/Collapse source code of procedure GoOnline Source Code
      LPARAMETERS INP lcURL
      LOCAL lnHWNDHandle, fResult
      IF This.LoadAPIFuncs() != ERROR_SUCCESS
         RETURN .F.
      ENDIF

      IF TYPE("m.lcURL") != "C"
         RETURN .F.
      ENDIF
                  
      lcURL = m.lcURL + cNULL
      lnHWNDHandle = 0
      =This.BeforeGoOnline(@m.lcURL)
      fResult = InternetGoOnline(@m.lcURL, m.lnHWNDHandle, 0)
      =This.GetExtendedError()
      =This.AfterGoOnline(@m.lcURL,m.fResult)
      RETURN m.fResult # 0