|
RSAK wrote: But someone have not understood it properly and giving different explanation to it.
Are you talking about Iain? Nobody can understand your problem properly until *you* explain it properly. If there's a fault, it's yours, please.
Nobody can give you wiser advice than yourself. - Cicero
.·´¯`·->Rajesh<-·´¯`·.
Visual C++ MVP
|
|
|
|
|
Yes. I still confused with the following answer given by him.
void CTestDlg::OnList_SelChange(void)
{
int iIndex = 0;
iIndex = m_ctrlList.GetCurSel();
if(iIndex == LB_ERR)
{
return;
}
if(iIndex == 3)
{
m_ctrlList.SetCurSel(-1);
}
}
|
|
|
|
|
|
But on friday i have seen his Iain name in that post .
|
|
|
|
|
No. If i need to use EnableWindow() then i wouldn't have raised this question.
Let us consider the following
CEdit m_MyEditCtrl;
m_MyEditCtrl.SetReadOnly(TRUE);
m_MyEditCtrl.Enable Window(FALSE);
Would the above two stmts are same? please answer.
|
|
|
|
|
Please stop spamming. I've answered this question here[^]. Here's another chance to express yourself better: What exactly is that you want to do?
Nobody can give you wiser advice than yourself. - Cicero
.·´¯`·->Rajesh<-·´¯`·.
Visual C++ MVP
|
|
|
|
|
void CTestDlg::OnList_SelChange(void)
{
int iIndex = 0;
iIndex = m_ctrlList.GetCurSel();
if(iIndex == LB_ERR)
{
return;
}
if(iIndex == 3) // Suppose you do not want to select fourth item
{
m_ctrlList.SetCurSel(-1);
}
}
|
|
|
|
|
Didi you read the subject?
|
|
|
|
|
Did you forget your manners today?
Someone has kindly offered you a direction to look at for a solution, and that's the tanks they get?
You ask how to make the combobox readonly - you're told a drop list *is* read only.
You clarify that you know that, but you don't want the users changing selection.
Someone tells you how to stop that happening, by disabling the control.
You don't want that. You want the user to think "This app is broken. When I click on an item, nothing happens" instead of giving them useful visial cues.
This user shows you how to capture selection changing, and then rejecting it (ok, he made it no selection, but it's not hard to jump to reselecting the item you want), and you be rude to him.
Your's needing another shot of caffeine to withstand ingrates,
Iain.
Plz sir... CPallini CPallini abuz drugz, plz plz help urgent.
|
|
|
|
|
Hi i am not here to hurt anyone.
sometimes my questions may lead you think like that.
Anyhow answer i got.-:: "Its not possible to make read only as like CEdit".
Thanks.
|
|
|
|
|
RSAK wrote: Hi i am not here to hurt anyone.
I may have been a little harsh... (Shocking, I know).
Iain.
Plz sir... CPallini CPallini abuz drugz, plz plz help urgent.
|
|
|
|
|
Hi,
My current operating system is Windows Vista. Earlier my application used to run in Windows 2003. We have a place where some settings are written to HKEY_LOCAL_MACHINE . Now in Windows Vista a non administrative user cannot write anything to registry. We have a proposal to write some settings to ini file. But Vista doesn't have a ini file. So I need to create a private ini file or else some other file and move those settings to this ini file. Can someone send me a code snippet for creating and writing to a private ini file. This file should be independent from one terminal services session to another.
Thanks,
Venkat
|
|
|
|
|
In Vista you can still write to registry but you have to use HKEY_CURRENT_USER.
For ini files I use CIni[^].
-Saurabh
|
|
|
|
|
I'm surprised you didn't have this problem before under windows XP when your users ran as a non-administrator.
What do you say? You required your users to make themselves vulnerable to messing up their system by visiting one bad website?
Shame on you sir!
/rant over.
Can you not change the permissions on the few registry keys you need to get access to? I'd need to check on vista at home, but regedt32 (rather than regedit) will let you do this.
Iain.
Plz sir... CPallini CPallini abuz drugz, plz plz help urgent.
|
|
|
|
|
Hello everyone,
When open or delete a file (or something else) by a handle, there is error like the handle is occupied by some other parties.
My question is, what is the general technique or tools to find out which process occupies the handle?
thanks in advance,
George
|
|
|
|
|
Im not sure do you need to GetModuleFileName?
|
|
|
|
|
No Hamid,
I do not mean to get the name of the handle, but mean to get the name of the module/binary which holds the handle. Any ideas?
regards,
George
|
|
|
|
|
|
Thanks Naveen,
I have tried to install this tool, but it seems it only works for Windows XP and Windows Vista from error message box?
I need to debug on Windows Server 2003. Any ideas?
regards,
George
|
|
|
|
|
George_George wrote: I need to debug on Windows Server 2003. Any ideas?
Ya it support only, XP and Vista, if you want it work on 2003, you need to rebuild the driver code plus some other modifications.
Any way This[^]utility seems to support window 2003 also.
|
|
|
|
|
Thanks nave,
I have found out Process Explorer also has similar function.
regards,
George
|
|
|
|
|
Hi all.
I am trying to open Xml file using parser..
I am using MSXML2.dll.
When i debug It is throughing Exception in this line
/////////////////////////////
EVAL_HR(objDOMDoc.CreateInstance("Msxml2.DOMDocument.2.0"));
/////////////////////////
In this line i am getting Error...
when I used MSXML4.dll..It is showing error "Cannot open MSXML4.dll..
any suggestions.
Thank you
manju
Hi..
I am Mnaju.I have Completed my B.E Computers Science.Lokking for a job.I am interested in VC++
manju
|
|
|
|
|
When dialog initialization, OnSize(UINT nType, int cx, int cy) run times more than one. The cx is Specifies the new width of the client area, but
cx is not same in all times. How to get the right cx which is the real size?
|
|
|
|
|
hanlei0000000009 wrote: cx is not same in all times. How to get the right cx which is the real size?
Each time it represent the current real size. The last time is possibly of interest for you.
If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler.
-- Alfonso the Wise, 13th Century King of Castile.
This is going on my arrogant assumptions. You may have a superb reason why I'm completely wrong.
-- Iain Clarke
[My articles]
|
|
|
|
|
if you want the size, call GetClientRect() in (and after) OnInitDialog
Greetings from Germany
|
|
|
|