Search:
Type: Posts; User: AceInfinity
Search:
Search took 0.05 seconds; generated 7 minute(s) ago.
-
Keep in mind you're using ANSI functions. There are a lot of null's in multi-byte strings... You are not using the proper functions if that's the case and most likely it is the reason why you're...
-
You can also do this:
const char *pStrings[] = { "one", "two", "three" };
You don't need strcpy() if you're using string literals, and they can be assigned directly because they have static...
-
He only mentioned DLL files. My guess is that he wants to prevent the DLL load order from being exploited so that someone can't put a malicious DLL in the startup path for it to be loaded instead of...
-
UPX is a bandaid to the problem however, the real issue here is with the default compiler options. Personally I've had cases where UPX has reversed the effect of lots of my manipulations to make a...
-
That is for a mouse event not a keypress. For keyboard and mouse you should be using the SendInput() function which deprecates both mouse_event() and keybd_event()
-
How big is your array? Why don't you just pass a container to the function which contains the order of the read?
-
The majority of that code isn't even relevant. There's hardly any translation needed to convert it to C++ because this should be it:
mouse_event(MOUSEEVENTF_LEFTDOWN | MOUSEEVENTF_LEFTUP, X, Y, 0,...
-
You just run 'make' through the terminal.
-
As jmc mentioned above, interfaces are implemented while classes are inherited. Implementing an interface basically means that yes, *this* object has *these* 'features' in simplest terms...
-
An object that implements the IEnumerable interface is one that implements the necessary iterators for constructs like the foreach structure to be used on the collection. In .NET these are called...
-
Actually no, that's not correct. *Only* the first for loop example is valid and legal code. The last 2 examples you have posted are both demonstrations of undefined behavior due to sequence point...
-
I'm curious on clarification of the highlighted parts above? C has sorting algorithms (http://www.cplusplus.com/reference/cstdlib/qsort/). But the I/O objects std::cout, etc.. for C++ are all...
-
Here's my list from my experience:
1. OOP
2. Smart pointers & RAII with the STL
3. Templates (Macro's in C can be harder to deal with)
4. Better type safety
5. References
That's a good...
-
What COLORREF is clrBackColor that you've defined, and are you sure it's a color that you are using on the form? And these are not extended class styles:
CS_HREDRAW | CS_VREDRAW
I'd suggest...
-
I would suspect that sscanf() as mentioned by 2kaud is the issue here because you never check or sanitize that input, and assume that sscanf() will initialize those values. You assume that the input...
-
You dynamically allocated those objects but never delete them which is very bad. Also, why is the class that inherits test publicly have a virtual keyword on ola()?
I would also not suggest...
-
http://en.cppreference.com/w/cpp/language/range-for
Just change it back to an iterator for loop then.
Define the iterator, move it to the next position while it's != vector end(). That code is...
-
What is the goal here exactly? This is improper code to begin with... :S
A vector of type B doesn't mean that they are initialized right away, you need to do this manually to populate the...
-
Just because the code compiled doesn't mean it is okay. From what I seen there was lots wrong with the structure of your application design. If you want to learn better ways of writing the...
-
You don't need to escape every '\' if you use verbatim strings:
objSaleFileWrite.WriteLine(@"\si");
-
What did your code look like? C++ uses & for reference parameters.
-
No, because that would eliminate all possibility of you actually taking the time to figure it out and learn something. Read the documentation and see which handles are passed to what functions, and...
-
Enumerate the processes with CreateToolhelp32Snapshot(), Process32Next() / Process32First() until you find the process that you're looking for then call TerminateProcess()... It's not that difficult.
-
You should have read earlier posts first. He wrote the explanation for that here:
-
Where is the message loop exactly? You need to first understand the event based model. There's tons wrong with this, although I can't help you with this based on my current understanding of your...
-
Actually I agree with boop boops here as well. Rectangles are not the basis of drawing efficiently anymore. Newer gaming engines are reluctant to use rectangles as a base drawing model because it has...
-
These are still not user defined types... Imagine trying to convert a collection wrapper to a boolean? How would you do that? Or better yet, why? You don't know what this user defined type was meant...
-
dunfiddlin pointed out that the answer was given to you. If you don't see how to implement the solution, or you don't attempt to do it, how will you understand how to manage that solution even if...
-
No, i changes on this line:
i /= 10 / 1;
So after the initial:
n = i;
n is no longer equal to the value of i anymore. i = i / 10 / 1.
-
I've used AutoCAD before btw. It's quite an advanced program once you get into functions and all that good stuff. I'd taken a course and was a designer a while back. I haven't used much of it lately...
-
There's a good reason this should never be attempted in the first place however. That is over the top, and would only make the efficiency of the language worse. If the user defined type is meant to...
-
i = 0
For i = 0...
Seems a bit redundant. Although for explicitly defining the array size, you can calculate the size of the number by doing this:
Dim digits As Integer =...
-
Huh?
You'd better make sure that this works for the cases I've hinted at above. What do you mean by "share the mingw compiler with my new language"? I thought the intent was to create your...
-
C++11 just means that you'll need to be able to compile with C++11 standards, if this is supposed to be distributed to others for use, and those people may not like to use C++11 yet, or they just...
-
This is because the OnPaint() method fires early on when the form is created, you can't control that, what you can do is set a boolean that is evaluated the next time the control is drawn however,...
-
I wrote a very simple Pong game simulation a while back: http://tech.reboot.pro/showthread.php?tid=3594
http://i.imgur.com/2cBZa.gif
Perhaps it'll give you some ideas. The graphics themselves...
-
The point here is that SpecialFolder is an enum, and JMC is pointing out that you're not reading the documentation to see why it's returning a numeric value, even though it should (because it's an...
-
Try the HEVC (H.265) encoding and see what the output is. H.264 is still pretty good otherwise. The only thing is, I've been hearing high CPU usage from the HEVC format, even though it is supposedly...
-
You need to read about how preprocessor directives like include work first to see why I've done it this way. All it does is allow the compiler to essentially replace that spot with the #include'd...
-
Ahh, I didn't notice the methods being used, I just seen the regular IO stuff, and there was no mention that this was ASP.
|
Click Here to Expand Forum to Full Width
|