bsharath
asked on
Any way to get all the save target as links to a file
Hi,
Say if i am on EE page and there anr many links Can i get all these to a file.
Say i have opened Q's need to get all these names(The full Http path) to a file.
Regards
SHarath
Say if i am on EE page and there anr many links Can i get all these to a file.
Say i have opened Q's need to get all these names(The full Http path) to a file.
Regards
SHarath
ASKER
Is this a Vbs script...
It's VB.Net, converted from a vbs
ASKER
Sorry to ask how should i run this..
I saved the code as "Filename.vbs" But gives an error.
I saved the code as "Filename.vbs" But gives an error.
The code is vb.net if you want to make a vbs file use this
Dim sURL
Dim IeDoc
Dim i
Const ForAppending = 8
set objFSO = CreateObject("Scripting.Fi leSystemOb ject")
set objFile = objFSO.OpenTextFile("C:\te sta.txt", ForAppending, True)
'Create new instance of IE
Set ieapp = CreateObject("InternetExpl orer.Appli cation")
'Make it visible - some things dont work
'unless its visible
ieapp.Visible = True
'define the page to open
sURL = "www.yahoo.com"
'navigate to the page
ieapp.Navigate sURL
'Pause the macro using a loop until the
'page is fully loaded
Do
Loop Until ieapp.ReadyState = 4 ' READYSTATE_COMPLETE
'store the Document object
Set IeDoc = ieapp.Document
For d = 0 To ieapp.Document.All.tags("a ").Length
objFile.WriteLine(IeDoc.Li nks(d).hre f)
Next
objFile.Close
Dim sURL
Dim IeDoc
Dim i
Const ForAppending = 8
set objFSO = CreateObject("Scripting.Fi
set objFile = objFSO.OpenTextFile("C:\te
'Create new instance of IE
Set ieapp = CreateObject("InternetExpl
'Make it visible - some things dont work
'unless its visible
ieapp.Visible = True
'define the page to open
sURL = "www.yahoo.com"
'navigate to the page
ieapp.Navigate sURL
'Pause the macro using a loop until the
'page is fully loaded
Do
Loop Until ieapp.ReadyState = 4 ' READYSTATE_COMPLETE
'store the Document object
Set IeDoc = ieapp.Document
For d = 0 To ieapp.Document.All.tags("a
objFile.WriteLine(IeDoc.Li
Next
objFile.Close
ASKER
I get this...
-------------------------- -
Windows Script Host
-------------------------- -
Script: C:\Documents and Settings\sharathr\Desktop\ Get all links.vbs
Line: 33
Char: 1
Error: Object required: 'Links(...)'
Code: 800A01A8
Source: Microsoft VBScript runtime error
-------------------------- -
OK
-------------------------- -
--------------------------
Windows Script Host
--------------------------
Script: C:\Documents and Settings\sharathr\Desktop\
Line: 33
Char: 1
Error: Object required: 'Links(...)'
Code: 800A01A8
Source: Microsoft VBScript runtime error
--------------------------
OK
--------------------------
Did it open IE when you ran it? What URL did you use?
ASKER
Yes it opens the iE and for this link...
https://www.experts-exchange.com/?qipuIndex=1&openQuest=true#questionsInProgress
Here i have all my open Q's...
I got the error here.
For Yahoo it worked fine...
https://www.experts-exchange.com/?qipuIndex=1&openQuest=true#questionsInProgress
Here i have all my open Q's...
I got the error here.
For Yahoo it worked fine...
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
>>but if your wanting to monitor questions on EE you may want to check out quickee on sourceforge.net
...or even better, check out my profile :)
...or even better, check out my profile :)
ASKER
I get this...
-------------------------- -
QuickEE
-------------------------- -
Object reference not set to an instance of an object.
-------------------------- -
OK
-------------------------- -
After installing it asks me for the username and password after i provide i get this...
It says Logging in please wait....
--------------------------
QuickEE
--------------------------
Object reference not set to an instance of an object.
--------------------------
OK
--------------------------
After installing it asks me for the username and password after i provide i get this...
It says Logging in please wait....
bsharath,
Any bugs or problem you encounter, please post in the Bugs thread -> http:/Q_22769793.html
Wayne
Any bugs or problem you encounter, please post in the Bugs thread -> http:/Q_22769793.html
Wayne
Dim IeDoc As Object
'Create new instance of IE
Dim ieapp As Object = CreateObject("InternetExpl
'Make it visible - some things dont work
'unless its visible
ieapp.Visible = True
'define the page to open
Dim sURL As String = "www.yahoo.com"
'navigate to the page
ieapp.Navigate(sURL)
'Pause the macro using a loop until the
'page is fully loaded
Do
Loop Until ieapp.ReadyState = 4 ' READYSTATE_COMPLETE
'store the Document object
IeDoc = ieapp.Document
For d As Integer = 0 To ieapp.Document.All.tags("a
My.Computer.FileSystem.Wri
Next