H
hkMicro
Having problems compiling the following code in C USING CL.EXE
// shell.c LANGUAGE = .NET 2003
#include <iostream.h>
#include <windows.h>
int main()
{
SHELLEXECUTE(NULL, "open", "notepad.exe", NULL, NULL, SW_SHOWNORMAL);
RETURN 0;
}
Results:
C:\ > CL /EHs shell.c
....... Incremental Linker Version 6.00.8447
......
shell.obj : error LNK2001: unresolved external symbol __imp__ShellExecuteA@24
shell.exe : fatal error LNK1120: 1 unresolved externals
C:\>
I suppose the problem has to do with Unicode. but am not sure. Any help
appreciated.
Thanks,
Hank
// shell.c LANGUAGE = .NET 2003
#include <iostream.h>
#include <windows.h>
int main()
{
SHELLEXECUTE(NULL, "open", "notepad.exe", NULL, NULL, SW_SHOWNORMAL);
RETURN 0;
}
Results:
C:\ > CL /EHs shell.c
....... Incremental Linker Version 6.00.8447
......
shell.obj : error LNK2001: unresolved external symbol __imp__ShellExecuteA@24
shell.exe : fatal error LNK1120: 1 unresolved externals
C:\>
I suppose the problem has to do with Unicode. but am not sure. Any help
appreciated.
Thanks,
Hank