560 Posted Topics
Re: Try catching a: [url]http://msdn.microsoft.com/en-us/library/system.stackoverflowexception.aspx[/url] | |
Re: I would consider creating a DLL for commonly used functions. | |
Re: Unfortunately without researching the HTTP RFC spec you may not be dealing with those things at a low level. There are a number of free libraries available for using HTTP, it may be worth a google search. | |
Re: [quote]Yes, but you'll have to reverse engineer their code to figure out where to insert your detour/trampoline function.[/quote] Hey that big block of NOOPs looks pretty good... | |
Re: Personally I would opt to use a library for HTTP. I know libcurl is at least one option, there are probably hundreds more. The reason I would use a [i]library[/i] is because if the project requires using the HTTP specification extensively, it will save you a lot of work. You … | |
Re: how to use typedef with a function pointer: [code] typedef void (*FuncType)(void); ... ... FuncType pointerToMyFunc = foo; [/code] | |
I'm just wondering how programmers rate their own skills, for instance I haven't been using C# very long, but I do feel I have a good grasp on the language. If I see on a job listing: "* 3+ years C# or Visual Basic.NET " What the heck is 3+ … | |
Re: I'm not aware of any. I suppose you could hire a programmer. | |
Re: This is a very pathetic question. The rules say you should give your post a descriptive name not "Need help". For Screen capturing, it can easily be done in C#. For packet capturing data being transmitted across WIFI that contains remote desktop information, I'm not sure this is the right … | |
Re: Typically you will get bad results if you call srand() too often. I've seen it used in a loop or a function right before every call to rand(). Try calling it once for the lifetime of the program. | |
Re: I think he means the data structure call the "map" in C++. [url]http://msdn.microsoft.com/en-us/library/xfhwa508.aspx[/url] Check out the "Dictionary", and maybe other classes. | |
Re: IRC, (AKA "Multiplayer Notepad") isn't really "cool" or "hip" these days. I am kind of fond of the idea, but unless I have a browser-based IRC client, I will be reluctant to visit often. Just because I won't ever open the IRC client, not because I don't like the chat. … | |
Re: If using Windows.... Does this help? [url]http://www.codeproject.com/KB/winsdk/harddiskspace.aspx[/url] How about this? [url]http://msdn.microsoft.com/en-us/library/aa364935(v=vs.85).aspx[/url] or this? [url]http://msdn.microsoft.com/en-us/library/aa364937(v=vs.85).aspx[/url] see also this: [url]http://support.microsoft.com/kb/202455[/url] You will probably need only to include <windows.h> | |
I have a DataGridView on a form that updates the datagridview automatically and will allow the user to manually edit the information. I need to save the information in the DataGridView somehow. I don't know what the best option would be. I could of course use a file to store … | |
Re: At least make the effort to put into words what you're too lazy to do. | |
First of all, what is a "data source", the kind that can be attached to a "DataGridView", what are they used for, and how can I use one? | |
Re: Please see this page for more algorithm information: [url]http://en.wikipedia.org/wiki/Quicksort[/url] | |
Re: It doesn't "send" anything as far as I know, and if it does, it's probably dependent on the implementation--which you shouldn't concern yourself with. It "returns" an [b]iterator[/b] to the first element in the vector [b]container[/b]. For example: [code] std::vector<int> myVec(10,7); std::vector<int>::iterator it = myVec.begin(); for( ; it != myVec.end(); … | |
Re: std::string is a C++ class (or maybe a typedef'd class template). It's not a C style "string". Notice the C++ string has member functions that can be accessed via the direct member access operator ([b] . [/b] ). i.e., [code] std::string input; std::cin >> input; std::cout << "Size =" << … | |
Re: Lambdas are awesome. [code] auto lam = [](const char *str) { std::cout << str << std::endl; }; lam("Hello World!"); [/code] | |
Re: Will the std::stringstream convert the portion you're working with to __int64 ? | |
I only know a little bit about the Global Assembly Cache. After creating a WPF application, in the toolbox, if you right click and select "Choose Items", it will open a window in which you can specify controls you want to use that are in the GAC. Is it safe … | |
Re: Or maybe Application::Run(gcnew John()); | |
Re: If you're using Windows you will probably want to use "SendInput" in the Windows API | |
What is the meaning of "immutable" when relating to an Int32 ? Int32 i = 0; i++; //etc | |
Re: I think that happens when an exception is thrown that isn't caught. Had that message from a VS2008 app once before. | |
Re: Unless this is an assignment I would use a library to do this. Otherwise, some creative design could likely solve the problem, you may want to work out some pseudo-code for the entire program. It may go something like: -order-of-operations scan, instantiation of evaluator class if required. Innermost expression is … | |
Re: May want to check the file stream for errors also. Could re-design loop to be: [code] while( inFile >> tempInt )//<-- exits loop on error, possibly what you want. { if( (tempInt + sum) > 1000 ) break; //... } [/code] | |
Is there a way to store binary code in memory (as a value) then execute it? For instance if I have an array of bytes I have filled with the binary code of say, a .exe, is it possible to execute it? | |
Is there a way to store binary code in memory (as a value) then execute it? For instance if I have an array of bytes I have filled with the binary code of say, a .exe, is it possible to execute it? | |
Re: I usually opt to use the Thread class, with mutexes, [url]http://msdn.microsoft.com/en-us/library/system.threading.thread.aspx[/url] and with a function and delegates. Delegates will probably be needed to access any controls on your form because the controls must be accessed on the same thread they were created. You can define a custom delegate for a … | |
Re: I do that all the time, except using a Mutex. I'm extremely new to C# and only today learned of the "lock" statement. From what I've read about multi-threading in C# you may not want your _Status to be static. I searched google again and couldn't find the exact page … | |
Re: I agree with using both an "ifstream" and an "ofstream" because it will simplify the process of reading and writing; if one used "fstream" for both i and o, it will most likely complicate things more. | |
Re: What exactly are you wanting? What are you having trouble with? What do you need improvement in? | |
Re: I see this all the time, and I hope by me explaining it, will make it clear to you. After creating an array like so: [icode]char buffer[10] = { 'a','b','c'};[/icode] when you use the operator[] ( [ # ] ) you are accessing a SINGLE ELEMENT. No matter how you … | |
What happens when an exception is thrown from within a new thread of execution? How do I catch it? Must it be within the same thread? Also, what is the proper way to update a control residing on a form, from within a new thread? I think it would be … | |
Re: loop through it and make sure at least one character isn't a space would also tell you. Oh, and it's "Your" instead of "You're", you're = you are | |
Re: [url]http://msdn.microsoft.com/en-us/library/system.net.networkinformation.ping.aspx[/url] | |
Hey guys, I'm making a global operator, and I have a line where I'm comparing a std::string::difference_type to a std::string::size_type, I think the difference_type is usually a signed integer, and the size_type an unsigned.. Any ideas for an algorithm change? Also, there is a lambda function used I would like … | |
Is there any way to add a disclaimer using the "Publish" feature of Visual Studio 2010 ? I just kind of fear someone will claim the application damaged their computer and try to sue me or something, it's unlikely anyone would, but I suppose it could happen. If not, what … | |
Re: percent[i] = totalvote; that isn't correct. Try making it a percentage based on totalvote and the number of votes they actually got. | |
Re: [url]http://msdn.microsoft.com/en-us/library/ms747027(VS.85).aspx[/url] | |
Re: If I'm understanding the problem correctly the solution is pretty simple. want all your "words" in the string in different strings or something? [code] #include <iostream> #include <string> #include <sstream> #include <vector> typedef unsigned int uint; //Returns, Num. words. uint getWords(std::string &in, std::vector<std::string> &words){ uint count = 0; std::stringstream ss(in); … | |
Re: I agree with [b]cscgal[/b] on her thoughts about the two. Fortunately, I will also be attending a university in the fall for CS, so it may become more clear to me. | |
Re: Just a suggestion since you're using C++, why not use templates instead of void pointers ? | |
Re: Use [b] [noparse][code] /* code here */ [/code] [/noparse] [/b] | |
Re: There is a "for each" in C++/CLI. In C++ we do have a function named that: [url]http://www.cplusplus.com/reference/algorithm/for_each/[/url] | |
Re: hmm, You must not be aware that there are thousands of free C++ libraries available. Alternatively your Operating System's API may actually support playback of MP3 sound, otherwise google a C++ sound library that meets your needs. | |
Re: You need to use the .c_str() member of the std::string class to generate a NULL-terminated C-style "string" from the memory the std::string class is managing for you. I would also suggest a polymorphic approach to parsing expressions like that, specifically using polymorphically a member function to return the result of … |
The End.