|
I would like to know it.
If you know, please tell me.
|
|
|
|
|
I'm wrong, it's radio buttons that have a push style. Maybe there's an article on the site about a push button like that ?
Christian Graus - Microsoft MVP - C++
|
|
|
|
|
Do you have any suggestion?
Please help!
|
|
|
|
|
When I said 'maybe there's an article', I was suggesting that you search for one.
This[^] looks like one example of a class that will do what you want, I think.
Christian Graus - Microsoft MVP - C++
|
|
|
|
|
why you dont use the radiobutton with push-like style? i think that would be the easiest way.
P.
|
|
|
|
|
I think that using the radiobutton with push-like style is the easiest way, but how can I use it as I mentioned.
Please help!
|
|
|
|
|
Ok la!
Thank you very much!
|
|
|
|
|
Hi
there is a class where you can change the apperance of any button (normal button, radiobutton, checkbox). This way you can use a check box with the look of a normal button.
http://www.codeproject.com/buttonctrl/cbuttonst.asp[^]
Hope that this helps
codito ergo sum
|
|
|
|
|
I use radiobutton to do it.
Thank you very much!
|
|
|
|
|
Hi,
I have a CFormView derived class which has a thread running at the background which does some background processing. On my view, I have a button which when clicked, the handler function gets called and takes the user to some other screen. When clicked on the button, I cannot wait till my background thread ends and then call the handler. I have to immediately call the handler function without waiting for the thread to end.
What I am doing presently is, just signaling an event to end the thread and call the handler without waitng for he thread to end. if I do this way,my program is crashing with an assertion(it says illegal access of members in the thread). Inside the thread, members of the CFormView derived class are used.
Can anyone please suggest me a solution to call the handler immediately, without waiting for the thread to end and at the same time my program should not crash.
Thanks
Madhavi.
|
|
|
|
|
ledallam wrote: Can anyone please suggest me a solution to call the handler immediately, without waiting for the thread to end and at the same time my program should not crash.
How do you grant access to the CFormViews member variables in the first place and how do you spawn your thread?
When you call the so called "handler", what does it mean?
Is the CFormView object destroyed when you call the "handler"? One solution could be to make sure it's not.
--
Roger
It's supposed to be hard, otherwise anybody could do it!
|
|
|
|
|
We solved a problem similar to this by placing the thread control information into a separate queue. The queue is a singleton at the 'applciaiton' level,a nd not controlled by any of the threads' clients. The thread and the thread's client could access the thread data via the queue. If the 'client' had to leave before the thread was done, then the thread was signaled to exit, but it became a 'zombie' thread and removed itself from the qeue when it could. This way, there was no access violation because the thread's data belonged to a client that might 'disappear' before the thread was done.
|
|
|
|
|
Hi,
I have a form view derived from CFormView on which I have placed several buttons,and onclick of the button i.e in LButtonUp handler, it takes the user to a different screen. It takes some time to show up the new screen as some thread processing has to take place for showing up the new screen. After the user clicks on a button and while the processing is going on, if the user clicks on another button my program is asserting. Hence I want to prevent the clicks on other buttons when the processing is going on. The buttons on my view are CBitmap buttons and totally there are 30 buttons. So when the user clicks on one button, I want to prevent him from clcking on all other 29 buttons, in other words I want to prevent the handlers in LButtonDown and LButtonUp from getting called. I want to revert back to normal state when the for view is shown initially and if for any reason the handler function returns and the user has to stay in the current view itself.
Can anyone please help me to do this.
Thanks
Madhavi.
|
|
|
|
|
Just disable the buttons when the user is not allowed to use them.
Christian Graus - Microsoft MVP - C++
|
|
|
|
|
Hi,
Thanks for ur inputs. But it's not a CButton. It is CBitmap which is drawn on the view using BitBlt. I am handling LButtonDown and LButtonUp on these bitmaps by finding whether the point of click is inside the bitmap rectangle or not. Please let me know how I can disable a CBitmap?
Thanks
Madhavi
|
|
|
|
|
Well, if you handle the click, then deciding not to handle it is trivial, surely ? You can't 'disable a bitmap', that is, you can't stop your code from handling the click, nor can you automatically make it look disabled. You need to draw a different bitmap if you want to show it's disabled, and then just ignore the click in your own code.
Christian Graus - Microsoft MVP - C++
|
|
|
|
|
Hi all, With some sercuity software if you try to end the task you receive an access denied message like below. Even when the process is running under my user and I'm a local admin on the PC.
---------------------------
Unable to Terminate Process
---------------------------
The operation could not be completed.
Access is denied.
---------------------------
OK
---------------------------
I was wondering where I could find some information on this topic. I've look on msdn, here and google but haven't found much. Really I think I just need a hand on what the topic is called so I know exactly what to research in MSDN.
Thanks all.
Luke
|
|
|
|
|
Sometimes if the process is running as a service, then you cna try stopping the service using the 'services' control panel application instead.
|
|
|
|
|
I don't beleive they are running as a service, can't see it in there. Also, I don't want to know how to kill it, I won't to know in c/c++ how to do they same thing, and I'm not sure where to begin to look, or more to the point what to search for.
Cheers,
Luke
|
|
|
|
|
TerminateProcess
ControlService with SERVICE_CONTROL_STOP
|
|
|
|
|
Hi All,
Can anyone pls post the code to import a X509 certificate to a PKCS 11 Token ?
Thanks & Regards
Raj
|
|
|
|
|
are u find the correct way to import certificate to pkcs 11 token?
i need the source samples too.
can u post some code?
|
|
|
|
|
are you find the way?
i need it too.
can you post it to me.
thanks.
|
|
|
|
|
I need to get a HWND (Win32 Window handle) for the Window that is under the mouse pointer.
Do you know how to do this off the back of your hand?
Thank you! I am using wxWidgets in Win32; No MFC/ATL.
-- Andrei B (andreib.com/blog)
|
|
|
|
|