Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 37
Default Make changes to Options in Internet Explorer and log onto a networ

This post requests answer to two issues.

Issue no.1
Using a macro, how can I make changes to Internet Options (specifically LAN
Settings) of Internet Explorer.

Issue no. 2
I have a code that is used to access a web page but before I can access that
web page I need to be logged on to a private DCN (Data Communication
Network). Is there a way to log on using a macro.

Thanks and regards

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Make changes to Options in Internet Explorer and log onto a networ


Changinh LAN settings MYA be a security violations. One method would be
to create a BAR file and then run the BAT file using the VBA function
SHELL. Another method would be to run a DLL to make the changes. From
VBA you can call any of the DLL functions in the windows\system32 folder
by declaring the library function in VBA. ther ae plenty of examples of
this on the web if you know which function you need. I can help if I
knew a little bit more of what you are trying to accomplish.

Web loggins are usually aFORM on the webpage. If you gave me the URL I
can help. I recently did this for a Yahoo Mail account shown below.
this code would ned to be modified for your website.

Some sites stay loggin so you need to test if one of the login object
is found before trying to loggin. I did this below by finding the
USERNAME. the user name object would only be available if you were not
logged in.


Set IE = CreateObject("InternetExplorer.Application")
IE.Visible = True

'get web page
IE.Navigate2 URL
Do While IE.readystate < 4 Or _
IE.busy = True

DoEvents
Loop

'login
With Sheets("Main")
Set UserName = IE.document.getelementbyid("username")
If Not UserName Is Nothing Then
UserName.Value = .Range("DefaultEmail")

Set PasswordBox = IE.document.getelementbyid("passwd")
PasswordBox.Value = MailForm.PasswordBox

Set form = IE.document.getelementsbytagname("Form")
form(0).Submit

Do While IE.readystate < 4 Or _
IE.busy = True

DoEvents
Loop

End If
End With


--
joel
------------------------------------------------------------------------
joel's Profile: http://www.thecodecage.com/forumz/member.php?userid=229
View this thread: http://www.thecodecage.com/forumz/sh...d.php?t=157063

Microsoft Office Help

  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 37
Default Make changes to Options in Internet Explorer and log onto a ne

Thanks for your response. For the first part of I need to change the
following in the LAN settings.

(1) I need to uncheck "Use automatic configuration script"
(2) Check "Automatically detect settings".
(3) on the Advanced tab I need to enter some rules such as
*.waridtel.com;*.warid.com;*.wt.wi.pri;172.*.*.*;1 0.*

For the second problem the network I need to log on to is not accessible via
web; rather it is my organization's private network (VPN sort of network). I
click an icon which then pops up a login window. Thus it might not be easy to
modify your code to meet my requirement.



"joel" wrote:


Changinh LAN settings MYA be a security violations. One method would be
to create a BAR file and then run the BAT file using the VBA function
SHELL. Another method would be to run a DLL to make the changes. From
VBA you can call any of the DLL functions in the windows\system32 folder
by declaring the library function in VBA. ther ae plenty of examples of
this on the web if you know which function you need. I can help if I
knew a little bit more of what you are trying to accomplish.

Web loggins are usually aFORM on the webpage. If you gave me the URL I
can help. I recently did this for a Yahoo Mail account shown below.
this code would ned to be modified for your website.

Some sites stay loggin so you need to test if one of the login object
is found before trying to loggin. I did this below by finding the
USERNAME. the user name object would only be available if you were not
logged in.


Set IE = CreateObject("InternetExplorer.Application")
IE.Visible = True

'get web page
IE.Navigate2 URL
Do While IE.readystate < 4 Or _
IE.busy = True

DoEvents
Loop

'login
With Sheets("Main")
Set UserName = IE.document.getelementbyid("username")
If Not UserName Is Nothing Then
UserName.Value = .Range("DefaultEmail")

Set PasswordBox = IE.document.getelementbyid("passwd")
PasswordBox.Value = MailForm.PasswordBox

Set form = IE.document.getelementsbytagname("Form")
form(0).Submit

Do While IE.readystate < 4 Or _
IE.busy = True

DoEvents
Loop

End If
End With


--
joel
------------------------------------------------------------------------
joel's Profile: http://www.thecodecage.com/forumz/member.php?userid=229
View this thread: http://www.thecodecage.com/forumz/sh...d.php?t=157063

Microsoft Office Help

.

  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Make changes to Options in Internet Explorer and log onto a networ


I think the answer is to automate the changing the register. He is an
article on where the IE register parameters are located


'How to configure client proxy server settings by using a registry
file' (http://support.microsoft.com/kb/819961)


If you are able to create a bat file to change the registry settings
then run the bat file from VBA.


--
joel
------------------------------------------------------------------------
joel's Profile: http://www.thecodecage.com/forumz/member.php?userid=229
View this thread: http://www.thecodecage.com/forumz/sh...d.php?t=157063

Microsoft Office Help

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
make changes to Internet Options and how to log onto a private net Farooq Sheri Excel Programming 0 November 24th 09 11:40 AM
VBA and Internet Explorer Jamie Excel Programming 6 September 8th 09 10:18 PM
How can I make VBA scripts compatible with browsers other than Internet Explorer? Advice Pro[_6_] Excel Programming 1 May 21st 09 07:04 PM
Internet Explorer da Excel Discussion (Misc queries) 4 October 9th 08 09:31 PM
internet explorer doris Excel Discussion (Misc queries) 1 January 5th 05 09:44 PM


All times are GMT +1. The time now is 07:04 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"