Jump to content

Can you help test something simple across platforms?


Recommended Posts

Hi,

I've been playing around with using an embedded browser to access a password-protected site (using basic authentication).

The old way of doing it would have been (in a standard, non-Autoit IE instance):

http://username:password@domain.com

But as most of us know, Microsoft removed that functionality a while ago, and just going to domain.com doesn't present the standard login box.

But it still seems to work within an embedded browser.

I'd like to make sure this works across different IE/platform versions - any chance you could help test?

I've got:

Platform - XP Pro

IE - 7.05739

CPU - 32 bit

I greatly appreciate any help you can provide!

Regards,

Andy

Edited by Andrew Peacock
Link to comment
Share on other sites

And I totally forgot to add sample code and URL details, so here it is:

#include <GUIConstantsEx.au3>
#include <WindowsConstants.au3>
#include <IE.au3>

$username = "test"
$password = "test"


_IEErrorHandlerRegister ()

$oIE = _IECreateEmbedded ()
GUICreate("Embedded Web control Test", 640, 580, _
        (@DesktopWidth - 640) / 2, (@DesktopHeight - 580) / 2, _
        $WS_OVERLAPPEDWINDOW + $WS_VISIBLE + $WS_CLIPSIBLINGS + $WS_CLIPCHILDREN)
$GUIActiveX = GUICtrlCreateObj($oIE, 10, 40, 600, 360)

GUISetState()       ;Show GUI

_IENavigate ($oIE, "http://"& $username & ":" & $password & "@www.automateyourbusiness.com/test/")

; Waiting for user to close the window
While 1
    $msg = GUIGetMsg()
    Select
        Case $msg = $GUI_EVENT_CLOSE
            ExitLoop
    EndSelect
WEnd

GUIDelete()

Exit

You should see "Success!" if it works OK.

Regards,

Andy

Edited by Andrew Peacock
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...