erifash Posted December 15, 2005 Posted December 15, 2005 (edited) How do I use AutoItX with C++? I know you have to #include <AutoIt3.h> but when I try and compile it gives me undefined function. Does it have something to do with the AutoIt3.lib file? I searched around and heard about that a little bit. I just don't know what to do, I am a noob at C++. I have Dev-C++ v4.9.9.2. Thank you. Edited December 15, 2005 by erifash My UDFs:_FilePrint() | _ProcessGetName() | _Degree() and _Radian()My Scripts:Drive Lock - Computer Lock Using a Flash DriveAU3Chat - Simple Multiuser TCP ChatroomStringChunk - Split a String Into Equal PartsAutoProxy - Custom Webserver
nfwu Posted December 17, 2005 Posted December 17, 2005 Why don't you look at "C:\Program Files\AutoIt3\AutoItX\StandardDLL\VC6\Example\" ? Try copying and pasting the folder somewhere else and using that as a starting point. TwitterOut of date stuff:Scripts: Sudoku Solver | Webserver | 3D library (Pure AutoIt) | Wood's GadgetsUDFs: _WoodUniqueID() | _DialogEditIni() | _Console*() | _GetIPConfigData() | _URLEncode/Decode()
erifash Posted December 17, 2005 Author Posted December 17, 2005 Thank you! My UDFs:_FilePrint() | _ProcessGetName() | _Degree() and _Radian()My Scripts:Drive Lock - Computer Lock Using a Flash DriveAU3Chat - Simple Multiuser TCP ChatroomStringChunk - Split a String Into Equal PartsAutoProxy - Custom Webserver
erifash Posted December 26, 2005 Author Posted December 26, 2005 (edited) I just got back from my vacation and I tried to compile the example provided with the version of Dev C++ mentioned earlier and it throws undefined function errors for the four functions used in the example. I am no C++ expert so would someone please be kind enough to explain to me why this is happening and how to fix it so it works? Thank you for your patience. Edited December 26, 2005 by erifash My UDFs:_FilePrint() | _ProcessGetName() | _Degree() and _Radian()My Scripts:Drive Lock - Computer Lock Using a Flash DriveAU3Chat - Simple Multiuser TCP ChatroomStringChunk - Split a String Into Equal PartsAutoProxy - Custom Webserver
nfwu Posted December 27, 2005 Posted December 27, 2005 (edited) Using Dev C++? Now i see, slightly more complicated than Visual C++. The all the files come from the Sample directory at "C:\Program Files\AutoIt3\AutoItX\StandardDLL\VC6\Example" on my system. So the steps are: 1. Create new project (File>New>Project, then Empty project) 2. Add "AutoIt3.h" to project. (Project>Add to Project, Select file "AutoIt2.h") 3. Add "AutoItX3.lib" to linker options (Project>Project Options, select the Parameters tab. Click "Add library" and select "AutoItX3.lib") 4. Program as normal and add your *.cpp files to the project (or try out the sample by adding the main.cpp to the project) EDIT: Sample Directory Path Edited December 27, 2005 by nfwu TwitterOut of date stuff:Scripts: Sudoku Solver | Webserver | 3D library (Pure AutoIt) | Wood's GadgetsUDFs: _WoodUniqueID() | _DialogEditIni() | _Console*() | _GetIPConfigData() | _URLEncode/Decode()
erifash Posted December 28, 2005 Author Posted December 28, 2005 (edited) I followed your steps to the word then I clicked Project>Add to Project and added the main.cpp from the example. I am still getting linker errors about 'undefined refrence's to the functions used. It will be nice if I could just get this working... P.S. - To compile I just hit ctrl+F9. Edited December 28, 2005 by erifash My UDFs:_FilePrint() | _ProcessGetName() | _Degree() and _Radian()My Scripts:Drive Lock - Computer Lock Using a Flash DriveAU3Chat - Simple Multiuser TCP ChatroomStringChunk - Split a String Into Equal PartsAutoProxy - Custom Webserver
nfwu Posted December 28, 2005 Posted December 28, 2005 (edited) I personally use Microsoft Visual C++, and find no problems with it. Sorry i can't help. EDIT: Not even Dev C++'s "File>Import>MS Visual C++ Project" works for this project! That's completely strange... Edited December 28, 2005 by nfwu TwitterOut of date stuff:Scripts: Sudoku Solver | Webserver | 3D library (Pure AutoIt) | Wood's GadgetsUDFs: _WoodUniqueID() | _DialogEditIni() | _Console*() | _GetIPConfigData() | _URLEncode/Decode()
erifash Posted December 28, 2005 Author Posted December 28, 2005 What commands should I use to compile the example? The MS Visual C++ I have does not have an IDE. My UDFs:_FilePrint() | _ProcessGetName() | _Degree() and _Radian()My Scripts:Drive Lock - Computer Lock Using a Flash DriveAU3Chat - Simple Multiuser TCP ChatroomStringChunk - Split a String Into Equal PartsAutoProxy - Custom Webserver
erifash Posted December 28, 2005 Author Posted December 28, 2005 Okay, nevermind. I figured out how to get this working with Dev-C++! Everything required to do this is in the zip file attached (Read the README for instructions). My UDFs:_FilePrint() | _ProcessGetName() | _Degree() and _Radian()My Scripts:Drive Lock - Computer Lock Using a Flash DriveAU3Chat - Simple Multiuser TCP ChatroomStringChunk - Split a String Into Equal PartsAutoProxy - Custom Webserver
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now