462 Posted Topics
Re: Install a 64 bit compiler on the 32 bit computer, at the top where it shows debug and release, there are options like x32 x86 x64.. choose x64 a for pure 64 bit version of the program | |
Hi All, Im new to threading and forms and really bad at API. Jonsca pointed me to Backgroundworker because my original problem was to constantly check if a window is open. If it is open, terminate my program. I failed at that so I tried Hotkeys. The problem is: My … | |
How do I find a window by partial title.. or if the title contains a certain word.. I was thinking GetWindowText but that requires that I have the handle already.. I was going to enum windows I think that I can search for a window title containing the string.. if … | |
Re: I believe he is trying to do this: [CODE] #include <iostream> using namespace std; char Package; int main() { cout<<"Choose a package: 1 = Package A, 2 = Package B\n"; cin>>Package; //This is how u get the user choice.. if(Package == '1') //I guess u mean split choice by if … | |
The code below is from my form.. I declared a string GLOBALLY.. Then upon FormLoad, It inserts values for the string... When I do button click, the string is blank.. Why is it blank? Shouldnt the Values from FormLoad Event be in it? : [CODE] public ref class Form1 : … | |
Can someone explain why it wont find the window?? I did everything right, Im pretty sure of it :S Yet it just wont find it. EDIT: Admin delete.. I think I just figured it out.. [CODE] private: System::Void Form1_Load(System::Object^ sender, System::EventArgs^ e) { Form1::Visible = false; Query ^ F = … | |
K I just got this Idea that I want to implement into a program I downloaded. Yes the program is open source but I dont wanna compile it, I just want to sort of Inject?.. What I want to do is add a button to the program and have the … | |
Re: Not really a question?? Explain what u want properly.. The code above shows me nothing except that you have it set up like a telephone thats all.. and it prints a corresponding number when the person types a letter.. What exactly do u want? you can do something like after … | |
I've download this following program source from a SVN repository.. [url]http://blanddns.no-ip.org:81/repos/public-smart/[/url] How do I compile it?? I've tried but it has c++ and java files included in it.. and some are even in separate folders. Can someone tell me how? Do I have to do command line? Do I need … | |
Re: Ummm First off dont Use Goto because it skips over a bunch of code... Use function-prototypes or else make a function with the mainmenu before int main().. Second why not use Switches and Cases? I will test it.. Edit: Your problem was the GoTo.. it skips over the code.. and … | |
Re: LOL where is the source code... how can we know what the program is doing just by u giving us a name?? And please insert the source code into code tags.. | |
Re: Dont know if thats even possible but I do know how to make the DLL a resource and then have the program extract the Dll when needed... Your basically asking for the decompilation of the DLL | |
KK I've been using mouse_eventf for clicking buttons in another application.. To do this I've done GetClientRect to get the size of the client and then click the button at a certain distance from one edge of the client... What I noticed that is that if the user's computer is … | |
Re: I dont know how to get binary code from memory or anything but I do have code that can extract a binary from resources if that helps.. | |
Is this possible to embed a console into the gui like the picture below?? If so I wanna know how. [img]http://img229.imageshack.us/img229/6995/cmdahk.jpg[/img] found it here: [url]http://www.autohotkey.com/forum/topic45935.html[/url] | |
Hello everyone, I have one question.. should be relatively simple but I just cant seem to find any info anywhere.. maybe Im just looking in the wrong place and need guidance.. Here is my problem.. I have the following code: [CODE] EnableMenuItem(GetSystemMenu(GetConsoleWindow(), FALSE), SC_CLOSE , MF_GRAYED); DrawMenuBar(GetConsoleWindow()); GetSystemMenu(GetConsoleWindow(), FALSE); //Disables … | |
Re: add this to the top of your code: [CODE]#include <iostream> //U already have iostream so no need to put that again.. but put the following: using namespace std; //Without this, every line beginning with cout would have to be replaced with std::cout.[/code] *sigh* No offense or anything.. You are better … | |
Re: Post the code here?? Like the entire thing.. or the .cpp file or both. | |
Re: In main, you have not declared what type x is.. whether is is int, double or float.. I have declared it for u as int type as your other functions show that you want it as int. invalid initialization of reference of type ‘std::string&’ from expression of type ‘int’ thats … | |
![]() | Re: I noticed that in the first code posting, you had if(moneyA == half) you didnt have the && index>= quantity. Did you do that purposely? ![]() |
Re: [CODE] int ComputeArea( int length, int width ) { int area; area = length * width; return length; }[/CODE] That should definitely not return length.. it should actually return area.. and is messing up your calculations.. Also to round up the amount of gallons: [CODE] int FindGallons( int paint_area ) … | |
This is the function in question... What happens is the user opens notepad, if notepad is open then they are required to type a password.. If its invalid, notepad is closed.. if the password is valid, it continues.. else if the user hasn't entered a password within 10 seconds, timeout.. … | |
Re: [QUOTE=beejay321;1482872]i dont understand any of that[/QUOTE] Check out the isdigi() and isalpha() functions please.. To understand the code below.. The guys above are absolutely correct but clearing the input buffer will not help here.. instead a work around is to declare choice as a char and then to call isdigit() … | |
Basically If the user does not enter a string or character or press any keys after a certain length of time, program will goto or ask again.. or do whatever.. Problem: Not allowing the user to enter input.. Note accepting user input.. [CODE] #include <windows.h> #include <stdio.h> #include <iostream> using … | |
Re: Well you see the thing is when getting process by id, the ID can change when the process restarts or exits depending on if another program already took the id during that interval. Meh Just look at how to Enumerate processes and look here: [url]http://msdn.microsoft.com/en-us/library/ms683215[/url] [CODE] int isRunning(char *pProcessName) { … | |
Hi everyone, I made a program that will check if a process is running.. it is supposed to detect if a process is running and start a timer. If the process has been ended, the timer is paused.. when the process is restarted, the timer continues from where it last … | |
Re: :S been 11 hrs and no one replied.. I guess I'll go by the title of this thread "run a cmd code in mfc app" cmd commands would be as useful as using system(); so for the cmd command: taskkill /F /IM notepad.exe you would write in c++ system("task kill … | |
Re: Meh it works except... If u enter "pluto" instead of "Pluto" (capital letter P).. then it gives u an error and asks u to re-enter the planet name.. Other than that, it works as it should.. Another thing: If I enter a decimal, it wont work as the weight is … | |
Re: Uhhh I will help u.. I have noticed u got the math wrong.. U havent thought of what happens if the person enters 12, 24, 36 inches (multiples of 12).. then to convert that to feet.. What if the person enters 15 (its greater than 12 but not a multiple).. … | |
Re: Uhh Try putting a location in the program like C:/Users/fdnsdnlgds/data.in as for why its not grabbing the data... I dont know.. I usually use getline(); Used to have these problems.. try checking this thread: [url]http://www.daniweb.com/forums/thread283874.html[/url] | |
Re: psh lol thats not complicated at all.. also what kinda of code they want it in?? MFC? API?? Windows Form??? | |
Re: as far as I see, he needs == instead of = as he is declaring them as int and double.. Making them equal a number rather than comparing them to true or false. As for the char* cant be converted to char[30] thats an error on his part at [CODE] … | |
Re: :S Linux compiler?? Mingw?? I dont got the wait.h header nor the unistd header. Or else I'd compile it.. For anyone trying to help him, this is a linux system he is compiling on.. | |
Note: I program in C++ Not C#. In visual studio 2010, Where u press release or debug, next to it has a box with win32.. How can I change it to x86.. I tried pressing New and edit and stuff and configuration manager but it doesnt have the x86 choice... … | |
Re: You can use cases.. [code] #include <iostream> #include <string> using namespace std; char nSel; void getinput(); int main() { cout << "\tAurDown v2.1\n" << "\tLicense: GPL3\n\n" << "Menu\n" << "1. Search for package\n" << "2. Download a package\n"; cout << "Enter Selection\t"; getinput(); return 0; } void getinput() { cin>>nSel; … | |
Re: Edited: Forgot to log in before writing out this post.. so now it looks messed up as hell so I dont wanna rewrite it but I hope it helps! mhmm Open visual studio, press ctrl shift N or else just press file -> New -> Project Create a "WINDOWS FORM … | |
Hi Everyone, Im using visual studio 2010 windows form application. I created a windows form application to add and remove files to a directory on the click of the button1. The problem is that when I put it on a different computer, it can never find those files.. Its supposed … | |
Re: [CODE]int isRunning(char *pProcessName) { HANDLE hSnap = INVALID_HANDLE_VALUE; HANDLE hProcess = INVALID_HANDLE_VALUE; PROCESSENTRY32 ProcessStruct; ProcessStruct.dwSize = sizeof(PROCESSENTRY32); hSnap = CreateToolhelp32Snapshot(TH32CS_SNAPPROCESS, 0); if(hSnap == INVALID_HANDLE_VALUE) return -1; if(Process32First(hSnap, &ProcessStruct) == FALSE) return -1; do { if(stricmp(strupr(ProcessStruct.szExeFile), pProcessName)==0) { CloseHandle( hSnap ); return ProcessStruct.th32ProcessID; break; } } while( Process32Next( hSnap, &ProcessStruct ) … | |
Using Windows Form Application from Visual Studio 2010. KK The big problem... When I compile it and run the program, Enter a value into the textbox, it automatically changes to a value the program has defaulted. I'll attach the Program/Project Folder incase anyone wants to compile/run it.. Example: Two textboxes.. … | |
The code below is what I'm having problems with... The combobox part is getting me angry and i've searched everywhere, code guru, msdn, stackoverflow, daniweb... And I cant figure it out. Its for a game my friend plays. I play and quit on and off.. I decided to do a … | |
Re: Well first off main() cannot be void... it must return int... so I changed it to [CODE]int main() //changed void main() to int main() { ............. }[/CODE] Also the code below needs redeclaration of i cuz its declared in the first for statement and it is not in scope in … | |
This is a program that is supposed to run on startup when the computer turns on... What I did was I put the name of the program in the RunOnce Registry key attached below... when u double click the key, it puts the program name in the registry telling it … | |
KK the code below is a loop part of my main program I just cut it out and made it compilable.... This is the problem... When the user enters a number greater than 2, its supposed to tell them to retry because that was not in the options menu... that … | |
Below has the source code to the program Im writing... anyway I want to do this... I want to be able to include a file from the project in my executable... Example: If I put the program on a different computer, I want it to able to open a file … | |
Hey guys I found the following code snippet below... I want to know how to compile this... I am a c++ programmer and something is wrong with my mouse/audio so I thought this may programmatically solve it but I have no clue about anything java and in c++ there is … | |
kk so I am having a problem on a mac where the audio doesnt work very well unless my finger is on the touchpad... it works perfectly smooth... I want to write code to detect whether the finger is there or not and if it isnt then move the mouse … | |
SKIP to LINE 117 [CODE] #include <iostream> #include <windows.h> #include <fstream.h> #include <stdio.h> #include <stdlib.h> using namespace std; char n , p , m , L , F , E; int v , x , y , O , z , q , R; int main() { SetConsoleTextAttribute(GetStdHandle(STD_OUTPUT_HANDLE), 14); cout<<"This … | |
Ok here is what I want... I want to read the Dictionary file, and output its contents into the dynamic-text.dat file... But it reads the dictionary file and it will not write to the dynamic-text.dat file and I have no clue why... what am i doing wrong.. when I split … | |
Re: If you tellme what exactly your math books says... or at least what the equation represents I can help you from there but just a picture isnt gunna cut it as I cant find that formula anywhere on google... Though just looking at it im pretty sure its one of … | |
Re: [B][U]adhruv92 [/U][/B] First And Last Time: I did [B]NOT[/B] do this to actually do you homework for you, the reason I actually did it was for a C++ refreshment in math, secondly I thought since no one else will actually help you, I can give you an idea of how … |
The End.