|
i have a menu with minimize,maximize and restore and they work but i cant figure out how to resize the controlls when i maximize or restore the dialog i need help
|
|
|
|
|
USE Window MEssage
ON_WM_SIZE();
this will help u in above cause
-----------------------------
"I Think It will Work"
-----------------------------
Alok Gupta
visit me at http://www.thisisalok.tk
|
|
|
|
|
HI ,,
I m Storing Value in Registry as String Value
in Windows 2000 / XP its store string value without double qoutes"" as... value
but in Window 98 it Save String Value with in qoutes... "value"
then after query a value then i try to mathc it but there is missmatch in Windows 98 due to " .." .
y any solution.
thanx
|
|
|
|
|
hian don't mind,i think you are wrong.
i am working on registry i have never this problem which you stating.
anyway what are using raw API's
or <atlbase> CRegClass
-----------------------------
"I Think It will Work"
-----------------------------
Alok Gupta
visit me at http://www.thisisalok.tk
|
|
|
|
|
HI i m using CRegKey Class.... and its methods for query etc.
Can u send me any code sampl ,, that can work on both
win 98 and win 2000/ XP
but if u see using regedit command too see registry values
in windows 98 .. or 2000/ Xp.
check there any registry value that is string value
in win 98 its as "value" but in XP and 2000 its as value simply without qoutations"".
thanx
|
|
|
|
|
IS your Problem Solved
-----------------------------
"I Think It will Work"
Formerly I AM Known As "Alok The Programer"
-----------------------------
Alok Gupta
visit me at http://www.thisisalok.tk
|
|
|
|
|
I think the Problm in Query to the key
here
CRegKey reg;
CString str = "cam";
BOOL bRetVal;
CString strTmp = "Software\\NDT\\Fovea";
bRetVal = reg.Open (HKEY_LOCAL_MACHINE ,(LPCTSTR)strTmp ) ;
if (bRetVal==ERROR_SUCCESS)
{
CString key = "Password";
char getValue[256] ;
DWORD d;
bRetVal=reg.QueryValue ( getValue , (LPCTSTR)key , &d);
if (bRetVal==ERROR_SUCCESS)
{
AfxMessageBox(" Working fine");
CString check = (CString)getValue ;
AfxMessageBox( "Value is ....||"+ check);
if (str.Compare (check) == 0)
{
AfxMessageBox( "Same");
reg.Close ();
}
else
{
AfxMessageBox( "Not same");
reg.Close ();
}
}
else
AfxMessageBox(" Query Failed");
}
else
{
AfxMessageBox( "Cannot Open");
reg.Close ();
}
It is messaging Query Failed..
|
|
|
|
|
I think the Problm in my Query to the key
here
CRegKey reg;
CString str = "cam";
BOOL bRetVal;
CString strTmp = "Software\\NDT\\Fovea";
bRetVal = reg.Open (HKEY_LOCAL_MACHINE ,(LPCTSTR)strTmp ) ;
if (bRetVal==ERROR_SUCCESS)
{
CString key = "Password";
char getValue[256] ;
DWORD d;
bRetVal=reg.QueryValue ( getValue , (LPCTSTR)key , &d);
if (bRetVal==ERROR_SUCCESS)
{
AfxMessageBox(" Working fine");
CString check = (CString)getValue ;
AfxMessageBox( "Value is ....||"+ check);
if (str.Compare (check) == 0)
{
AfxMessageBox( "Same");
reg.Close ();
}
else
{
AfxMessageBox( "Not same");
reg.Close ();
}
}
else
AfxMessageBox(" Query Failed");
}
else
{
AfxMessageBox( "Cannot Open");
reg.Close ();
}
It is messaging Query Failed..
|
|
|
|
|
Here is your Problem
Zeeshan Bilal wrote:
CString key = "Password";
char getValue[256] ;
DWORD d;
bRetVal=reg.QueryValue ( getValue , (LPCTSTR)key , &d);
remeber one thing,QuerryValue Third Parameter containing values goes Both IN and Out so if you want to run your Program properly change DWORD d; to DWORD d=255;//one space for null character
->Basically when the function is Called, the DWORD value Must contain the buffer size of string (which is going in as Second parameter for fetching required Value).
->when function return it contain the value for Total data in second Parameter Return .
-----------------------------
"I Think It will Work"
-----------------------------
Alok Gupta
visit me at http://www.thisisalok.tk
|
|
|
|
|
hi,
how do i determine if the contents of the dialog are changed from the initial values. i have edit boxes, check boxes, etc. after initialization of the dialog with the default values, how do i determine if the contents of the dialog are changed?
|
|
|
|
|
For editboxes you call GetModify (or send EM_GETMODIFY if you are not using MFC). Otherwise, you'll have to do it manually.
|
|
|
|
|
Most controls have a sort of OnChange Handler or OnClick...
Right click the control and choose "add event handler".
If something changes in your edit box you can check it against the original value.
good luck.
"If I don't see you in this world, I'll see you in the next one... and don't be late." ~ Jimi Hendrix
|
|
|
|
|
HI , i m using VC++ 6 and DirectX ( DirectShow)
Now i m compling my project in Release mood and Use MFC in Static Library ,, and it gives following Erorrs at compiling..
\\\\\\\\\\\\ Erorrs////////////
LINK : warning LNK4049: locally defined symbol "_strrchr" imported
Strmbasd.lib(wxdebug.obj) : error LNK2001: unresolved external symbol __imp__sprintf
Release/cam.exe : fatal error LNK1120: 1 unresolved externals
Error executing link.exe.
/////////
If i change to only to MFC shared Library its gives no Erorr at compile n works fine ......... y?
any hlp thanx
|
|
|
|
|
I have 2 things regarding MFC Class Wizard behaviour I wish to modify:
1. When using MFC Class Wizard's New Class Dialog, the content of Base Class ComboBox are all the standard MFC class. Is there anyway to add new classes into this ComboBox items.
2. When adding member variable of a class for certain dialog control, is it possible to override the default one, for example, instead of variable type of CButton, the system can allow us to select CRoundButton.
Thanks for any help provided.
|
|
|
|
|
alvinsanusi wrote:
1. When using MFC Class Wizard's New Class Dialog, the content of Base Class ComboBox are all the standard MFC class. Is there anyway to add new classes into this ComboBox items.
AFAIK No.
alvinsanusi wrote:
2. When adding member variable of a class for certain dialog control, is it possible to override the default one, for example, instead of variable type of CButton, the system can allow us to select CRoundButton.
Sure, use the Text Wizard to change CButton to CRoundButton.
"No matter where you go, there your are." - Buckaroo Banzai
-pete
|
|
|
|
|
Thank you for your information. But I don't understand what is a Text Wizard.
Do you mean I update the data in the header file directly? I know this can be done but I am looking for possibility to do it more efficiently.
|
|
|
|
|
Where can I get Informations or articles about several registry commands? For Example HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Policies\System\NoDispCPL.
|
|
|
|
|
|
http://support.microsoft.com/default.aspx?scid=kb;en-us;151176
http://www.microsoft.com/windows2000/techinfo/reskit/en-us/default.asp?url=/windows2000/techinfo/reskit/en-us/regentry/93827.asp
"When I was born I was so surprised that I didn't talk for a year and a half." - Gracie Allen
|
|
|
|
|
Can somebody tell me how to hide the wastebasket from the desktop?
|
|
|
|
|
Sure. Just remove (or rename) the HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Desktop\NameSpace\{645FF040-5081-101B-9F08-00AA002F954E} registry key.
"When I was born I was so surprised that I didn't talk for a year and a half." - Gracie Allen
|
|
|
|
|
Is there a way in c++ that I can do a file scan across a harddrive with multiple filters at once? Like search my HD for files that contain the filters
*abc*|*def|rty|
etc etc.
I may have quite a few of them and don't want to keep scanning over and over for each one. I would prefer to do this in C#, but I'm fairly sure you can't. I can put a managed wrapper around some c++ if it will do this.
TIA
|
|
|
|
|
Either you do the scan several times, or you look for all files, filtering it yourself - so, no can do.
|
|
|
|
|
Oh well, thanks for the info. I'll get all and filter myself then.
John
|
|
|
|
|
You could parse the filter into its individual patterns, sending each one to a separate thread. Each thread would then report back to the primary thread with its findings.
Or, for each file on the target drive, see if it matches any of the patterns in the filter. I did this once back about 11 years ago. It was a DOS-based utility and was a very good learning exercise.
"When I was born I was so surprised that I didn't talk for a year and a half." - Gracie Allen
|
|
|
|