VB6 Debugger - Command line arguements - vb6

In the VB6 IDE there is a window were you can specify command line arguements (for debugging). If you create a .exe with arguements specified, will they be published with the application? I don't believe they will.

No, they will not. This is just for testing your application if it uses command line arguments. It allows you to specify your command line arguments and step through exactly like if the program was called with those command line arguments.
For example, you normally pass parameters by simply calling your EXE and providing the parameters at the same time. So, if you normally call your program like such
C:\test.exe /test /inet /copy
You would simply set the command-line arguments to
/test /inet /copy
in the VB6 IDE

Related

How can I get command line arguments in a Qt Installer Framework script?

I am writing a Qt Installer Framework script, and I would like to allow the user to launch the installer with arguments and then apply those arguments in various ways. For example, a switch to auto accept the EULA, a means to directly pass the target directory, a list of the components to be installed, etc.
The syntax to pass arguments to QIFW installer is Key=Value.
You can provide command line argument like below
YouInstaller.exe Arg1=true
Then you can get this value in Component or Controller script as below
var Arg1 = installer.value('Arg1')
installer QML Type
Controller Script

Use VS envirenment-variables as command-line args

I can use envireonment-variables such as $(TargetFileName) in my pre- and post-build-events. What I want to do is apply those variables to the command-line args of an external program (in my case nunit). So whenever my app starts I want to start another one with the file-name of the first as arg.
Is this possible?
When debugging my project the nunit-windows appears but shows an error-message that the given assembly $(OutDir)$(TargetFileName)$(TargetExt) could not be found. I suppose that the variables are only available during build but not during run so it seems I have to hardcode the parameters to the command-line args. Is this true?

windows command not responding to ruby - trying to call a macro with a .mac file extension

I have a macro file that i can run in the cmd line in windows by simply navigating to the directory and typing profit.mac in the cmd line
however, when i go to call it in a ruby script i keep getting errors
I have tried system(), exec(), ``, and %x() and i havent been able to get it to work
are there any other options I have to call my macro file?
i get the same error on 3/4 of them
(backticks), profit.mac = (Errno::ENOEXEC)
exec('profit.mac') = (Errno::ENOEXEC)
%x('profit.mac') = (Errno::ENOEXEC)
system('profit.mac') = nothing happens
Are your .mac macros files executables or need to be interpreted by another program?
I guess those macros files have to be interpreted by another "macros executor" program. You would need to prepend that in your command execution.
exec('macrosInterpreter.exe /path/to/profit.mac')
It is like running a ruby script. Assume you want to run a test.rb file. You can't do exec('test.rb'), you would have to do exec('ruby test.rb').

Install MathLink program with arbitrary PATH environment

Is it possible to use Install[] to start a MathLink program with a custom PATH environment variable?
I am trying to use mEngine to connect Mathematica to MATLAB on Windows. It only works if mEngine.exe is launched when the PATH environment variable includes the path to the MATLAB libraries. Is it possible to modify the PATH for launching this program only, without needing to modify the system path? Or is there another way to launch mEngine.exe?
#acl's solution to wrap mEngine.exe in a batch file, and temporarily modify the PATH from there, works correctly:
I used this as the contents of mEngine.bat:
set PATH=c:\path\to\matlab\bin\win32;%PATH%
start mEngine.exe %*
*% ensures that all command line arguments are passed on to mEngine.exe
start is necessary to prevent the command window from staying open until mEngine.exe terminates
It can be started using Install["mEngine.bat"].
Since all the information that is needed for the kernel to communicate with mEngine.exe is passed by Install[] as command line arguments, all we need to do is launch mEngine.exe with these arguments. It is not necessary for Install[] to know the location of mEngine.exe, the important thing is that the process gets launched with the correct command line arguments, which is ensured by %*.

Windows Program: How to snoop on command line arguments?

I am trying to reverse engineer the build system of a commercial Windows based IDE, so I can use make to build my project.
A program is launched to perform a task, and I need to know what command line arguments are passed to this program when it is run. However the windows process viewer does not show the command line arguments.
Is there any way to see what command line arguments are being passed when the program is launched?
(Actually it just occurred to me that I should substitute a stub program to read the command line args. Still, I'd like to know if there's an easy way).
Sysinternals Process Explorer lets you do that.

Resources