15,300 Posted Topics
Re: You don't need lines 5, 6 and 9 because fteid is never used for anything. That is not the same as the fteid on line 8. | |
Re: Good luck reading those header files :) I tried once to read MS-Windows implementation of iostream and gave up because it was so complicated. | |
Re: You can create it in any of several languages. C# might be easiest so that you can take advantage of what .NET framework has to offer. | |
Re: Its whatever Microsoft says it is. [URL="http://www.w7forums.com/dword-qword-t4621.html"]Here[/URL] is a good explanation of that. The size of a word or dword is assembler dependent, not os dependent. | |
Re: add a line at the end of main() to make the program want for you to press a key [code] int main() { <snip> // your code goes here getchar(); // wait } [/code] | |
Re: [QUOTE=sergent;1541815]Whats in there?[/QUOTE] Make a monetary donation to DaniWeb and you too will be able to enter Area 51. | |
Re: The only way I can think of to change the color of the text on every blink is to write a clock interrupt function and change the color in that function. Clock ticks about once every millisecond, so your interrupt function will want to make the change only once every … | |
Re: change it to this [code] typedef struct DictionaryList* Dictionary; struct DictionaryList { char* word; Line lines; DictionaryList* Next; }; [/code] | |
Re: I suspect that is reading the file incorrectly. If all the records in the file are of type struct menu then there is no need for 35 to 39. It just boils down to this: [code] while( infile.read(reinterpret_cast<char*>(&m), sizeof(Menu)) ) { cout<<m.idNum << m.foodItem << m.price << m.description <<endl; } … | |
Re: First you need an array of averages, as you have already coded on line 3. You will eventually want to read those values from a data file and put them into an array, but hard-coding them for now will be ok so that you can finish the rest of the … | |
Re: did you look in either the Debug or Release folder, depending on which one you compiled? It should have generated by *.dll and *.lib files. | |
Re: don't understand what you are trying to say. Variables a, b, c and d do not appear in the code you posted. | |
Re: My guess is that you are using MS-Windows and you want to compile a program written for *nix. If you install gcc or Dev-C++ you might be able to compile it ok. If you don't have one of those two compilers then your only resort is a complete rewrite of … | |
Re: windows.h will not work with turbo c++ because its too old of a compiler. There are [URL="http://www.daniweb.com/software-development/cpp/threads/371563"]other threads here about the same topic,[/URL] suggest OP read them. | |
Re: If it is for MS-Windows then start with the [URL="http://msdn.microsoft.com/en-us/windows/hardware/gg487428"]Windows Driver Development Kit (DDK)[/URL] I have no idea how much time it might take one person to do that job. | |
Re: [QUOTE=genie_02;1599017]what is the step by step procedure to make your program run... using c++[/QUOTE] Depends on the compiler and operating system. Tell us what you want to use. | |
Re: did you bother to click that link or did you just read the suggested price? | |
Re: Not usually, most libraries do not provide you with the source code so recompiling it will be impossible. In other cases when you get an open source library you will also get the source code. Check the download file to see if it already contains the binary DLL, if not … | |
Re: I don't get it. What is that +1 supposed to do (other than DaniWeb giving us activity points). Yes, I clicked it and some google box came up. But why?? | |
Re: There are several (many) sort algorithms to choose from. Did your instructor tell you which one to use? The simplest one to code is called the bubble sort, but its also the most time consuming to run. Just google for "bubble sort" and you will find example code that you … | |
Re: Look under "Legacy and other languages". COBOL is one of those ancient languages that is not used very much any more outside financial institutions such as banks. You probably won't find much help for it here at DaniWeb. You might start learning COBOL by reading some of [URL="http://www.google.com/#sclient=psy&hl=en&source=hp&q=cobol+tutorial+for+beginners&pbx=1&oq=cobol+tutor&aq=1&aqi=g5&aql=t&gs_sm=c&gs_upl=0l0l2l0l0l0l0l0l0l0l0ll0&bav=on.2,or.r_gc.r_pw.&fp=c306e119a7d85f91&biw=1079&bih=534"]these tutorials[/URL]. What … | |
Re: lines 7 and 8 are incorect. Array elements are counted from 0 up, but not including the max index number. For example scores has valid index values of scores[0][] and scores[1][] The <= operator on line 7 will attempt to dereference scores[2][], which does not exist. The correct code for … | |
Re: I don't know whether the IDE is buggy or not, but it is distributed with an outdated version of MinGW compiler and has a lousy debugger, not very programmer-friendly. Since its no longer being updated, such as with a current version of MinGW, programmers should stop using it and get … | |
Re: what compiler? Code::Blocks and vc++ 2010 Express are both free. | |
Re: what compiler are you using? what operating system? what is VBO? | |
Re: We will not do your homework for you, you need to first post what you have tried. | |
Re: You need to pass the string by reference, not by value. [icode]string login(string& pfile);[/icode] or you can catch the return value in main [icode]pfile = login(pfile);[/icode] When you do that there is no reason to have a parameter to login(). | |
Re: The function return address is in the first 8 bytes. The 8 is the offset into the stack pointer whose address is in ebp register. | |
Re: The maximum depends on the version of MS-Windows you are running. The maximum under MS-DOS was (is) 126 characters (maybe less depending on which version). I don't know the maximum for *nix, but its not the same. [quote=Microsoft]On computers running Microsoft Windows XP or later, the maximum length of the … | |
Re: [URL="http://www.cplusplus.com/forum/general/8510/"]Link[/URL] | |
Re: >>123456789123456789123456789123456789 Does the file actually look like that -- just a bunch of numbers with no separation between them? | |
Re: [QUOTE=happygeek] As for punishment that could be a fine or prison term, but then how long is a piece of string.[/QUOTE] My guess is that Mr. X is already in prison so he probably could care less about the laws of any country. Some prisons in USA are nothing more … | |
Re: probably something like below: count using normal integers but convert to base62 for display. [code] #include <cstring> #include <iostream> using namespace std; int main( ) { long n = 1234576; char buf[255]; _itoa( n, buf, 62 ); cout << buf << "\n"; return 0; } [/code] Warning: The above code … | |
Re: I agree with Narue -- VS is my favorite too, especially because of its debugging capability. But 2010 is terribly slow starting up. I recall that VC++ 5.0 had a similar problem that M$ corrected in VC++ 6.0. Hopefully they will do the same with 2010. On the rare occasions … | |
Re: for line 13 your compiler is correct. names is an array of 1024 pointers, which are unallocated, meaning they point to no memory. You will have to allocate memory for them before they can be used. An easier way to do this for your program is to just hardcode the … | |
Re: That's called burnout. Take a vacation from programming for awhile to regain your enthusiasm. It happens to everyone on occasion. | |
Re: Possibly a related problem: Using IE8, the "Unanswered Threads" and "Threads I've Posted In" buttons don't always work. Have to click them twice in order to get valid lists. The first time I click either of those buttons the browser seems to do something but when all done the screen … | |
Re: Is that your control panel screen? I don't get that link on mine. | |
Re: What processor? There is no such thing on Intel or Intel compatible processors that I'm aware of. Implementing threading in assembly language would be exceedingly difficult. Better to do it in a higher language such as C. | |
Re: Post the code you compiled. Most likely you need to add something to the end of main() to keep the program open so that you can read what it wrote on the screen. There are several ways to do that, but the most common is to add [icode]cin.get()[/icode], like this: … | |
Re: not very responsive -- I could not make it work very well. I'm on 64-bit Windows 7. | |
Re: If the application program is a console program then you may have to have a WinMain() inside the dll and call it from the dll. For example if you have a function named foo() in the dll then foo() would call its WinMain() using HINSTANCE that it gets by calling … | |
Re: Welcome to DaniWeb Allyson. Please tell us a little more about yourself, such as where are you from and how old are you. If you are in college, where? | |
Re: MFC and ATL are both pretty old libraries that wrap win32 api functions. Neither are recommended for new programs. In c++ use Windows Forms and .NET franework, or more commonly called CLR/C++. I wouldn't bother learning MFC or ATL until you work for a company that has existing code you … | |
Re: suggest reading some of [URL="http://www.google.com/#sclient=psy&hl=en&authuser=0&source=hp&q=c%2B%2B+mobile+phones&pbx=1&oq=c%2B%2B+mobile&aq=3v&aqi=g3g-v2&aql=t&gs_sm=c&gs_upl=0l0l1l0l0l0l0l0l0l0l0ll0&bav=on.2,or.r_gc.r_pw.&fp=e1768da1ce57202d&biw=1053&bih=519"]these google links[/URL]. Writing programs for smartphones requires a cross compiler so that you can do development work on a pc then transfer the program to the device. Microsoft VC++ 2010 Pro version is such a compiler (the Express edition does not support it). I think … | |
Re: >> strcpy((char*) &secret_number, aString); That should fail on most processors. Why? because you can't just simply copy the contents of a string to an integer. The contents of aString have to be converted to int using something like strtol() [edit]I think this is what Narue was talking about too :) | |
Re: Do you use sockets to read from USB port??? Please see [URL="http://www.usb-by-example.com/"]USB Design By Example[/URL] | |
The End.