Hello everybody! I am new to the community. I need your help. Everyones help. would really appreciate it if someone could send me the code of a program that will do the following:
+Open a file in a given location.
+Press three times tab.
+Enter a number in a field.
+And press enter at the end.
Please it is of great importance to me so if you can help by all means do!
Thank you very much all of you who are willing to try and help me!
To open a file, you need to create a stream. Is this for input or output?
For the other items, I'm not sure what is supposed to happen. It sounds like you might be using Visual C++, but it is not clear whether you or the program presses tab three times, what is to happen to the number in the field, or what happens when you press enter.
Hints for any program: First, be sure you completely understand the problem. I'm not sure you do, I certainly don't. Second, understand how to solve the problem if you were to do it by hand. Include all the information you would have to keep track of, and every step you would follow. Third, implement the solution you would do by hand in the program. Finally, test the solution. Note, you cannot do steps 2-4 until AFTER you have done step 1. Sometimes you will run into a roadblock and have to go back to step 1, if you realize that you didn't understand part of the problem.
well I want the program to give input into a file after the program presses three times tab and then give the number as input. finaly the program will hit twice the enter key. if you could please help me I would be most gratefull...
Are you using Visual C++, Borland C++, or something else? This will affect how you perform the input. For doing this in a command line, you will not be able to use std::cin, since tabs count as whitespace. You will have to use the getline function. I'm assuming the user is supposed to be pressing these keys, not the program.
I am using Visual C++ and I want it to be automated. I mean that the program will do all of the above that i have already mentioned. It will open the file, it will press three times tab, it will input a number in the field that the pointer will be at that specific moment and it will press twice enter.
That sounds like it's opening a file in notepad and issuing mouseclicks to notepad... somewhat more complicated.
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks