|
using VC++6 ,i can easily rename the member variables of CRecordset-derived class with classwizard,
but when i use VC++7 ,i cannot find one easy way to rename the variable which appears at several place in .cpp and .h file.
i want to know : is there any tool in VC7 which can update columns and bind the member variables to columns in the database table like classwizard in vc6?
anybody have some advice appreciated anyhow.
|
|
|
|
|
I am using the desktop window as a parent window of a child window in my app. The child is unable receive messages as a result. Any help would be greatly appreciated.
|
|
|
|
|
What messages you want to recieve and what is your child window? A dialog? Or a button?
Philip Patrick
Web-site: www.stpworks.com
"Two beer or not two beer?" Shakesbeer
Need Web-based database administrator? You already have it!
|
|
|
|
|
How can i achieve that in my program,
wat's the function or API to do this?
I don't need it to be able to resize using mouse, just rather by function calls will do.
And how do i propogate the message from CDialog to the controls in the dialog boxes?
like WM_SIZE or any another msg.
Thanxs a billion.
|
|
|
|
|
See this article for one solution.
/ravi
Let's put "civil" back into "civilization"
http://www.ravib.com
ravib@ravib.com
|
|
|
|
|
Use either SetWindowPos or MoveWindow . What message do you want to propogate? Because ususally the controls are resized in the WM_SIZE message of the dialog box.
Build a man a fire, and he will be warm for a day Light a man on fire, and he will be warm for the rest of his life!
|
|
|
|
|
Thanxs!
i would want to propogate messages like WM_SIZE to a subclass that i have created.
I wll take a look at the article recommended Ravi Bhavnani.
BTW,
wat's the difference between INT and int, BOOL and bool,....?
Thanxs once again
|
|
|
|
|
aldeba wrote:
wat's the difference between INT and int, BOOL and bool,....?
the int and bool data types are native data types that you will find in C++. The int is a four byte signed integer and I believe that the bool is a one byte value that indicates either true or false.
Microsoft has declared the INT and BOOL datatypes to make programs more portable. If you search through the header files in windows.h, you will find that the INT is probably defined as an int like this:
#define INT int
And the BOOL is defined as an int as well. That is because the bool datatype does not exist in C, and all of these functions are supposed to work in C as well as C++.
The code is made more portable by letting you define what the underlying datatype is for the INT or BOOL when you compile the program on different machines. For instance the difference between compiling your program for Win32 or Win64. Or an Intel machine or a UNIX machine.
I prefer to use the native datatypes for my own internal code, but if I am writing a library of API functions to distribute, I usually use the #defined types.
Build a man a fire, and he will be warm for a day Light a man on fire, and he will be warm for the rest of his life!
|
|
|
|
|
aldeba wrote:
i would want to propogate messages like WM_SIZE to a subclass that i have created.
You dont need to do that, if you change the size of the controls from the dialog(eg. MoveWindow), the control will recive a WM_SIZE message.
|
|
|
|
|
I am getting error LNK2019, after adding this code to a project:
void CSimpleShlExt::DeleteFiles(string sPath)
{
vector <string> Paths;
string enumerate = sPath;
if (enumerate[enumerate.length()- 1 ]!= '\\')
enumerate += '\\';
enumerate += "*.*";
WIN32_FIND_DATA fd;
::FindFirstFile(enumerate.c_str(), &fd);
}
and I think I need to get rid of ATL_MIN_CRT, which is defined I believe, but I cannot find where. I am using .NET. Can anyone help me ?
Christian
The tragedy of cyberspace - that so much can travel so far, and yet mean so little.
And you don't spend much time with the opposite sex working day and night, unless the pizza delivery person happens to be young, cute, single and female. I can assure you, I've consumed more than a programmer's allotment of pizza, and these conditions have never aligned. - Christopher Duncan - 18/04/2002
|
|
|
|
|
actually, removing this code does not solve the problem, but it now fails to build with the code that originally compiled fine. So my project settings must have changed, but how to change them back ?
Christian
The tragedy of cyberspace - that so much can travel so far, and yet mean so little.
And you don't spend much time with the opposite sex working day and night, unless the pizza delivery person happens to be young, cute, single and female. I can assure you, I've consumed more than a programmer's allotment of pizza, and these conditions have never aligned. - Christopher Duncan - 18/04/2002
|
|
|
|
|
In VC 6 _ATL_MIN_CRT is set in the Project Settings->C++ tab->Compiler options. No idea where it is in VC 7 'cause I never could find the bloody project settings in that version. If worse comes to worse, put this in stdafx.h:
#undef _ATL_MIN_CRT
--Mike--
Just released - RightClick-Encrypt - Adds fast & easy file encryption to Explorer
Like the Google toolbar? Then check out UltraBar, with more features & customizable search engines!
My really out-of-date homepage
Sonork - 100.10414 AcidHelm
|
|
|
|
|
Thanks Mike. you're not wrong - the new IDE blows when it comes to this stuff. It's like XP - it tries to help, but merely makes things impossible.
It works now though
Christian
The tragedy of cyberspace - that so much can travel so far, and yet mean so little.
And you don't spend much time with the opposite sex working day and night, unless the pizza delivery person happens to be young, cute, single and female. I can assure you, I've consumed more than a programmer's allotment of pizza, and these conditions have never aligned. - Christopher Duncan - 18/04/2002
|
|
|
|
|
"nafxcwd.lib" and "LIBCMTD.lib" both defined "delete", I need to use both of the two lib files. If I choose using MFC in static lib, a error will come out.
What can I do? Thanks!
|
|
|
|
|
I have the following
dataout.setf(ios::fixed | ios::showpoint);
dataout << setw(10) << setprecision(5) << number << endl;
I get this result:
0.00000
How can I make it print instead:
.00000
Or, if I have the output:
-0.12123
How can I make it remove that 0 and print:
-.12123
Sounds really stupid I know, I have to make this data perfect in
order for it to work with this crappy fortran program.
Please, any response anyone can give me will be greatly appreciated.
Sincerely,
Danielle (an overworked graduate student)
|
|
|
|
|
ummmm
sprintf() it o another string first and remove the zero manually then output the adjusted string?
"... and so i said to him ... if it don't dance (or code) and you can't eat it either f**k it or throw it away" sonork: 100.18128 8028finder.com
|
|
|
|
|
Someone can explain (or point me to some article) how to use ToolTips with Tab control? I need a plain Win API
Philip Patrick
Web-site: www.stpworks.com
"Two beer or not two beer?" Shakesbeer
Need Web-based database administrator? You already have it!
|
|
|
|
|
I've tried OnOK() but that only works in a Dialog. OnDestroy() and DestroyWindow() dont work either, and I dont know what else there is. Whats the function to close my program?
-Raffi
|
|
|
|
|
Try this:
PostQuitMessage(0);
Mazy
"The more I search, the more my need
For you,
The more I bless, the more I bleed
For you."The Outlaw Torn-Metallica
|
|
|
|
|
Thanks
-Raffi
|
|
|
|
|
Mazdak wrote:
PostQuitMessage(0);
This might kill the application unless there are other GUI threads. It's safer to post a WM_CLOSE to the window you want to close.
Nish
Regards,
Nish
Native CPian.
Born and brought up on CP.
With the CP blood in him.
|
|
|
|
|
hmmmmmmmmm,thank you Mr.Nish.
Mazy
"The more I search, the more my need
For you,
The more I bless, the more I bleed
For you."The Outlaw Torn-Metallica
|
|
|
|
|
i think use SendMessage function to send a WM_CLOSE message
can do it also!
I'm a beginner of VC++...
|
|
|
|
|
I use __try in my application but compiler give me this error for it:
error C2712: Cannot use __try in functions that require object unwinding
I read in MSDN :
To avoid this error message, compile using the /GX- option.
Now how can I do it?I don't know how to compile with an option!
Thanks
Mazy
"The more I search, the more my need
For you,
The more I bless, the more I bleed
For you."The Outlaw Torn-Metallica
|
|
|
|
|
in your VC++ IDE
take Menu Item PROJECT>>SETTINGS (or simply ALT + F7)
and in the Project Settings Propertypage take the C/C++ TAB
in that there is a text box Project Options in that u must add that /GX
R_Renjith The True CP ian
|
|
|
|