I'm writing a program, with VBA, in order to manipulate Microsoft Project.
But i have some troubles and i want to do some debug. How can I open a command line in order to see what's going on with some printfs which appear in the command line?
I'm writing a program, with VBA, in order to manipulate Microsoft Project.
But i have some troubles and i want to do some debug. How can I open a command line in order to see what's going on with some printfs which appear in the command line?
Can't you do your debuging with MsgBox
? I think that will be way easier than getting VBA to spawn a command line. Actually I don't even get why you want to do that since there's a debugger included into VBA...
hth
K
To open a command line from VBA you can use the Shell function (shell("cmd.exe")
)
But for debugging VBA applications, the immediate window (alt+g) is a very, very nice feature.
Instead of doing printfs to a command line window you put some debug.print
statements and watch them from the immediate window. You can also pause execution and lookup/modify variables values in real-time.
Hope that helps