|
not eror ... just that i don't know how to do that ... i'll tell u again ... i whant to make an Edit_Box "Enabled" after i click the Check_Box and to enter a value also .. in te same time ... my problem is with the changing of the status of the Edit_box because of my click ... understand ?
nu prea ma fac inteles, dar incerc sa ma exprim !!!
|
|
|
|
|
Assuming your dialog class has a CEdit member variable mapped to the edit control, you can use:
m_ebEdit.Enabled(pCheck->GetCheck() == BST_CHECKED);
"Opinions are neither right nor wrong. I cannot change your opinion. I can, however, change what influences your opinion." - David Crow
|
|
|
|
|
Actually what David meant was:
m_ebEdit.<code>EnableWindow</code> (pCheck->GetCheck() == BST_CHECKED); /ravi
My new year's resolution: 2048 x 1536
Home | Articles | Freeware | Music
ravib@ravib.com
|
|
|
|
|
Hummm, most of MSDN is on line (avialable via www). If you're developing the program using the VC++ IDE, then you should already have access to MSDN; otherwise there would be no help avialable when you hit F1. If you are using MFC (via VC++), then activating the class wizard will give you the option of setting the UI options (via command id) as follows:
void MyView::OnUpdateColortypeFill(CCmdUI* pCmdUI)
{
pCmdUI->SetCheck(m_Grid.GetColorType() == CGetColor::FILL);
}
INTP
"The more help VB provides VB programmers, the more miserable your life as a C++ programmer becomes."
Andrew W. Troelsen
|
|
|
|
|
guys .. i apreciate the help .. but it would be better if u would tell me were to put the sequence of code ... these are my arrors ....
<br />
D:\DOCUMENTELE MELE\3\3Dlg.cpp(150) : error C2653: 'MyView' : is not a class or namespace name<br />
D:\DOCUMENTELE MELE\3\3Dlg.cpp(152) : error C2065: 'm_Grid' : undeclared identifier<br />
D:\DOCUMENTELE MELE\3\3Dlg.cpp(152) : error C2228: left of '.GetColorType' must have class/struct/union type<br />
D:\DOCUMENTELE MELE\3\3Dlg.cpp(152) : error C2653: 'CGetColor' : is not a class or namespace name<br />
D:\DOCUMENTELE MELE\3\3Dlg.cpp(152) : error C2065: 'FILL' : undeclared identifier<br />
D:\DOCUMENTELE MELE\3\3Dlg.cpp(164) : error C2065: 'm_ebEdit' : undeclared identifier<br />
D:\DOCUMENTELE MELE\3\3Dlg.cpp(164) : error C2228: left of '.EnableWindow' must have class/struct/union type<br />
so .. i'm in the fog again ..
|
|
|
|
|
hello everyone...
i have a small question:
i want to intercept keyboard strokes being sent to applications...for example i want the 'a' button to send a 'b' to applications instead of 'a'...should i use hooks or subclassing...i need to know what are the appropiate APIs that should be used..
note:i want this to be done for all applications ((processes)) not only one...
|
|
|
|
|
Hook is better , just try global Keyboard hook.
saeedmalas wrote:
.i need to know what are the appropiate APIs that should be used..
SetWindowsHookEx(...) ,but for Global hook you have to create a dll.
look for more example here :-
http://www.codeproject.com/system/hooksys.asp
http://www.codeproject.com/system/Paladin.asp
http://www.codeproject.com/dll/hooks.asp
"I Think this Will Help"
[Vote One Here,.....]
<h5
alok="" gupta="" <br=""> visit me at http://www.thisisalok.tk
|
|
|
|
|
it looks like that using SetWindowsHookEx is only for monitoring not modifying...i actually want to prevent a message from reaching applications or modifying that message before reaching them..not just see what the message is...
|
|
|
|
|
Actually after hooking you can use GetWindowLong to to get Window procedure of any window and you can modify the charater from there.
look for that in more Detail in the link given by me in last post
"I Think this Will Help"
[Vote One Here,.....]
<h5
alok gupta="" <br=""> visit me at http://www.thisisalok.tk
|
|
|
|
|
if i'm going to do that,i think i have to get the Window procedure of all windows of all processes...i think that's a very hard work..isn't there an easier way..
|
|
|
|
|
This is not a small question!
There are aticles at CP that may give you the information that you seak.
I'll tell you this much, you need to use hooks.
INTP
"The more help VB provides VB programmers, the more miserable your life as a C++ programmer becomes."
Andrew W. Troelsen
|
|
|
|
|
After I read some articles about building MFC Dll in this website,
I tried to export my class as MFC dll. However, I also want my class to
handle messages, such as PostMessage, SetTimer, etc.
I want to ask that how can I use message handling ability in my class which is exported as MFC Dll?
Thanks
|
|
|
|
|
Simply derived class from the CCmdTarget or it decesendent for enabling the messaage handlling in that class.
"I Think this Will Help"
[Vote One Here,.....]
<h5
alok="" gupta="" <br=""> visit me at http://www.thisisalok.tk
|
|
|
|
|
Hello, I'm developing a application that does the communication wit TCP/Ip between two computers and send files between them, but i have some questions like i want to know what is the best way to develop it, for example socket or i don't know. Somebody can say me the best way ant what libraries can i use for develop it.
Thanks.
|
|
|
|
|
|
Thanks Ravi, but i have other question because i think that u know a lot. With this example i can see how can i implement my communication betwwen 2 computers with files but my applicacion start when i connect with a USB device and i have to pass the ID of the device to the server and the server has to see what files can download this device from the server. And i want to know how can i integrate my program that control the USB device and i know the ID of the device to pass this ID to the server and what will be the best way to develop the permissions in the server ( with a data base, only with text files, can u help me?, it's only to say to the client that whatever device has permiss to download for example only 5 files).
Thank you very much for your help.
/Jorge
|
|
|
|
|
You could check out http://www.msgconnect.com/[^] I haven't used it, but it looks good.
And as Ravi said there are lots of articles here on tcp/ip. Would be nice to abstract your problem out to higher level concepts than tcp/ip though.
Neville Franks, Author of ED for Windows www.getsoft.com and Surfulater www.surfulater.com "Save what you Surf"
|
|
|
|
|
densitet wrote:
the best way to develop it
Well that is up to you (unless you have someone to bounce your ideas of of)!
densitet wrote:
socket or i don't know.
I understand why you asked this question, but we both know that it is bogus.
Basicaly, what you see is what you get!
Curiosity: What is this sopposed to mean, "densitet"? (OpenOffice spell checher - has no ideas, and neither do I.)
INTP
"The more help VB provides VB programmers, the more miserable your life as a C++ programmer becomes."
Andrew W. Troelsen
|
|
|
|
|
after I finished a dialogue template ,I want to build the class "CMyDlg" of the dialogue template ,but the problem arised: Unable to open the files (D:\ly\CMyDlg.h,D:\ly\CMyDlg.cpp)for class "CMyDlg" . Who can tell me why? thanks!
|
|
|
|
|
This is not an uncommon message from ClassWizard. I get it about 30% of the time when creating a new class. To ensure that your class gets properly added to the project, exit the IDE, delete the temporary files (e.g., .opt, .ncb, .aps, .clw) , and re-open the project. The next time you invoke ClassWizard (Ctrl+W), all should be well.
"Opinions are neither right nor wrong. I cannot change your opinion. I can, however, change what influences your opinion." - David Crow
|
|
|
|
|
thank you, I get it. but why ? Is that vc's bug?
|
|
|
|
|
Yes, it is a bug. I see the same thing happen on all my systems (about 5 current - many in the past). Does not seem to matter what OS or if virus scanner, spybot scanner, firewall, etc. are installed and running or not.
|
|
|
|
|
I really need the email address of Allan Nielsen who is the author of the article "SuperGrid"
|
|
|
|
|
|
Hi, I am having a strange issue with StretchDIBits on Win2000 Server and multi-monitor. If the primary monitor is smaller then the secondary, and it is at the bottom.
When using StretchDIBits and goto PrintPreview I initially get a large white unpainted area in the preview window. The non-white part appears to be the same depth as the primary monitors height. Now if I invalidate the white parts, drag some other app over it, it now paints the invalidated white part with the correct bit of the image. Minimise then Restore the white part is back.
If I try using SetDIBitsToDevice this works without any white bits. But I must use StretchDIBits.
I have tried a number of other apps and if they use StretchDIBits, they also have issues.
Anyone got any thoughts
Cheers
Jason Carter
|
|
|
|