|
You wouldn't beleive it, but it has taken me nearly all day to get this one little function working correctly. I just hope it will all be worth the effort.
Thanks again.
|
|
|
|
|
Your welcome, glad I could help...
John
|
|
|
|
|
Geez, I ended up with exactely the same code BUT for the mask that was wrong (masking only one bit and not two...).
That was a very interesting question, thanks for sharing it.
~RaGE();
|
|
|
|
|
The cast from int to double is implicit. i.e.
int i=3;
double d = i;
Steve
|
|
|
|
|
|
Michael Dunn wrote: FYI this belongs in the C# forum[^]
Why on earth would I want to put a C++ question in the C# forum? Please re-read my thread, I stated that I could only find a C# example of what I wanted to do. I added the function with the offchance that one of the C++ gurus here would understand it and know a way to convert it to C++.
Also if you read the repies to my initial post, you should notice there is nothing C# about them. All the code and examples are pure C++.
|
|
|
|
|
Hi,
In my (MFC) application, I would like to let the user configure his toolbars (add/remove buttons, associate custom bitmaps/commands with the buttons he adds). I have no idea as where to start. I know how to use a normal CToolBar , but with a fixed amount of buttons and an imagelist with the right size, and with the event handlers associated to each button. But how do we do that dynamically ?
~RaGE();
|
|
|
|
|
<thinking aloud>
I create a CToolBar object for each toolbar I want my user to customize. I have a .bmp where I stock every bitmap he may use to put on the button he wants to insert. For adding a button, I simply get the CToolBarCtrl control from the associated CToolBar and use the AddButton command.
Is this OK ?
I suppose that I need to map the IDs of the created buttons to commands, and that I will have to handle them in the OnCommand handler. Or is there any better way ?
</thinking aloud>
~RaGE();
-- modified at 15:22 Tuesday 18th April, 2006
|
|
|
|
|
I write a Application in form "Dialog" use menus.
I want to display "checked sign" when user click left mouse on that menu by using this code :
void CMTCaroDlg::OnUpdateOptionPlayoverlan(CCmdUI* pCmdUI)
{
// TODO: Add your command update UI handler code here
pCmdUI->SetCheck(TRUE);
}
But when i run the Application, no thing to change !!!
Why ???
Help me please !!!
Lgx
|
|
|
|
|
this kind of handles are invalid for dialog.
u need to check it yourself by CheckMenuItem() function.
A special image tool for C++ programmers, don't miss it!
The world unique Software Label Maker is here for you and me ...
A nice hyper tool for optimizing your MS html-help contents.
|
|
|
|
|
|
How does use it ???
Help me please !!!
|
|
|
|
|
The update command UI system doesn't run for dialogs unless you add message handler for WM_KICKIDLE and start the update process from there. Google for WM_KICKIDLE and you should find many pages on what to do
--Mike--
Visual C++ MVP
LINKS~! Ericahist | NEW!! PimpFish | CP SearchBar v3.0 | C++ Forum FAQ
|
|
|
|
|
I am developing a directshow filter, but there is something wrong when running this filter. I know GraphEdit can be used to test the filter, but how to debug the filter step by step by setting breakpoint? Thanks.
|
|
|
|
|
Go to Project properties->Configuration Properties->Debugging in VS and set "Command" to the
path of your graphedit.exe. Then it starts automatically when you start debugging your filter.
In debugging mode you can step through your code by loading and starting your filter in graphedit, if you have properly registered the debug dll/ax with regsvr32.
|
|
|
|
|
Hello,
i want to display a long text (more than 127 characters) in the status bar. I am using GetStatusBarCtrl().SetText(...) but this function only displays 127 characters. I tried to display my text in two parts and then send it still using the previous function but didn't succeed (I get one part on the left and the other one completely on the right)
Thank you for your help,
agnes
|
|
|
|
|
Hi athomass
I'm not sure that this is your answer anyway use SetBorders in class statusbar
|
|
|
|
|
Hello,
Thank you for your answer, I tried that but I do not get what I want because I have to display other information on the right of the status bar (using SetPaneText and SetPaneInfo). If I use SetBorder, these information is also moved.
Somebody has another idea?
Agnes
|
|
|
|
|
I have given one big code with about 60 classes, and have been told that the code has memory leak, the code is compiled with visuall studio 6 and written in C/C++, does anybody know if the visual studio (any vresion) can find out where this emory leak would be located?
Thanks
nahi
|
|
|
|
|
Does it use MFC?
"Let us be thankful for the fools. But for them the rest of us could not succeed." - Mark Twain
"There is no death, only a change of worlds." - Native American Proverb
|
|
|
|
|
Yes it does! it has a dll that would be used by another program and also VB and MFC for some other parts.
TNX
|
|
|
|
|
Then simply use F5 to start the program. Since it is a DLL, you'll need to provide the name of the EXE that goes with it. Any new without a matching delete will be noted in the Debug window when the program terminates.
"Let us be thankful for the fools. But for them the rest of us could not succeed." - Mark Twain
"There is no death, only a change of worlds." - Native American Proverb
|
|
|
|
|
DEar David,
Thanks for the message, My program receives and sends out packets through sockets (put the info in some buff and sends them and kill the buff after sending out the info. What is your suggestion for me.
Best regards,
|
|
|
|
|
nahitan wrote: What is your suggestion for me.
See here. If you are saying that this will not work for you, how are you verifying that a memory leak exists?
"Let us be thankful for the fools. But for them the rest of us could not succeed." - Mark Twain
"There is no death, only a change of worlds." - Native American Proverb
|
|
|
|
|
thanks for the help
|
|
|
|