|
-
Apr 29th, 2007, 10:30 AM
#1
Thread Starter
New Member
accessing internet explorer
hi
i want to make a program that opens internet explorer and open up webpages in that opened instance of IE..it should be able to read the source and send information to it..like form posting...? now i searched up the net but couldn't find the information..maybe i am searching the wrong topics...please help me with this...or atleast tell me what i should be looking for internet programming or DCOm programming or...sth else?
thanks
-
Apr 29th, 2007, 03:10 PM
#2
Re: accessing internet explorer
Welcome to the Forums.
Here is a thread that has several methods that you can use.
http://www.vbforums.com/showthread.php?t=330341
VB/Office Guru™ (AKA: Gangsta Yoda™ ®)
I dont answer coding questions via PM. Please post a thread in the appropriate forum. 
Microsoft MVP 2006-2011
Office Development FAQ (C#, VB.NET, VB 6, VBA)
Senior Jedi Software Engineer MCP (VB 6 & .NET), BSEE, CET
If a post has helped you then Please Rate it! 
• Reps & Rating Posts • VS.NET on Vista • Multiple .NET Framework Versions • Office Primary Interop Assemblies • VB/Office Guru™ Word SpellChecker™.NET • VB/Office Guru™ Word SpellChecker™ VB6 • VB.NET Attributes Ex. • Outlook Global Address List • API Viewer utility • .NET API Viewer Utility •
System: Intel i7 6850K, Geforce GTX1060, Samsung M.2 1 TB & SATA 500 GB, 32 GBs DDR4 3300 Quad Channel RAM, 2 Viewsonic 24" LCDs, Windows 10, Office 2016, VS 2019, VB6 SP6 
-
Apr 30th, 2007, 10:30 AM
#3
Thread Starter
New Member
Re: accessing internet explorer
great thread over there rob i learned something but still all that is related when u have a webbrowser component in your form....but i don't want to have a webbroswer componet..i want vb to open IE.....and in that opened instance of IE thru either handle or something like that communicate with it...basically do what the code over the other thread does but not in a webrowser component..it should be in an opened IE that the progarm opened..
-
Apr 30th, 2007, 02:33 PM
#4
Re: accessing internet explorer
Here is a quick example of creating a new IE and navigating to a website.
Code:
Option Explicit
Private Sub Form_Load()
Dim oIE As Object
Set oIE = CreateObject("InternetExplorer.Application")
oIE.Visible = True
oIE.Navigate2 "http://www.vbforums.com"
End Sub
VB/Office Guru™ (AKA: Gangsta Yoda™ ®)
I dont answer coding questions via PM. Please post a thread in the appropriate forum. 
Microsoft MVP 2006-2011
Office Development FAQ (C#, VB.NET, VB 6, VBA)
Senior Jedi Software Engineer MCP (VB 6 & .NET), BSEE, CET
If a post has helped you then Please Rate it! 
• Reps & Rating Posts • VS.NET on Vista • Multiple .NET Framework Versions • Office Primary Interop Assemblies • VB/Office Guru™ Word SpellChecker™.NET • VB/Office Guru™ Word SpellChecker™ VB6 • VB.NET Attributes Ex. • Outlook Global Address List • API Viewer utility • .NET API Viewer Utility •
System: Intel i7 6850K, Geforce GTX1060, Samsung M.2 1 TB & SATA 500 GB, 32 GBs DDR4 3300 Quad Channel RAM, 2 Viewsonic 24" LCDs, Windows 10, Office 2016, VS 2019, VB6 SP6 
-
May 1st, 2007, 09:47 AM
#5
Thread Starter
New Member
Re: accessing internet explorer
thanks rob..i will try this..
is it possible to only load the html first..like i don't want any images to be loaded..atleast the one not specified?
Last edited by nepdude; May 1st, 2007 at 10:10 AM.
-
May 1st, 2007, 12:24 PM
#6
Re: accessing internet explorer
I think there was something like that already on the forums. Try a search.
VB/Office Guru™ (AKA: Gangsta Yoda™ ®)
I dont answer coding questions via PM. Please post a thread in the appropriate forum. 
Microsoft MVP 2006-2011
Office Development FAQ (C#, VB.NET, VB 6, VBA)
Senior Jedi Software Engineer MCP (VB 6 & .NET), BSEE, CET
If a post has helped you then Please Rate it! 
• Reps & Rating Posts • VS.NET on Vista • Multiple .NET Framework Versions • Office Primary Interop Assemblies • VB/Office Guru™ Word SpellChecker™.NET • VB/Office Guru™ Word SpellChecker™ VB6 • VB.NET Attributes Ex. • Outlook Global Address List • API Viewer utility • .NET API Viewer Utility •
System: Intel i7 6850K, Geforce GTX1060, Samsung M.2 1 TB & SATA 500 GB, 32 GBs DDR4 3300 Quad Channel RAM, 2 Viewsonic 24" LCDs, Windows 10, Office 2016, VS 2019, VB6 SP6 
-
May 4th, 2007, 10:11 AM
#7
Thread Starter
New Member
Re: accessing internet explorer
hi....are there any API's for positiioning the IE window?? i want the IE window to open up in a location that i have specified...and also to scroll the page to a desired position...i know it is possible to do by javascript...and in this case by inserting custom javascript into the page, but is there any API or function within VB to acomplish that.
-
May 4th, 2007, 04:10 PM
#8
Re: accessing internet explorer
You can use SetWindowPos to position the window and size it.
I think for the scroll you will need to SendMessage to it but unsure how to tell it to go to a particular point.
VB/Office Guru™ (AKA: Gangsta Yoda™ ®)
I dont answer coding questions via PM. Please post a thread in the appropriate forum. 
Microsoft MVP 2006-2011
Office Development FAQ (C#, VB.NET, VB 6, VBA)
Senior Jedi Software Engineer MCP (VB 6 & .NET), BSEE, CET
If a post has helped you then Please Rate it! 
• Reps & Rating Posts • VS.NET on Vista • Multiple .NET Framework Versions • Office Primary Interop Assemblies • VB/Office Guru™ Word SpellChecker™.NET • VB/Office Guru™ Word SpellChecker™ VB6 • VB.NET Attributes Ex. • Outlook Global Address List • API Viewer utility • .NET API Viewer Utility •
System: Intel i7 6850K, Geforce GTX1060, Samsung M.2 1 TB & SATA 500 GB, 32 GBs DDR4 3300 Quad Channel RAM, 2 Viewsonic 24" LCDs, Windows 10, Office 2016, VS 2019, VB6 SP6 
-
May 10th, 2007, 09:25 AM
#9
Thread Starter
New Member
Re: accessing internet explorer
i am using this
ie.navigate2 "html file"
--> Here ie is a referenced object
now this works fine when i click on the command button again and again and it opens fine but after
closing the opened instance of IE by clicking the close button of the opened instance of IE, and after clicking on the command button i get this error.
run time error '-2147417848 (80010108)':
Automation error
The object invoked has diconnected from its clients.
How do i get around this?
also what is the vb code for double quotation? (for replace function)
sorry for asking in this same forum
-
May 10th, 2007, 10:08 AM
#10
Re: accessing internet explorer
Post your code. Are you saying that you get the error when you close IE and then try to create another?
VB/Office Guru™ (AKA: Gangsta Yoda™ ®)
I dont answer coding questions via PM. Please post a thread in the appropriate forum. 
Microsoft MVP 2006-2011
Office Development FAQ (C#, VB.NET, VB 6, VBA)
Senior Jedi Software Engineer MCP (VB 6 & .NET), BSEE, CET
If a post has helped you then Please Rate it! 
• Reps & Rating Posts • VS.NET on Vista • Multiple .NET Framework Versions • Office Primary Interop Assemblies • VB/Office Guru™ Word SpellChecker™.NET • VB/Office Guru™ Word SpellChecker™ VB6 • VB.NET Attributes Ex. • Outlook Global Address List • API Viewer utility • .NET API Viewer Utility •
System: Intel i7 6850K, Geforce GTX1060, Samsung M.2 1 TB & SATA 500 GB, 32 GBs DDR4 3300 Quad Channel RAM, 2 Viewsonic 24" LCDs, Windows 10, Office 2016, VS 2019, VB6 SP6 
-
May 10th, 2007, 10:16 AM
#11
Thread Starter
New Member
Re: accessing internet explorer
yes rob exactly..
i open and IE instance and then i close it and if again i try to open that then i get that error..
-
May 10th, 2007, 10:22 AM
#12
Re: accessing internet explorer
I just tested my code in a Command1_Click event procedure and I was able to open, close and rereate several times. Can you post your code.
VB/Office Guru™ (AKA: Gangsta Yoda™ ®)
I dont answer coding questions via PM. Please post a thread in the appropriate forum. 
Microsoft MVP 2006-2011
Office Development FAQ (C#, VB.NET, VB 6, VBA)
Senior Jedi Software Engineer MCP (VB 6 & .NET), BSEE, CET
If a post has helped you then Please Rate it! 
• Reps & Rating Posts • VS.NET on Vista • Multiple .NET Framework Versions • Office Primary Interop Assemblies • VB/Office Guru™ Word SpellChecker™.NET • VB/Office Guru™ Word SpellChecker™ VB6 • VB.NET Attributes Ex. • Outlook Global Address List • API Viewer utility • .NET API Viewer Utility •
System: Intel i7 6850K, Geforce GTX1060, Samsung M.2 1 TB & SATA 500 GB, 32 GBs DDR4 3300 Quad Channel RAM, 2 Viewsonic 24" LCDs, Windows 10, Office 2016, VS 2019, VB6 SP6 
-
May 10th, 2007, 10:34 AM
#13
Thread Starter
New Member
Re: accessing internet explorer
Code:
Dim ie As New InternetExplorer
Private Sub Command1_Click()
Dim i As String
ie.Navigate2 "localhost"
ie.Visible = True
End Sub
i am getting the hint that it might be becuz of that global declaration?
-
May 10th, 2007, 10:38 AM
#14
Re: accessing internet explorer
Yes, because you are creating it in there too with the "New".
Code:
Dim ie As InternetExplorer
Private Sub Command1_Click()
Set ie = CreateObject("InternetExplorer.Application")
Dim i As String
ie.Navigate2 "localhost"
ie.Visible = True
End Sub
VB/Office Guru™ (AKA: Gangsta Yoda™ ®)
I dont answer coding questions via PM. Please post a thread in the appropriate forum. 
Microsoft MVP 2006-2011
Office Development FAQ (C#, VB.NET, VB 6, VBA)
Senior Jedi Software Engineer MCP (VB 6 & .NET), BSEE, CET
If a post has helped you then Please Rate it! 
• Reps & Rating Posts • VS.NET on Vista • Multiple .NET Framework Versions • Office Primary Interop Assemblies • VB/Office Guru™ Word SpellChecker™.NET • VB/Office Guru™ Word SpellChecker™ VB6 • VB.NET Attributes Ex. • Outlook Global Address List • API Viewer utility • .NET API Viewer Utility •
System: Intel i7 6850K, Geforce GTX1060, Samsung M.2 1 TB & SATA 500 GB, 32 GBs DDR4 3300 Quad Channel RAM, 2 Viewsonic 24" LCDs, Windows 10, Office 2016, VS 2019, VB6 SP6 
-
May 10th, 2007, 10:48 AM
#15
Thread Starter
New Member
Re: accessing internet explorer
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|