|
|
|||||||||
|
|||||||||
| |||||||||
|
|
|
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
#1
|
|||
|
|||
|
how to read and save in text file
Hi,
I am trying to save the records of smtp , and use it again . I designed a winstock mass email sending software it works but I have to enter smtp all the time so I want save it in text file and use it . please help |
|
#2
|
||||
|
||||
|
will this work for you?
Open App.path & "\YourFileHere" for Input as #1 While Not EOF(1) Line Input #1, gstrYourSMTP Wend Close #1 gstrYourSMTP = Replace(gstrYourSMTP, """", "")
__________________
Fisherman "Any intelligent fool can make things bigger, more complex, and more violent. It takes a touch of genius -- and a lot of courage -- to move in the opposite direction." - A.Einstein |
|
#3
|
|||
|
|||
|
hi
it gives me run time error Open App.Path & "C:\Temp\vb_project\VB98\Bulkemail" For Input As #1 |
|
#4
|
||||
|
||||
|
Fisherman had Open App.path & "\YourFileHere" for Input as #1 not Open App.Path & "path\to\YourFileHere"...
The reason for this is because App.Path adds the path to the file. When your app tries to open a file, it sees this: C:\Temp\vb_projects\VB98\C:\Temp\vb_project\VB98\Bulkemail which is an invalid path. |
![]() |
| Viewing: Dev Shed Forums > Programming Languages - More > Visual Basic Programming > how to read and save in text file |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|