Posts
 
Reputation
Joined
Last Seen
Ranked #4K
Strength to Increase Rep
+0
Strength to Decrease Rep
-0
83% Quality Score
Upvotes Received
5
Posts with Upvotes
5
Upvoting Members
5
Downvotes Received
1
Posts with Downvotes
1
Downvoting Members
1
3 Commented Posts
0 Endorsements
Ranked #2K
~20.4K People Reached
Favorite Tags
Member Avatar for VBNick

I just finished up writing a class to encapsulate a pointer-to-pointer that provides auto-release functionality like shared_ptr<T>. I'm curious though, does something like this already exists, in the standard library, boost, ect? I know the idea exists, because in the Unity Engine, when you call Destroy(gameObject), any and all references …

Member Avatar for VBNick
0
143
Member Avatar for kspecks

So here is something I am writing just to get back into code and I can't find the flaw with it. [CODE] template<typename T> class Array { public: Array(unsigned arraySize): data(0), size(arraySize) { if(size > 0) data = new T[size]; } ~Array() { if(data) delete[] data; } void setValue(unsigned index, …

Member Avatar for VBNick
0
311
Member Avatar for tgifgemini

[B][/B] Hi all, I am trying trying to make both the "Tab Key" behave as the "Enter" key. keys. In otherwords, both the Tab and Enter should acheive the same objective. I am using the code below but only the "Enter" key is working, but the "Tab" key is not …

Member Avatar for zebnoon
0
3K
Member Avatar for VBNick

Hi, if anybody has a second, I have a quick question: In the following situation, Container can contain any combination of the derived classes. If I wanted to go through "Container", for example, and delete all instances of the class DerivedC, how would I do that? [CODE] class Base; class …

Member Avatar for VBNick
0
229
Member Avatar for VBNick

Hi. I was wondering if someone could offer a bit of advice on this. I have made a web server, and everything seems to be done correctly as far as I can tell. It works and loads web pages just fine. The problem is, that when big files are requested …

Member Avatar for VBNick
0
267
Member Avatar for Peter_morley

I'm having trouble displaying a string and integers through the use of stringstream. The code below displays fine as is but say I put in << endl after name. When I compile this it only displays the name string and thats it. If I add a space in any of …

Member Avatar for Peter_morley
0
234
Member Avatar for ramkumar0022
Member Avatar for VBNick

I was trying to make a for loop count down backwards using this loop, but when it gets to zero, instead of realizing that decrementing will bring the number below zero, it tries to make the unsigned short (-1), which is actually 65535 as unsigned. of course, this code produces …

Member Avatar for William Hemsworth
0
170
Member Avatar for Glass_Joe

[ATTACH=RIGHT]17038[/ATTACH]Goonies aren’t the only ones that never say die. [I]Duke Nukem Forever[/I] has finally seen the light of day after what will be 14 years coming upon its newly anticipated 2011 release date and 923859023 jokes later about how the game has taken “forever”. And in local news, pigs are …

Member Avatar for cmliu2004
0
195
Member Avatar for VBNick

I have a simple web server built, and I created a status window that runs on a separate thread. If I have a list of structs being updated by the main thread, is it ok to read(only read) from those structs from the second thread for the purpose of getting …

Member Avatar for mike_2000_17
0
181
Member Avatar for VBNick

If I am using overlapped sockets with i/o completion ports, is it ok to use WSASend on a socket to send data [B]after [/B]posting the initial WSARecv on that same socket, but [B]before [/B]having received any data? Will the socket still receive data and trigger the completion port if I …

Member Avatar for VBNick
0
91
Member Avatar for VBNick

I have read all the MSDN docs on this subject that seemed relevant, but I am still confused about a few things. I am trying to achieve functionality like WSAAsyncSelect(), but use a separate thread instead of the main window. Can I use the regular WSAEventSelect() for this? and if …

0
47
Member Avatar for rv_mup08

im newbie in C++ i have a project about how to get the Total Number of HOurs Worked From inputed Tine in and Time out Time in Format: 08:00 Time Out Format:12:00 Input From Monday to Friday DTR Output must be Display the Total no. of Hours worked: 102:59 --->Example …

Member Avatar for rv_mup08
0
2K
Member Avatar for VBNick

Hullo. I made a small webserver just to flex my winsock muscle, but it only works for small files like html files. Once I have processed the request to get the path of the file, I send the result like this: [code] ifstream fin; fin.open(URL, ios_base::binary | ios_base::in); if (!fin.good() …

Member Avatar for VBNick
0
170
Member Avatar for VBNick

hi, I put together a small app to try using SEE in assembly, but I am getting the wrong output. these are the .cpp file and the .asm file [code=cpp] #define WIN32_LEAN_AND_MEAN #include <iostream> using namespace std; extern "C" int *myFunc(float *a, float *b, float *result); int main(int argc, char …

Member Avatar for VBNick
0
135
Member Avatar for VBNick

Why does the debugger stop execution and give an error when WaitForSingleObject() is called on a closed HANDLE?? when I run my program outside of the VS2010 IDE, WaitForSingleObject(invalid handle) just returns WAIT_FAILED like its supposed to. Is there anything actually wrong with calling it on an invalid handle?

Member Avatar for VBNick
0
2K
Member Avatar for VBNick

can anyone tell me why this would freeze? I'm trying to find a way to terminate a thread from outside of it, and allow the main program to do garbage cleanup, like closing any HANDLEs used or freeing any memory allocated. I trigger an event which should cause that loop …

Member Avatar for VBNick
0
99
Member Avatar for broli100

Hi, I want to put GLSL shader in my game to get realistic shadows and lighting. But when I use polygons GL_POLYGON ,they are totally black. Only thing that works OK with shader is glutSolid bullshit like glutSolidTeapot and glutSolidCube and so on. So I wanted to know the source …

Member Avatar for broli100
0
252
Member Avatar for VBNick

I just finished a small winsock program for sending files, but its soooooooooooooooooooooooooooooooooooooooooooooooooooooooo slooooowwwwwwwwwwwwwwwww:yawn: so I am hoping someone here may be able to offer me some advice. so far, the program works as follows: 1. User1 chooses a file and attempts to send it. 2. User2 chooses to accept …

Member Avatar for VBNick
0
638
Member Avatar for VBNick

I made a simple app to turn off a monitor. The entire program consists of just this: monoff.cpp [code] #include "windows.h" #define MON_OFF 0x2 int CALLBACK WinMain(HINSTANCE hInstance, HINSTANCE hPrevInstance, LPSTR lpCmdLine, int nCmdShow) { SendMessage(HWND_BROADCAST, WM_SYSCOMMAND, SC_MONITORPOWER, MON_OFF); return 0; } [/code] For some reason it still wont run …

Member Avatar for VBNick
0
281
Member Avatar for VBNick

I need a little help with this :icon_redface: if I use ifstream::read() and go past the end of the file, how do I tell how many chars have been read? thanks, Nick

Member Avatar for VBNick
0
244
Member Avatar for Member 785530

Hey, i want to display live x and y values on a C++ form in vs2008 and want to control windows mouse pointer through the x and y values my program is generating. Need help. Thanks

Member Avatar for jonsca
0
112
Member Avatar for vlad44

hi all, i was trying to write to a pre existent binary file but every time it would change the size of file and remove all of its contents so what i should i do????? here is an example to what i'am trying to say(it is not exactly the same …

Member Avatar for vlad44
0
109
Member Avatar for VBNick

I have a small test program made, and it actually fully works. It connects, and you can send messages back and forth.....but for some reason, when I call connect(), It returns SOCKET_ERROR, but connects, and works fine anyways. Does anyone know why? here is the code: see lines 160, 161 …

Member Avatar for VBNick
0
217
Member Avatar for mayank101505

how to read txt file binary data and store it in array for further use. this use the concept of data file handling. plzzz bhelp me the way out as soon as possible.

Member Avatar for Excizted
0
86
Member Avatar for VBNick

Hi, I am trying to make a windows forms application that starts using Sub Main instead of the Form1_Load event. I have tried putting this in Public Class Form1 [code="vb"] Public Shared Sub Main() MsgBox("ASdf") End Sub [/code] and also tried putting this at the top of the programs code …

Member Avatar for VBNick
0
158
Member Avatar for Chaos3737

Please help with my C++ OpenGL code! I am trying to make a simple game in OpenGL with C++ (my first). The issue I'm having is that the WSAD keys move the sphere AND the cube. Since the goal of the game is going to be to get points by …

Member Avatar for VBNick
0
459
Member Avatar for VBNick

Hi, Does anybody know how to enable/disable a secondary monitor using ChangeDisplaySettingsEx or any other function?

Member Avatar for VBNick
0
616
Member Avatar for VBNick

Is there a way to put a computer to sleep somehow other than clicking start, then sleep? I am using a shortcut to this right now: C:\Windows\System32\rundll32.exe powrprof.dll,SetSuspendState 0,1,0 but it doesnt do the same thing as clicking "Sleep" in the start menu. I need a piece of C++ code, …

Member Avatar for VBNick
0
1K
Member Avatar for happygeek

Plenty of people have done it, gone online pretending to be something they are not. Indeed, plenty of men have gone online into chat rooms, forums, virtual worlds and social networking sites pretending to be women. Usually it is for the attention, sometimes it is for the sexual kicks of …

Member Avatar for Tony OnUtila
1
419