VB/Frontpage ????

My question is similar to q10259657.  I want to take a flat text file say file01, which contains two columns.
aaa   12345
bbb   12312
ccc   212ab
I want to transform the aaa, bbb etc into a hyperlink consisting of a constant string say
'http://mymachine/documentation/tables/aaa.htm' and do the same for each line in the file.  
What is some VB code that will do this?
xoxomosAsked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

MitchBroadheadCommented:
Is the flat file a text file?

Then it would be:

dim strTemp as str

Open "<textfile>.txt" for Input as #1
line input #1, strTemp

hyperlink "http://mymachine/documentation/tables/" & strTemp

I don't know the exact code for a hyperlink as i am not at my desk.
0
MitchBroadheadCommented:
remember to

Close #1

the textfile
0
AHadiACommented:
in the above code isn't considered that
u must extract first col .

try this :



Dim MyLine As String

Dim HLinks(100) As String

ConstString = "http://mymachine/documentation/tables/"

Open "<text file>.txt" For Input As #1

i = 0
While Not EOF(1)
 Line Input #1, MyLine
 HLinks(i) = ConstString + Split(MyLine, " ", 2)(0) + ".htm"
 i = i + 1
Wend

Close(1)
..
..
..
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
MitchBroadheadCommented:
stolen
0
xoxomosAuthor Commented:
Don't know anything about it but it looks good.  Will try it this weekend.  Thanks
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Visual Basic Classic

From novice to tech pro — start learning today.