You could try this:
Create a file for output as mentioned by Jacques.
Then have a string variable to hold the result of LocateFile$(), perhaps
called oStr. Then do:
oStr = LocateFile$(3)
print #9, oStr
This will then avoid the message window and plonk the result in your
text file, but as Jacques said you can not work with file from the
mapbasic window - therefore this feature would have to be an element of
an application with a tool button or menu command to activate it.
===================
Colin Henderson
Assc. GIS Consultant
WFI Consulting
++44 (0)7887 638771
-----Original Message-----
From: Jacques Paris [mailto:[EMAIL PROTECTED]]
Sent: Thursday, August 30, 2001 04:41
To: Brown, Christopher (HI); MIL
Subject: MI-L RE: redirecting results from message window to text file
Chris,
I do not know if that can be done from an existing application or from
the
mapbasic window as one cannot work with files from it.
When writing an aplication that "must" print results to the message
window
and if those are not related to the progress of the operations, I prefer
sending them directly to a text file then displaying the file.
'create a text file to receive the output (9 is any number you want)
c="text_output.txt"
open file c for output as #9
'write the results to it
print #9, "Something to write about"
'to view the results
run command "Run Program ""Notepad.exe"" & "" "+c+" "" "
Hoping this will stimulate more operationnal ideas.
Jacques Paris
e-mail [EMAIL PROTECTED]
MapInfo/MapBasic support http://www.paris-pc-gis.com
-----Original Message-----
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED]]On Behalf Of Brown,
Christopher (HI)
Sent: August 29, 2001 20:56
To: '[EMAIL PROTECTED]'
Cc: '[EMAIL PROTECTED]'
Subject: RE: MI-L Mi-pen files with milisted and MapInfo 6.5
> To find the user-specific directory, or to confirm which file MI Pro
> is currently using, you can use the new MapBasic function
LotateFile$()
> in the MI Pro MapBasic window. Just type:
> Print LocateFile$(3)
> to make MI Pro display in the message window the location of the file
> it is using.
>
I am sure that there is a way to send the results in the message window
to a
text file, but cannot remember how to do it?
Can anyone help?
Thanks
Chris
Chris Brown - Cartographer
Resources Planning, Hamersley Iron P/L
mailto:[EMAIL PROTECTED]
_______________________________________________________________________
List hosting provided by Directions Magazine | www.directionsmag.com |
To unsubscribe, send e-mail to [EMAIL PROTECTED] and
put "unsubscribe MapInfo-L" in the message body.
_______________________________________________________________________
List hosting provided by Directions Magazine | www.directionsmag.com |
To unsubscribe, send e-mail to [EMAIL PROTECTED] and
put "unsubscribe MapInfo-L" in the message body.
_______________________________________________________________________
List hosting provided by Directions Magazine | www.directionsmag.com |
To unsubscribe, send e-mail to [EMAIL PROTECTED] and
put "unsubscribe MapInfo-L" in the message body.