English Deutsch Français Italiano Español Português 繁體中文 Bahasa Indonesia Tiếng Việt ภาษาไทย
All categories

i have a directory that I imported to a text file by
dir/b >textfile.txt

I want to know if there is a program that will automaticllay turn each line into a link...

what I basicllay want to do is, the files are names of movies.... i want to be able to hyperlink to yahoo movie previews, or some other movie preview site, and use the text on each line as a search string for which ever site i choose....

doing this manuallay would be a huge hassle, i am tring to automate the process...

I am sure that a simple script could be made to accomplish what I am looking to do...

2007-10-26 18:39:51 · 1 answers · asked by joe r 7 in Computers & Internet Programming & Design

should say "turn text FILE into links?"

2007-10-26 18:40:40 · update #1

thanks daniel... but problem is I havent done much coding since basic... and some html, way back in the day... I used notepad and created a script file (perhaps i am supposed to use something to compile the file??) this is the error I got with your code (and yes i changed the generic file names to fit what I need)

script : (it says the location and file name)
line: 1
char: 5
Error: expected ";"
Code: 800A03EC
Source: Microsoft JScript compilation error

2007-10-26 19:45:03 · update #2

1 answers

Set objFSO = CreateObject("Scripting.FileSystemObject")
Set objTextFile = objFSO.OpenTextFile ("c:\INPUTFILE.txt", ForReading)
Set objFile = objFSO.CreateTextFile("C:\OUTPUT.txt")
Set ObjFileText = objFSO.OpenTextFile("c:\output.txt", ForAppending, True)

Do Until objTextFile.AtEndOfStream
strNextLine = objTextFile.Readline
strMessage = "" _
& strNextLine & "
" & vbcrlf
objFileText.WriteLine strMessage

Next
Loop


ObjTextFile.Close
ObjFileText.Close

2007-10-26 19:18:48 · answer #1 · answered by Daniel T 5 · 0 0

fedest.com, questions and answers