I didn't get you in your previous reply. If you are asking what i am trying to accomplish is clear. I want to expire my application on particular date. but i can't use local time/date to check it as user may change its local time/date. That's why i am thinking of some other way.
If that is the goal then may I ask why do you want you application to suddenly stop working for every user. What purpose the purpose of this?
There is no suggestion I can give you for finding time, even if you assume that you want time in a particular time zone. As far as I know there is no way for a standalone computer to determine current time. In fact no device can have such capability because time is not absolute.
My suggestion is to follow what beko said. In addition to that you can mark it as expired once the expiry date reached. After that you should not allow the application to continue working even if the date is changed back.
I am working on an mfc application in which I am opening a dialog box containing smileys on button click. Now what I want is to close the dialog dialog box with smileys when mouse click event is fired anywhere on the screen.
1) A CDialog derived CDlgClass
2) A CCmdTarget derived CAnotherClass
I am unable to disable an item of the launched context-menu.
Please follow the comments below to track the problem.
//On Right-clicking the dialog, this function is called
VOID CDlgClass::OnContextMenu(CWnd* pWnd, CPoint point)
//Here, another class' ShowContextMenu is called to load the menu and show it
m_pAnotherClass->ShowContextMenu( this, point);
//Control reaches here when menu item 1 is clicked
void CDlgClass::OnUpdateMenuItemEdit1(CCmdUI* pCmdUI)
//Control is expected to reach here before the menu launches but doesn't do so. Why?//I am expecting menu Item 1 to be disabled before it shows up.
VOID CAnotherClass::ShowContextMenu(CWnd *pDlg, CPoint point)
CMenu *pcmPopupMenu = cmCtxtMenu.GetSubMenu(0);
pcmPopupMenu->TrackPopupMenu (TPM_RIGHTBUTTON|TPM_LEFTALIGN, point.x, point.y, pDlg );
What could be the problem with disabling the menu item although I could actually activate the menu item handler
The function CDlgClass::OnUpdateMenuItemEdit1(CCmdUI* pCmdUI) itself is not getting called before launch of the menu,
when the menu is loaded in a different class.
I wanted to know if one exe can be controlled by another exe. for example i have 2 dialog boxes which are 2 different exes. now in the first exe i am doing a simple addition where there are 3 edit boxes and a button to calculate. now in the 2nd dialog box i only have one button "calculate". now when i click on the 2nd exes calculate button, the event on the first exes button should execute. i hope i have made my problem clear. give me some leads for this.
I have referred a term "ActivexDll" I think there exist a concept called ActiveDll, if I am wrong then kindly excuse me and clarify "Difference between a Dll and ActiveX Components ".
If I am correct then can any one explain me the difference between a Dll and an ActicexDll.
Last Visit: 31-Dec-99 19:00 Last Update: 4-Mar-24 16:17