|
Programmatically, you can find out the size and position of the taskbar with the following:
// Find the taskbar
HWND hWndTaskbar = FindWindow("Shell_TrayWnd", NULL);
RECT rc = {0,0,0,0};
::GetWindowRect(hWndTaskbar, &rc);
Then just work around it.
|
|
|
|
|
I have a question, that is, how to show a window maximized but not covering the task bar.
|
|
|
|
|
ShowWindow ( hwndYourWindow, SW_MAXIMIZE );
--Mike--
http://home.inreach.com/mdunn/
A recent survey reports that 1/4 of all internet users in England surf for porn.
The other 3/4 just didn't want to admit it.
|
|
|
|
|
I'm having a terrible time with the date and time picker control. I 'm using the "Microsoft Date and Time Picker Control, version 6.0" which created dtpicker.h for me, but maybe there's a better way to go about this, because I can find no documentation for it anywhere.
Life is quite ironic because I figured out my problem just now as I was writing this email. But my solution isn't very elegant. I was just wondering if anyone could provide me with a good place to get some information on this class.
Right now I don't know how to properly initialize the VARIANT variable that I pass to:
void CDTPicker::SetMinute(const VARIANT& newValue)
(This is just an example the other "Set" functions are equally thwarting.)
So I'm cheating by calling GetMinute() first to set the value, which I then change slightly. But I would appreciate it if someone could tell me what I would need to do to avoid this hack.
Thank you
-john
|
|
|
|
|
Why are you using ActiveX control? CDateTimeCtrl doesn't expose some functionality?
Tomasz Sowinski -- http://www.shooltz.com
|
|
|
|
|
I have the feeling that the answer is, "Because I am a beginer and don't know quite what I'm doing." I'm using VC 5, and I couldn't figure out how to put a CDateTimeCtrl into my project so I used the ActiveX control since that's the only thing that I could figure out how to put into my dialog. Any advice on how to mend the error of my ways would be appreciated.
-john
|
|
|
|
|
HI Folks
I am writing an application which receives traps from different network devices and the output is in the form of predefined data structure, and the application receives traps continously it is a NT Service.
Now i want to send this output to the other application as input using a Message Queue concept can any one help me in this regard ASAP.
Any kind of help is appreciated
Thanks in Advance
Sudheer
sudheer reddy bandaru
|
|
|
|
|
You want to use WM_COPYDATA.
|
|
|
|
|
How do I enable this for Control Variables. ie m_ctlControl. It worked on my last install but I had to reinstall Windows and now it doesn't work. Can anyone help me this is a pain in the a**.
-Matt Newman
|
|
|
|
|
Hy!
I have deleted the files *.clw and *.aps in my project folder adn it work. This files are automaticly rebuil by IDE ( the clw file is generated when you first acces ClassWizard ... just selcet there all the classe in your project )
Bye,
BogdanO
...the night is long ... but not long enought to do some real coding ...
|
|
|
|
|
I think it's enough to delete XXX.ncb file
Jerzy
|
|
|
|
|
I guess i should do this with all of those files b\c of transferring from CD to HD. I should of thought of this earlier. Oh well thanks for the help.
-Matt Newman
|
|
|
|
|
Now tell me this why does a LineScroll(1) for a rich edit control work in win2000 and not in me. In win2000 it actually scrolls down but in winMe it just stays on the same line when i insert text.
|
|
|
|
|
Is there a way to get an edit control to right justify? Setting the property to right justify doens't seem to have any effect.
Thanks.
Richard
|
|
|
|
|
Check out this page, it should help you out.
There's a section on "Algning Controls"
http://www.codeproject.com/miscctrl/usingctrlsindialogs.asp
good luck
-john
|
|
|
|
|
Is there a better way to search an ODBC table for a particular record than to iterate through the table?
Thanks.
Richard
|
|
|
|
|
Try to put a WHERE clause in your SELECT statement like this :
SELECT * FROM table WHERE name='whatEver';
This way you will have only the records that interest you.
Bye,
BogdanO
...the night is long ... but not long enought to do some real coding ...
|
|
|
|
|
I am writing an application in which I need to capture all keyboard system keys in Win2k until the user logs in. I have managed to do so for all combinations except ctrl+alt+del using SetWindowsHookEx()in Winuser.h and a callback function. In Win2k this combination produces the Windows Security dialog with access to the Task Manager, and thus the ability to kill a process. I have no trouble capturing any dual combination of system and non-system keys, including anything with each of ctrl, alt and del. Is there a certain syntax needed to get all three of these keys, or is it just not possible to persuade Windows to let me handle things?
Lee Middleton
|
|
|
|
|
I think that win2k will not let you do this for security reasons. If you can trap ctrl-alt-del, then you can create a trojan which will mimic the logon screen and ask for a password.
(2b || !2b)
|
|
|
|
|
Hi,
I had problem of CTRL+ALT+DEL last few days. I searched discussion board for that but didnot found proper solution. I only found that use Gina Dll inplace of microsoft's MSGina.dll. That is not proper solution. Now i solved my purpose to disable CTRL+ALT+DEL in win2000. I don't know about WinNT but it will work for it also. So i want to contribute this part to all user.
Steps are as follows :
1. Open Microsoft SDK Examples. In That Example, Open GinaStub example.
2. Find function
int
WINAPI
WlxLoggedOnSAS(
PVOID pWlxContext,
DWORD dwSasType,
PVOID pReserved
)
3. In this function remove all code written and only return like this
return WLX_SAS_ACTION_NONE;
4. So it looks like this...
int WINAPI WlxLoggedOnSAS(
PVOID pWlxContext,
DWORD dwSasType,
PVOID pReserved
)
{
return WLX_SAS_ACTION_NONE; // Return code for doing nothing ... return to desktop
}
5. Now Make dll.
6. Goto Registry by regedit.
7. goto
\HKEY_LOCAL_MACHINE\Software\Microsoft\Windows NT\CurrentVersion\Winlogon
(WindowsNT is also there. So dont confused it is | Windows(Space)NT | okay)
8. Make New string value and give data like this
name : GinaDLL
Type : REG_SZ
Data : C:\WinNT\System32\mygina.dll (path of your gina dll(suppose mygina.dll))
9. Reboot computer And your control+alter+delete not worked at all.
----------------------------------------------------------------------------------------
If You want this mygina.dll then contact me on my personal email address.
manish_ld@rediffmail.com
m_codeproject@rediffmail.com
if still not contact me then and then try : pansiniya_manish@hotmail.com
----------------------------------------------------------------------------------------
Thanx in advance.
--------------------------------------------------
Say Whatever You Know.
Helping other people is good for health.
=========
Manish
=========
---------------------------------------------------
|
|
|
|
|
Hello;
Which is the return value? an address or a reference or a pointer, from func1 and func2.
int& func1(int* myref)
{
int int_temp;
int_temp = *myref;
return int_temp;
}
int* func2(int& myref)
{
int* int_temp;
int_temp = &myref;
return int_temp;
}
void main()
{
int int_main = 100;
int ret_val;
ret_val = func1(&int_main);
func2(int_main);
}
What is the difference(s) reference and address-of operator?
|
|
|
|
|
Well, if you specify the type followed by an ampersand you get a reference, if you have an ampersand before a variable that already exists, you get an address:
CString& strReference; // this would be a reference
CString* pString = &strAddress; // &strAddress would give you the address
so...
func1 returns a reference to int_temp and func2 would return the address of myref because even though its a reference as it is being passed in you are asking for the address of it with &int_myref;
Bret Faller
Odyssey Computing, Inc.
|
|
|
|
|
Thank you Bret...
I have another question;
In the;
int &putint() { return a; }
if calls;
putint()=30;
"a" member takes "30" value. In the simple way a=30. What's behind of this?
|
|
|
|
|
ok so...the function looks like this, correct?
int& putint() {
int a = 30;
return a;
}
well you get 30 because you are returning a reference to a (which has the value 30). Take this simple example:
int a = 30;
int& putint() { return a; }
void main()
{
int& nNumber = putint();
printf("%d", nNumber);
nNumber = 15;
printf("%d", a); // a now = 15
}
in this example we get a reference to a from putint and store it in nNumber. The first time we print nNumber we get 30. now when we set nNumber to 15 it also sets a to 15 because they point to the same number (they refer to each other) so basically they are the same variable and will vary equally.
Bret Faller
Odyssey Computing, Inc.
|
|
|
|
|
Thank you for your helps...
|
|
|
|