I need help compiling this code.
I have never tried programming, and I'm suing Visual Studio 2010.
I get these errors:
http://img203.imageshack.us/img203/7699/79293015.jpg
This is the code:
// feditspawn.cpp : Defines the entry point for the console application.
//
#include "stdafx.h"
#include <process.h>
#include "dinput.h"
IDirectInput8 *id8;
IDirectInputDevice8 *idid;
LPDIRECTINPUTDEVICE did;
LPUNKNOWN punkOuter=NULL;
int main(int argc, char* argv[])
{
//id8=new IDirectInput8;
// did=(LPDIRECTINPUTDEVICE) new BYTE[32768] /*DIRECTINPUTDEVICE */;
// did=(LPDIRECTINPUTDEVICE)idid;
CoInitializeEx(NULL,COINIT_MULTITHREADED);
CoCreateInstance(CLSID_DirectInput8, punkOuter, CLSCTX_INPROC_SERVER, IID_IDirectInput8W, (void**)&idid);
// id8->Initialize(,DIRECTINPUT_VERSION);
id8->CreateDevice(GUID_SysKeyboard,&idid,NULL);
idid->SetCooperativeLevel(NULL,DISCL_FOREGROUND /*DISCL_BACKGROUND*/ | DISCL_EXCLUSIVE);
printf("swapwning FEDIT\n");
_spawnl( _P_WAIT, "FEDIT.EXE", "FEDIT.EXE", "", "", NULL );
return 0;
}
If it's not too much trouble could someone please compile it quickly and upload the exe? Otherwise can you help me do it?
Re: I need help compiling this code.
Quote:
Originally Posted by
Griduser64
I have never tried programming
Yet the code you posted contains lines commented out. Who commented out those lines? If you never tried programming, why would there be any lines commented out? Only a person who has tried programming would make edits to the code like that.
Quote:
If it's not too much trouble could someone please compile it quickly and upload the exe? Otherwise can you help me do it?
And if this program doesn't work, then what?
Programming is much more than just compiling and getting an EXE. If the program doesn't work, who is going to debug it?
Regards,
Paul McKenzie