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
LVL 11
bsharathAsked:
Who is Participating?
 
JonMnyCommented:
just add this

on error resume next

on the first line

Not sure what your trying to do but if your wanting to monitor questions on EE you may want to check out quickee on sourceforge.net
0
 
JonMnyCommented:


      Dim IeDoc As Object
        'Create new instance of IE
        Dim ieapp As Object = CreateObject("InternetExplorer.Application")
        '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").Length
            My.Computer.FileSystem.WriteAllText("C:\Test.txt", IeDoc.Links(d).href & vbCrLf, True)
        Next
0
 
bsharathAuthor Commented:
Is this a Vbs script...
0
Free Tool: IP Lookup

Get more info about an IP address or domain name, such as organization, abuse contacts and geolocation.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

 
JonMnyCommented:
It's VB.Net, converted from a vbs
0
 
bsharathAuthor Commented:
Sorry to ask how should i run this..
I saved the code as "Filename.vbs" But gives an error.

0
 
JonMnyCommented:
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.FileSystemObject")

set objFile = objFSO.OpenTextFile("C:\testa.txt", ForAppending, True)




    'Create new instance of IE
    Set ieapp = CreateObject("InternetExplorer.Application")
   
    '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.Links(d).href)



    Next
objFile.Close




0
 
bsharathAuthor Commented:
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  
---------------------------
0
 
JonMnyCommented:
Did it open IE when you ran it? What URL did you use?
0
 
bsharathAuthor Commented:
Yes it opens the iE and for this link...
http://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...
0
 
Wayne Taylor (webtubbs)Commented:
>>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 :)
0
 
bsharathAuthor Commented:
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....
0
 
Wayne Taylor (webtubbs)Commented:
bsharath,

Any bugs or problem you encounter, please post in the Bugs thread -> http:/Q_22769793.html

Wayne
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.