Link to home
Start Free TrialLog in
Avatar of adraughn
adraughnFlag for United States of America

asked on

Write Log File in 2k/2k3

I have code that's been running fine in Access 2000 but is running a little differently in Access 2003 and I was wondering if you could clue me in as to a reason.

I have a log file (.txt extension) that I am writing during an Access operation that in the past, I have displayed on the users screen using the following VB code:

      ShellExecute 0&, "Open", LogFileName, vbNullString, vbNullString, 1

Where LogFileName = "C:/Temp/LogFile.txt"

When the same code runs in Access 2003, instead of opening the users default text program (like notepad or wordpad), it tries to open this file as a linked table.  Does this make sense or is there a better way that works in both Access 2000 and 2003?
ASKER CERTIFIED SOLUTION
Avatar of DatabaseMX (Joe Anderson - Former Microsoft Access MVP)
DatabaseMX (Joe Anderson - Former Microsoft Access MVP)
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
If that doesn't work, try the RecordsetClone.Recordcount :-)

mx
Mike ... Adria says she is bored and wants to come out for a visit ... and ride your toys in El C ...

mx
Avatar of adraughn

ASKER

More COLD than bored..... the .follow worked. Thanks boys.

-a