Beginners - April 2010 (Page 35)

[Linux]wchar_t[]/L"string" --> wchar_t* undesired result
 
Hello everybody. First of all I put this post here cuz it might be trivial compared to what's in the UNIX-subforum. Now to the actual issue. I have a proble...
[6 replies] Last: Also, in this case, you do not have to use wprintf to print wide chara... (by moorecm)
Arrays of strings, for loop and why back to the beginning?
 
my program outputs this: it outputs the string:"I'm the best Heitz around", then executes the for loop (un)successfully, because when the for loop is finished...
[3 replies] Last: your for loop should be for(int i = 0; i < 4; i++). You're outside of ... (by oghmaosiris)
size of array
 
WriteLog(_T("GetDependentServices: checking dependencies...")); LPENUM_SERVICE_STATUS lpDependencies = GetDependentServices(hService); if (lpDepende...
[1 reply] : That trick only works for stack arrays in the function that created th... (by helios)
'+' : cannot add two pointers (LPTSTR + tstring)
 
WriteLog(ess.lpServiceName + _T(": stopped.")); error C2110: '+' : cannot add two pointers how can i print servicename and text correctly to my log? (...
[3 replies] Last: - disadvantages? Well, the only disadvantage is, that it looks cr... (by imi)
i dont know >>= is
 
İn the code below ( double has 8 bytes) double 's 8 byte is shown in bytes. But i cant understand for(i = 128; i; i >>= 1) what this is. And i ...
[6 replies] Last: Thanks a lot to all... (by scallioglu)
Linked List logic error
 
void lsts::push(links *LLhead, int z) { links *temp = new links; temp->next = LLhead->next; temp->value = 33; LLhead->next = temp; z++; print(LL...
[3 replies] Last: I'm supposed to be building a queue and I am pushing the value of 33 ... (by sammy34)
by DBarzo
_BLOCK_TYPE_IS_VALID assertion with maps
 
Hi, In the following code, I have a _BLOCK_TYPE_IS_VALID assertion when the CDeviceManager destructor is called. The 'IAudioCallBackDevice *caller' argument...
[2 replies] Last: Found it. It was an error on a memcpy! Damn! :) Daniele. (by DBarzo)
by Parsa
Problem in dynamic memory allocation
 
Hi there, i'm new to programming and i'm having a bit of a problem lately. i'm writing a win32 windows application in microsoft visual c++ 2008, i have a class...
[3 replies] Last: That kind of error can only happen when there's a problem in the code.... (by helios)
by Lod
C++ wav playsound function
 
#include <iostream> #include <windows.h> using namespace std; int main () { PlaySound("F:\\Nightmare_Before_Christmas_-_This_is_Halloween.WAV", NULL, ...
[3 replies] Last: Header mmsystem.h Library coredll.lib (by Denis)
by Diaa
error LNK2019
 
I'm creating an image manipulation program and created two classes, pixel and image. The pixel class works fine and I can do everything with it, from inversing ...
[1 reply] : Post pixel.h and pixel.cpp It seems that you declared but not defined... (by hamsterman)
by caalar
Dynamic sized data structures
 
Hello! I would like to have a data structure that keeps a Structure array but doesn't have any idea about its size. My current code is : SAMPLE_STRUCT tem...
[1 reply] : I am not allowed to use vectors since I will be sending this packet t... (by helios)
RBG in windows.h
 
Hello hackers, I have a problem compiling this example, the compiler says that RBG identifier not found(redBlueGreen?) I saw something similiar in a differen...
[3 replies] Last: your code saying RBG...change it to RGB and put below code where you d... (by hkr88)
Quick Question: Exclamation Symbol (!)
 
Code for inserting an element at the front of a list: bool insertInFront( IntElement **head, int data ){ IntElement *newElem = new IntElement; if( !newEle...
[16 replies] Last: I should add that my previous statement is true for val being of any b... (by helios)
Random Number Initialization
 
I am working on a linked list, and have the list working correctly. I am not modifying my Node class to generate a pseudo random key. After playing with the sra...
[4 replies] Last: Yea... I just experimented using srand(time(0)) in my main code, and i... (by closed account Lv0f92yv)
I need assistance with loops
 
Hi, I want to create a loop inside a calculator which would ask the user to input the operation and the numbers again and would keep on pestering the user till...
[7 replies] Last: Hey! Have u checked the tutorial on this site? http://www.cplusplus.c... (by marvolo1300)
April 2010 Pages: 1... 333435
  Archived months: [mar2010] [may2010]

This is an archived page. To post a new message, go to the current page.