Fun with Notepad

yearightsure

New member
Local time
Today, 11:57
Joined
Jan 3, 2007
Messages
4
First post, new to the forum...

I have a text file called "test.prm" (ignore the extension...the file is a text file)

There are 22 lines of text (as shown below):

DBServer=xyz
DBName=WTI
DBUserID=
DBPassword=
DBPasswordNotReqd=
DBTimeOut=30
MainSize=5670,8625,3510,5430
ViewerSize=
SetupSize=435,330,6960,4875
HollanderSize=
IsSalesOrder=T
DocNumFrom=4055157
DocNumTo=4055157
PrinterName=Zebra S400
ReportFile=
ItemSearch=
CustCharInv=
CustCharDet=
CustCharItems=
MarginLeft=0.125
MarginTop=0.125
ViewerZoomPcnt=100

I'm trying to find a way to open the file, re-write docnumfrom and docnumto without doing a getfile and then re-writing the entire file; doing so creates problems with another program I am using a shell script to open that utilizes the above text to operate. Re-writing the file simply makes the shelled program barf. The text file must be opened, and the information simply needs to have a find and replace applied to it.

Restated, how does one do a find and replace on a simple text file in access vb using a wildcard as the items past the "docnumto=" will change on each save?

-yRs
 
Last edited:

Users who are viewing this thread

Back
Top Bottom