- Strength to Increase Rep
- +0
- Strength to Decrease Rep
- -0
- Upvotes Received
- 3
- Posts with Upvotes
- 2
- Upvoting Members
- 3
- Downvotes Received
- 1
- Posts with Downvotes
- 1
- Downvoting Members
- 1
I have a question about how the message loop works in a windows application [code] while ( GetMessage(&msg, NULL, 0, 0) ) { TranslateMessage(&msg); DispatchMessage(&msg); } [/code] Does the windows o/s maintain a message queue that the app retrieves a message from the front of then dispatch it bck to … |
|
Hi I'm wondering how you would write a function that could iterate through any stl container so it didn't matter what you were using e.g list, vector, deque and found an item that matched in that list so the function declaration would look something like this [CODE] template <class TypeList, … |
|
Hi im doing a basic script to parse a text file I want to look for a particular set of words. When i find the word then record the lines until there is a line that is blank [code=python] for line in logfile: for word in line.split(): if word in … |
|
Re:
I am new to C++ and would like to know the best way to setup a 2D game engine. All of the graphic files that I am using for this game are in .png format. How do I use SDL with my game engine, and where do I start when … |
|
I wrote this code to convert from number in denary to a different base I was curious if anyone has any tips on a better way to write this code I'm always looking to improve my coding and I find others critiques to be a great way of improving. In … |
|
This is a text based solitaire game I wrote. It tested it on Ubuntu Linux and Windows and it worked okay for me. Move cards between rows using their row number (7 for the deck) Let me know what people think. Critiques welcome..... don't be too harsh ;) |
|
I'm trying to change a char to an int using the stdlib.h atoi function It works perfectly on windows using VC++ however on Ubuntu Linux using g++ the value of [B]t[/B] is off and from is correct. [CODE] char from = '0', to = '0'; cout<< "From: "; cin >> … |
|
Re:
Hi, I have 2 frames. In left panel i have a hyper link. Whenever i click on hyper link (on the left panel) of the page should open in right panel of the frame. Here is the frame code. [code] <html> <FRAMESET cols="200,*"> <frame name="left" src="page.html"> <frame name="right" src="#"> </FRAMESET> … |
|
Re:
Say I got a number, I enter it in. (like 5). Now I want to convert that to a text string that represents that number (five). I also want it so that if I were to print a big number like 543 or something it will print that out in … |
|
Re:
Hi all. I am newbie to python. I need a starting step to get through it. [COLOR="Red"]How to read lines from a file.[/COLOR] I need the solution. |
|
Re:
I am trying to convert an array of longs to an array of chars. There are 1081 elements in the long array. Each element is 4 digits long. Is there a function in C++ that will convert a long something I can store in the array or could someone point … |
|
Re:
i am making a hangman game on python for school and need help i have to practice using loops like ifs there are three parts i have to make which are checkletter.py which i have been given directions to do this • Code the checkLetter() function so that it goes … |
|
Re:
I have to make a guessing game program using CLR Windows Form APP in Visual Studio 2008. The program has to catch excceptions. Im trying to catch an exception if I were to leave the input box called guessBox2 in the program blank and hit the submit button. IM STUCK. … |
|
Re:
I have answered few multiple choice questions.I am sure i have answered almost 95% correctly. Maybe you guys can identify if i have committed any mistakes.Just identify not solve.I will solve them myself.Just a hint what is wrong would help as i want to be sure all answers are perfect. … |
|
Re:
Hi All, I am facing problems with free() API of ANSI. I am using Visual Studio 2005. I am using 2 char pointers. If i copy from one to another and after if i try to free source pointer, it is giving exception. How to debug this problem? Please help … |
|
Re:
I am in the process of writing and debugging a Python version of Mastermind. I have to use classes, so I have them all in their own files. I have them called and such. My problem now is that a part of the code likes to repeat itself ad infinitum. … |
|
Re:
I am new to ctt programming and I am having some problems trying to get an understanding of what this programming is all about. The following program is the code. Note that in the program we must include the requirement that the program end if the user inputs an invalid … |
|
Re:
Good Evening All, I'm doing a small application using python. I want to check the special characters of the ASCII values with the given characters in the text box. if(string1.rindex!="char(32)" and string2.rindex!="char(32)") message("You have entered the special characters") else: check the values in the database and it follows. Thanks for … |
|
Re:
Hi! I'm new to this forum and joined as i had some doubts regarding c++. I've been studying c++ at school for about 8 months now and now we've been given a project to complete. Here's the topic: [url]http://www.cbse-sample-papers.blogspot.com/2008/09/computer-science-project-c-class-xii.html[/url] I've decided to make a Manager mode sort of a program … |
|
Re:
For the moment I am getting the computers name with this code, but perheps there could be others and better ways to get a computers unique "ID". I am searching for a way to identify a computer so a software can recognice that computer in order to work. The very … |
|
Re:
how can i convert a hex value of a byte (unsigned char) to a short value? [code="c++"] unsigned char hexByte = 0x02; short value= ??? [/code] thank you for your help! |
|
Re:
I am considering using python to write a simulation program to display the motions of about 10,000 2d disks. The program doesn't need to calculate the positions of disks. It just reads the result file and displays disks on the screen. I wonder whether python has this ability for rendering … |
|
Re:
[CODE]Suppose that a stack s and a queue q of characters are initially empty. Show s and q after each iteration of the second for loop of the following code fragment: for(char ch = 'A'; ch <= 'H'; ch++) s.Push(ch); for(int i = 1; i <= 4; i++) { s.Pop(); … |
|
Re:
I thought I understood how tuples work, but that is not the case. [code=python] lose = ['skldhf', 'laweoirht', 'skdljhflkjhs'] print lose [/code] How would I get it to print of the three phrases randomly? No, those aren't what I will be actually using, I just haven't come up with what … |
|
I was wondering how to change a url in javascript for example if i wrote an address [url]www.google.ei[/url] How would i get the script to change the address to [url]www.google.ie[/url] |
|
Re:
Hey, Kinda new to this, and trying to assemble some simple code, but I'm having a couple of issues that I hoped someone would be able to help me out with. 1) I would like to be able to remove duplicates from a submitted sentence, leaving only the first occurance … |
|
Re:
Is there any way to check if the script is being run in the Windows command line? |
|
Re:
I'm writing part of a program that involves writing user generated information to a text file. [code]class MonsterStats: def __init__(self, name): self.__monName = name def setName(self, name): self.__monName = name def fileWrite(self): monFile = open('MonsterFile.txt', 'w') monFile.write(self.__monName) monFile.close() [/code] I wrote this to test it out: [code]import MonsterClass name = … |
|
Re:
Hello, I am in school programming a game using SDL. It's a simple game where the player shoots at ships, which spawns randomly. For this I call random function rand() each time in the game loop, then using the modulus operator to determine wether a new enemy will spawn. The … |
|
I keep getting errors when i try and use the vector class I have an object vector<CSquare*>m_OldSquare; however when i try and add elements to the list [code] CSquare** tempArray = m_FocusBlock->GetSquares(); for(int i=0; i<4; i++) { m_OldSquares.push_back(tempArray[i]); } [/code] I get this error unresolved external symbol __imp___CrtDbgReportW referenced in … |