Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Page is correctly loaded?
Message
From
12/10/2001 03:38:12
 
General information
Forum:
Visual FoxPro
Category:
COM/DCOM and OLE Automation
Miscellaneous
Thread ID:
00566703
Message ID:
00567431
Views:
11
Hi José,

this is the code my applications use to establish a connection to a home banking site, including a progress bar for the user.
The max time given to the web browser control to open the site is in lnHBFailureDelay.
    loIE.Navigate(lcHBURL)
    llReady = .F.
    ltStart = DATETIME()
    lfrmPB  = CREATEOBJECT("frmprogressbar",
                           "WebSite der Bank wird gesucht... (max. Dauer: "
                           +TRANSFORM(lnHBFailureDelay)+" s)")
    WITH lfrmPB
      .setBar(0)
      .Show()
      lnSec = 0
      DO WHILE (DATETIME()-ltStart) <= lnHBFailureDelay
        lnBuf = INT(DATETIME()-ltStart)
        IF lnBuf > lnSec 
          lnSec = lnBuf
          .setBar(100*lnSec/lnHBFailureDelay)
          IF loIE.ReadyState >= READYSTATE_LOADED
            llReady = .T.
            EXIT
          ENDIF
        ENDIF
      ENDDO
    ENDWITH
    lfrmPB = .NULL.
    IF NOT llReady
* site is not there 
    ENDIF
HTH Robert
I've acquired quite a taste for a well-made mistake... [Fiona Apple]
Previous
Reply
Map
View

Click here to load this message in the networking platform