I am looking for a method to open internet explorer 9 as "InPrivate" mode so that I can log into a site under multiple logins.
How could I go about opening multiple instances of IE while keeping cookies isolated for each one, the only method I can think of is to open IE in its private mode. However after a significant amount of searching I haven't seen a function to do that. I am trying to avoid the "Application.SendKeys (Ctrl/Shift + P)" method and launch private IE (and set it as an object).Private Sub LaunchCRM() Dim TimeOutCheck As Integer TimeOutCheck = 0 USERNAME = Cells(Cells(2, "A").Value + 2, "C") PASSWORD = Cells(Cells(2, "A").Value + 2, "D") Set IE = CreateObject("InternetExplorer.Application") IE.Navigate "WEBSITE" IE.Visible = True AppActivate IE Do While FindWindow(vbNullString, "Windows Security") = 0 And FindWindow(vbNullString, "Connect to admin.saveonenergy.ca") = 0 Application.Wait DateAdd("s", 1, Now) TimeOutCheck = TimeOutCheck + 1 If TimeOutCheck = 15 Then MsgBox ("Timed out due to window not existing." & vbNewLine & "Please try again.") Exit Sub End If Loop Call FillLogin(USERNAME, PASSWORD) Call SetNumLockKey(True) If Cells(1, "A").Value = True Then Application.OnTime Now + TimeValue("00:00:01"), "LoginPrompt" End If End Sub
Thanks in advance.
hi, cerothen, as an option you can set the IE to start "In private" mode by default by amending registry, search the Internet on how to do that
Last edited by watersev; 11-03-2011 at 09:57 AM.
Thanks for the reply. However I am not looking to open IE as an "InPrivate" window be default. I am looking to when I call a function open an "InPrivate" window. Before my first post I had already looked into the registry option of that. However as this will be given to a few colleges it they likely don't want their IE to always open as "InPrivate".
Basically I am looking for something that would be similar to a call:
Set IE = CreateObject("InternetExplorer.Application.InPrivate")
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks