|
How can I detect if a user clicked outside a modal dialog?
|
|
|
|
|
Use mouse hooking by calling SetWindowsHookEx
|
|
|
|
|
Or get "control" over the mouse by calling "SetCapture". When use clicks you will get the click in your OnLbnDown ... and you check the mouse position.
Normally if you don't need that click you should imediatelly release the mouse by: ReleaseCapture.
Tutu.
|
|
|
|
|
Hi,
how can i integrate MSDN with Visual Studio 6. VS6 is alreay installed. now i have installed MSDN but when i press F1 in VS6, it says no MSDN collection. plz guide how can i tell VS6 about MSDN.
thanks,
omar lodhi
|
|
|
|
|
Run Installation CD of VS 6.0 again U can skip reintalling the software again by making no changes in the installed and uninstalled Features. After successful installation the Software automatically ask for MSDN CD.
I knew other ways, but since I did it long time ago I can't tell U precise way.
Hope is helps
Cheers!!!!
Siddharth
|
|
|
|
|
great wrote:
how can i integrate MSDN with Visual Studio 6. VS6 is alreay installed. now i have installed MSDN but when i press F1 in VS6, it says no MSDN collection. plz guide how can i tell VS6 about MSDN.
Which version of MSDN have you installed. If it is after October 2002, then it won't integrate with VS6, it only integrates with VS.NET and later.
Michael
But you know when the truth is told,
That you can get what you want or you can just get old,
Your're going to kick off before you even get halfway through.
When will you realise... Vienna waits for you? - "The Stranger," Billy Joel
|
|
|
|
|
I hope that's a typo - to the best of my knowledge, October 2001 is the cutoff date.
Steve S
|
|
|
|
|
Steve S wrote:
I hope that's a typo - to the best of my knowledge, October 2001 is the cutoff date.
You might be right. I thought it was Oct 2002 but I haven't got my disks handy to check. 2001 seems such a long time ago. All I know for sure it was October some year
Michael
But you know when the truth is told,
That you can get what you want or you can just get old,
Your're going to kick off before you even get halfway through.
When will you realise... Vienna waits for you? - "The Stranger," Billy Joel
|
|
|
|
|
Depending on your MSDN version it may not be possible to link directly with VC6. I believe that after January 2002 the MSDN only links with .NET it is still accessable through its shortcut however.
Sorry it may be January 2002 is the 1st .NET only version.
Ant.
|
|
|
|
|
Hello Guys:
i want to craete a tool bar in my dialog Box i am using following code in the OnInitDialog()
..........
m_ToolBar.Create(this);
m_ToolBar.LoadToolBar(IDR_TOOLBAR1);
m_ToolBar.ShowWindow(TRUE);
but i can't see any toolbar, any solutions?..
Thanks
Muhammad Ahmed
ahmed
|
|
|
|
|
i guess you forgot to make it visible:
VERIFY( m_toolbar.Create(WS_CHILD | WS_VISIBLE | CCS_NOPARENTALIGN |
CCS_NORESIZE | TBSTYLE_FLAT | TBSTYLE_TOOLTIPS, CRect(XX, XX, XX, XX),
this, AFX_IDW_TOOLBAR) );
|
|
|
|
|
i've used
m_ToolBar.CreateEx(this,TBSTYLE_FLAT,WS_CHILD | WS_VISIBLE | CBRS_ALIGN_TOP, CRect(10,10,100,100), AFX_IDW_TOOLBAR);
m_ToolBar.LoadToolBar(IDR_TOOLBAR1);
m_ToolBar.ShowWindow(TRUE);
but toolbar is invisible
|
|
|
|
|
i've tested it. it works in my dialog.
CListCtrl m_toolbar;
m_toolbar.Create(WS_CHILD | WS_VISIBLE | CCS_NOPARENTALIGN |
CCS_NORESIZE | TBSTYLE_FLAT | TBSTYLE_TOOLTIPS, CRect(0, 0, 100, 100), this, AFX_IDW_TOOLBAR);
check if maybe sth in your program is on conflict with some of the styles.
|
|
|
|
|
u've used
CListCtrl m_toolbar;
i am using
CToolBar m_ToolBar;
ahmed
|
|
|
|
|
sorry, i'm still asleep.
i've used CToolBarCtrl.
|
|
|
|
|
You used CToolBar or CToolBarCtrl ? In dialogs, you should use CToolBarCtrl .
CToolBar is useful only in frame windows (only frame windows support docking)
Robert-Antonio
"Love without sex is like a fish without antlers"
|
|
|
|
|
I am trying to use a COleDateTime object and use the method ParseDateTime() to convert a string to date/time format.But it returns an invalid status for the object every time the method is called.I have tried all formats of date,date/time as mentioned in MSDN, but none works.
In Debug mode, I am also not able to step into the ParseDateTime function.
COleDateTime objDate;
strDate = _T("2004/01/01");
objDate.ParseDateTime(strDate, 0);
I have included <afxdisp.h>
The same code works fine in another new workspace/project. But in my project/workspace, it isnt producing any result.
Can anyone please let me know what might be wrong?
|
|
|
|
|
It seems strange that you can't step into ParseDateTime! It is declared in \Microsoft Visual Studio\VC98\MFC\SRC\OLEVAR.CPP
In my experience it would seem that the project could require a complete rebuild. Strange problems like that are normally cured with a complete clean and rebuild.
Ant.
|
|
|
|
|
I tried that too..it still doesnt work..
|
|
|
|
|
Hello!
- check with dependency viewer what libraries are truly loaded (maybe you have two copies of some dll?)
- MSDN says that only formats
DD-MM-YYYY
MM-DD-YYYY
YYYY-MM-DD
are properly handled - see VarDateFromStr
- maybe instead of ParseDateTime you can use COleDateTime::Format() ?
- check the difference in locale settings (control panel) for date/time format on machines where it works, and not.
|
|
|
|
|
Thanx will try
|
|
|
|
|
Hi. How do you set the path for your source files if they are in a different directory then the project directory in Visual C++.Net. I tried to go to Tools/Options/Projects and added the path to the list of VC++ source file directories but when I compile my code I still get link errors.
|
|
|
|
|
#define "myFold\myHeader.h"
TOXCCT alias Nicolas C.
|
|
|
|
|
Hello!
If you get link errors, maybe include source file in project? Simply add it as a existing file to project.
|
|
|
|
|
I am trying to output binary numbers to the standard stream. The problem is that I want to display them in the mathematically correct format.
Using 7.5 as a decimal example, to display it as:
111.1
Do I have to write my own function to convert these, or is there a simpler way?
Thanks,
Joe Hoppe
|
|
|
|