-
Knowledge Base Approver
The King of Overkill!
VBAX Master
I understand.. give the following a try, real basic example but it should give you what you're looking to do. Of course feel free to ask specifics, but this should help you out:[vba]Sub MikeTextFileExample()
Dim vFF As Long, vFile As String, tempStr As String
'output filename, we can choose this programmatically if desired
vFile = "C:\your file name.txt"
'get a string to add to the file, just for this example
tempStr = InputBox("Please enter string to add to file", "Enter text")
'get an unused file number (for vba to refer to it)
vFF = FreeFile
'open the file so we can write to it
Open vFile For Append As #vFF
'add the line to the file
Print #vFF, tempStr
'close the reference to the file
Close #vFF
'add the link to cell C11 of activesheet
ActiveSheet.Hyperlinks.Add Range("C11"), vFile
End Sub[/vba]
Matt

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