View Single Post
  #4   Report Post  
Posted to microsoft.public.excel.programming
Jon Peltier Jon Peltier is offline
external usenet poster
 
Posts: 6,582
Default Excel VB Editor output stack and/or intermediate window to fil

Public Sub DebugPrint(sLogEntry As String)
' write debug information to a log file

Dim iFile As Integer
Dim sFileName As String

sFileName = ThisWorkbook.Path & "\debuglog" & Format$(Now, "YYMMDD") &
".txt"

iFile = FreeFile

Open sFileName For Append As iFile
Print #iFile, Now; " "; sLogEntry
Close iFile

End Sub


- Jon
-------
Jon Peltier, Microsoft Excel MVP
Tutorials and Custom Solutions
Peltier Technical Services, Inc. - http://PeltierTech.com
_______


"Gum" wrote in message
...
That would help. If I cannot get the stack, then I could get proxy data
that
I can put in the same dump file.

"Jon Peltier" wrote:

Instead of using Debug.Print, I have a routine called DebugPrint which
outputs the date and time plus the Debug string to a text file. I don't
know
about the stack.

- Jon
-------
Jon Peltier, Microsoft Excel MVP
Tutorials and Custom Solutions
Peltier Technical Services, Inc. - http://PeltierTech.com
_______


"Gum" wrote in message
...
I would like to output (dump) the information in the stack and/or
intermediate window of Excel VB Editor to a disk file. How can this be
done?