|
I don't believe you need the "address of" operator.
"Alot of the people on this forum are incredibly stupid, thinking that the internet is real" Score: 1.0 in the Soap Box
led mike
|
|
|
|
|
effectively, not needed, but prefered, because the future version of the standard will require it. and it is always more readable.
|
|
|
|
|
toxcct wrote: because the future version of the standard will require it
The ISO standard? Have a link?
"Alot of the people on this forum are incredibly stupid, thinking that the internet is real" Score: 1.0 in the Soap Box
led mike
|
|
|
|
|
Help! I've looked everywhere but can't find the answer.
I create a CPropertySheet containing a bunch of CPropertyPages.
If I launch it as a popup using DoModal it looks like it has the right width, i.e. the width of my property pages (which are all the same size).
But when I use SetWizardMode(), the resulting dialog is much wider than it needs to be. The buttons at the bottom are shoved to the right with empty space on the left of them, and above them. But my PropertyPages (according to Spy++) have been inflated in width. Their controls appear at the left, and there's a large empty space on the right, above the Cancel/Help buttons.
Does anyone have an idea what's going on here, and what I can do about it? I've tried all sorts of things (checking all contents, moving the buttons to the left, etc.) but I must be missing the obvious because nothing works.
You can see this behaviour in a simple app with just a default property page in a property sheet, too. Oh yeah, this is Visual C++ 6.0, and I'm using MFC.
Thanks.
- Owen -
|
|
|
|
|
I found it is strange, while in VC studio editor the code looks very nice with propper spacing, but when you view it in simple text editor the lines are out of order and do not match the same style in the VC. It the TABs that VC paste here and there, but you can not get rid of them thru find and replace, since you press button TAB in the find edit box it skips to net control.
9ine
|
|
|
|
|
9ine wrote: ...when you view it in simple text editor the lines are out of order and do not match the same style in the VC.
Which is why you should use spaces, not tabs.
"Talent without discipline is like an octopus on roller skates. There's plenty of movement, but you never know if it's going to be forward, backwards, or sideways." - H. Jackson Brown, Jr.
"Judge not by the eye but by the heart." - Native American Proverb
|
|
|
|
|
??? I dont use TABS, always spaces, but VC like tabs, e.g. when you start to compose switch() block and typing like
case 2:
and after you press ':' button VC accelerate this line ahead so it is
____case 2:
and you have to delete VC job but there is always some hidden TABS which you can not see and your code looks normal in VC but horible in text editor
9ine
|
|
|
|
|
immediately after it autoformats your text, do Ctrl+Z...
|
|
|
|
|
does not help with "if" and press "{"
9ine
|
|
|
|
|
weird, it does for me, for any auto-reformat... (with VC2003, like you)
|
|
|
|
|
9ine wrote: but VC like tabs,
So just change it to use spaces instead.
9ine wrote: ...there is always some hidden TABS which you can not see...
Use Ctrl+Shift+8 to see them.
"Talent without discipline is like an octopus on roller skates. There's plenty of movement, but you never know if it's going to be forward, backwards, or sideways." - H. Jackson Brown, Jr.
"Judge not by the eye but by the heart." - Native American Proverb
|
|
|
|
|
If you're using VC++ 6.0, select your text and then you can use the Edit menu, Advanced, Untabify to replace the tabs with spaces.
Hope that helps.
Karl - WK5M
PP-ASEL-IA (N43CS)
<kmedcalf@ev1.net>
PGP Key: 0xDB02E193
PGP Key Fingerprint: 8F06 5A2E 2735 892B 821C 871A 0411 94EA DB02 E193
|
|
|
|
|
|
yeah untabify works fine
9ine
|
|
|
|
|
hi
Can we create Windows ,Dialog Boxes and other components without using MS VC++??If so how??
Can't we write the code in Plain C++ or are there any third part tools/libraries available for it??
"Every morning I go through Forbes list of 40 richest people in the world. If my name is not in there, I go to work..!!!"
|
|
|
|
|
Windows applications reqire the Windows SDK.
"Talent without discipline is like an octopus on roller skates. There's plenty of movement, but you never know if it's going to be forward, backwards, or sideways." - H. Jackson Brown, Jr.
"Judge not by the eye but by the heart." - Native American Proverb
|
|
|
|
|
QuickDeveloper wrote: Can we create Windows ,Dialog Boxes and other components without using MS VC++??
Depends of what you plan to do exactly. You will still need to link to the win32 API but you don't need to use MFC and thus, you can use another compiler like Dev-Cpp for example (altough, I don't recommand it ). But, going the win32 way is VERY complicated and it's very long to develop a simple application.
You can use wxWidgets[^]: it is a cross-platform GUI library that will let you develop GUI quite easily.
|
|
|
|
|
Hi,
In a current project I use the PDH library to monitor system states for finding ressource and memory eaters in our system. The problem I now encountered is that one component uses lm.h, which uses lmerrlog.h, and both pdh.h and lmerrlog.h define a type HLOG (a HANDLE in PDH.h and a struct_HLOG in lmerrlog.h) this name collision results in not being able to compile the component using the lm, as the component using pdh.h is part of a very basic class collection used by EVERY other component in the project. How can I solve this problem of name collision. Both are Microsoft libraries included in Visual C++ 6.0 so I can't just rename the Handle in pdh.h or the struct in lm.h.
I hope this problem can be solved without installing additionally software as this software would have to be installed not only on our compiling computer but then on every developer's PC.
Is there some kind of namespace definition to encapsulate the usage of the PDH.h HLOG on just the component using the PDH library?? Or is there some other way to encapsulate the visibility of that definition to that class.
Hope you can help
Martin Dietz
|
|
|
|
|
Include the lm.h in ONLY the source files that need it.
You can also try to #undef the offending item from pdh.h prior ot including the lm.h or vice versa.
<br />
#include "lm.h"<br />
#undef HLOG<br />
#include "pdh.h"<br />
or switch it around to suit your needs.
Any sufficiently gross incompetence is nearly indistinguishable from malice.
|
|
|
|
|
Thanks for your answer, but as the component using the lm.h wasn't mine, I could not know if that component used the HLOG from lm, then it would have been hazardous to undefine it. And the seperate inclusions wouldn't work either as the pdh is included for a class that is part of a base class collection used (or at least being available), so the pdh.h would be included in every component via a precompiled header
I solved it by setting a namespace around the inclusion of pdh.h in my base component and accessing its functions with namespace identifier. It helped too and that way I didn't have to look which components of the whole software could also have problems like this.
Thanks anyway,
Martin Dietz
|
|
|
|
|
Sir,
I want to write a program that protects the file and folders by applying the password on the same.Now the question is , I want to choose a language and it's version(I mean like vb or vb.net) .I mean i want to know i which language it is appropriate to write this program .Also I want to give this facility by right click on the file folder.I mean When it is right clicked to the file/folder It gives the option Named Password.On clicking the password it open the window to set the password for the file or folder.
This is what I am looking for.Now Please suggest me which language is appropriate to make this program.I know to implement these things , I need Black Belt level of knowledge and the knowledge to writing device drivers and file system extentions .I also want to know one thing that I want to learn these things Black Belt , writing device drivers, file extentions.Please suggest where to start .I want to start from the scratch.
Please help.
Thanks
|
|
|
|
|
|
amaneet wrote: Now Please suggest me which language is appropriate to make this program.
There are probably several that could be used. Which are you most familar with?
"Talent without discipline is like an octopus on roller skates. There's plenty of movement, but you never know if it's going to be forward, backwards, or sideways." - H. Jackson Brown, Jr.
"Judge not by the eye but by the heart." - Native American Proverb
|
|
|
|
|
Hello,
Can you help me? Now I want to use the WMI class to get hardware/system information, including the processor, memory, disk drive, operation system, and so on. Bascially, all system hardware and software information. I have known mabye it's simply using the WMI class. But I don't know how to use it? Can you give me an example or source code. Hope to get all reply, thanks.
David
|
|
|
|
|