|
If you'd fix your signature such that it did not run into your posts, people wouldn't get confused into thinking you are directing the comment towards them.
"Approved Workmen Are Not Ashamed" - 2 Timothy 2:15
"Judge not by the eye but by the heart." - Native American Proverb
|
|
|
|
|
I agree with David Crow modify your sig
|
|
|
|
|
WTF !?
if you have problem, first learn C/C++... it might solve much of your newbies basics questions.
and about who here is good or bad programmer, i don't think YOU are able to judge anyone about this.
the point here is that anybody can understand what you asked in your 1st question. so why do you react like this ?
when you don't understand a question, don't you ask for more precision to understand and help the guy ? that's what we all 3 did.
but instead of add precision, you're attacking us.
answer of go to hell
|
|
|
|
|
Sakthiu wrote: What you are thinking yourself ?
are you a good programmer ?
If you dont know answers., Leave it and do your work..
Don't confuse his reply with his signature.
"Approved Workmen Are Not Ashamed" - 2 Timothy 2:15
"Judge not by the eye but by the heart." - Native American Proverb
|
|
|
|
|
what do you mean by "check" ?
what do you want to do exactly ?
the CRT string functions are the ones like strxxx() but if you're a C++ coder,i suggest you to have a look at the std::string class instead...
|
|
|
|
|
Do you mean compare ? A char array is how C stores a string ( and what any string class is wrapping ). There are plenty of string classes, are you using std::string, CString, or something else ?
Christian Graus - Microsoft MVP - C++
Metal Musings - Rex and my new metal blog
|
|
|
|
|
Sakthiu wrote: How do i check a char array and a string ?
Check them for what?
"Approved Workmen Are Not Ashamed" - 2 Timothy 2:15
"Judge not by the eye but by the heart." - Native American Proverb
|
|
|
|
|
What do you need,excatly?
|
|
|
|
|
When I include the pdh.h header file I recceive the following error:
error C2040: 'HLOG' : 'void *' differs in levels of indirection from 'struct _HLOG'
The error occurs in the header file. Any idea what could I be doing wrong???
Thanx in advance
The only programmers that are better than C programmers are those who code in 1's and 0's.....
Programm3r
|
|
|
|
|
|
|
Could there exists a conflict between header files, for example i'm including all of the header files, but the only one that is causing the error is pdh.h .... I'm well aware of the fact that the error occuring in the header file is not caused by faulty code.
windows.h
winbase.h
sql.h
sqlext.h
stdlib.h
mbstring.h
conio.h
exception
odbcinst.h
shellapi.h
winuser.h
exception
fstream
lm.h
Lmjoin.h
shlobj.h
Winreg.h
shlwapi.h
tchar.h
pdh.h
The only programmers that are better than C programmers are those who code in 1's and 0's.....
Programm3r
|
|
|
|
|
O.k, when I exclude the header files:
lm.h
Lmjoin.h
The error goes away and the dll compiles, but why would this be, the thing is I need both of those header files and the pdh.h header file.
Any suggestions???
The only programmers that are better than C programmers are those who code in 1's and 0's.....
Programm3r
|
|
|
|
|
i see somethings that could produce this :
some of the headers (in the list you provided) already include some others and some of the headers don't have an auto exclusive include statement like :
#pragma once or
#ifndef __MY_HEADER_H__
#define __MY_HEADER_H__
#endif
|
|
|
|
|
Hello
i'm a newbie here, i just want to ask if you an idea on how to pause a console app that is being spawned by the CreateProcess() function?
Thanks a lot.
i need to learn more... i want to be like you guys... i'm just a begginer
|
|
|
|
|
I don't think you can pause a process. Why don't you pause it inside the code of this console app itself ? What are you trying to achieve exactly ?
|
|
|
|
|
i was just hoping if i can pause a spawned process, maybe my ReadFile may return something from the application. because in my redirection class, it waited till the application fisnished before it can redirect its output into the editbox.
The thing is i have no coding access to the spawned process.
Actually if you will try to pause it manually, you can. by pressing the pause/break key.
i need to learn more... i want to be like you guys... i'm just a begginer
|
|
|
|
|
rupert_durans wrote: i'm a newbie here, i just want to ask if you an idea on how to pause a console app that is being spawned by the CreateProcess() function?
Have you tried CREATE_SUSPENDED . You can pass this flag to dwCreationFlags parameter of CreateProcess .
|
|
|
|
|
hello everybody !!
my new problem is that i have a class that contain a some functions and some variables
i want to execute one of these functions in a separate thread using AfxBeginThread(...);
and FYI this function uses some member variables of the class to do it's work
any idea ???
thnx 4 ur time and concern
a.hemdan
|
|
|
|
|
Pass the address of the instance of the class from which you want to call a member function as an argument of your thread. When you start a thread, you can pass a user defined parameter that will be passed to the function of your thread. There, pass the pointer to your class instance. In your thread function, cast it back to the class pointer and call the member function.
|
|
|
|
|
Hi
I have a friend who somehow encountered that and i remembered that he made a structure of the class and pass it on to the thread so that the member viriable can be used by the thread.
Try to research about worker thread and UI thread, you may find how to use member viriables of a class inside the thread by using struct.
Hope i have helped you somehow.
i need to learn more... i want to be like you guys... i'm just a begginer
|
|
|
|
|
rupert_durans wrote: he made a structure of the class and pass it on to the thread so that the member viriable can be used by the thread
What do you mean by making a structure of the class ? Why not simply pass the address of the class instance (the this pointer) to the thread ?
|
|
|
|
|
yup,
i asked him again and you are right, you may or may not create struct as long as it points to the class instance.
i need to learn more... i want to be like you guys... i'm just a begginer
|
|
|
|
|
Ok but why do you want to do such a thing ? What is the advantage of wrapping your class into a structure just to pass it to your thread ? Pass it directly, it's much cleaner. Why adding complexity where this is not required ?
|
|
|
|
|
hehehe, soweee, i'm just a newbie, i just saw it on my friend's code...
now i know that it can be direct,
can you please give me example on how to declare a pointer to the class instance?
i need to learn more... i want to be like you guys... i'm just a begginer
|
|
|
|