An INI file is a bit more than just a text file... there are system INIs and
private INIs, but basically these are "leftovers" from 16-bit Windows.
32-bit Windows uses the Registry for similar purposes -- a great improvement
in the eyes of some, not an improvement at all in the eyes of others. There
are Windows APIs for dealing with INI files, that are preferrable to just
working on them as though they were normal text, although they can be
read/written as normal text files. To learn about the APIs, I'd start
searching at the FAQ site,
http://www.mvps.org/access, then if I didn't find
what I was looking for, I'd go to the base URL of
http://www.mvps.org and
look for sites offering VB assistance -- one that is very good in such areas
is VB MVP Randy Birch's site. I'd look at
http://support.microsoft.com to
search the Knowledge Base and
http://office.microsoft.com.
Larry Linson
Microsoft Access MVP
"bborden" <bb*******@gmail.com> wrote in message
news:ea**************************@posting.google.c om...
I have a newbie question. Using VBA how do I open an INI file and
change the "LastDir=" line, shown below, to a new location then save
the file. I want to do this all in the backgroud before I run a
picture organizer application(from a command button on a form) that
will access the new location in the INI file.
Bottom Width=304
Bottom Height=0
[Main]
HideOnClose=0
LastDir=C:\Pictures\SmithJohn2
LastWorkDir=
LastAction=0
ViewStyle=0
Orientation=0
Thanks in advance.
"Michael Wiseley" <mi**********@gte.net> wrote in message
news:<xayrd.6727$wr6.1175@trnddc04>...
When using
Do until rst.eof
Put #filename, , rst!somedata
rst.movenext
Loop
I would like to create a new line for each item written into the text
file. Is there are character I can concatenate onto the back end of the string
I am writing to the txt file ?
Or is their a verison of Put that also does NewLine ??