Compare the hour value and use the bigger hour minus the smaller hour, let this be h. If both are the same hour, just subtract the minutes. Next, use the minutes from the "bigger" hour to minus the minutes from the "smaller" hour, let this be m. If the m is negative, subtract 1 from the h, and add 60 to m.
whatever whatever com
Posts
-
time counter -
MFC or Windows Forms ApplicationI've just upgraded from Visual C++ 6 to Visual Studio 2005. I saw a new type of GUI designer tool called Windows Forms Application, apart from the old MFC. The former has a lot of features and looks more intuitive than the traditional MFC. However, the codes are loking pretty funnny to me. May I know whats the difference between MFC and WFA, in terms of pros and cons? Thanks.
-
hash_map in VC6 [modified]Sorry. its using the hash_map> container. any idea if i can download the library and include it in my project? Thanks.
-
hash_map in VC6 [modified]Hi, I am trying to use some open source codes which is trying to include the header and it's not found in VC6. May I know if it is possible for me to download the missing header and source somewhere and use it in my project? I saw a website as below: http://www.cs.cmu.edu/afs/cs.cmu.edu/user/gchen/www/download/stl/download.html[^] How can I use it? Thanks. -- modified at 4:27 Monday 22nd January, 2007
-
Is it possible to "drag and drop" between listboxes in visual c++6?Thanks! U made my dae. Also thanks to all others who had given their comments. :-D
-
Is it possible to "drag and drop" between listboxes in visual c++6?Yeah. Thanks for the effort, but I was looking for dragging and dropping from one listbox to another, rather than within the same listbox for arrangement purpose. I guess such a feature is not supported in VC6. :((
-
Is it possible to "drag and drop" between listboxes in visual c++6?Can't really find anything relevant to VC6. :(
-
Is it possible to "drag and drop" between listboxes in visual c++6?CDragListBox allows drag and drop within its own listbox for arrangement purposes but not onto another list box. :sigh:
-
Is it possible to "drag and drop" between listboxes in visual c++6?I had seen a couple of articles on drag and drop between listboxes on the .NET framework IDE whihc uses some very helpful built-in functions. However, I am still on VC 6. Just wondering if it is possible to implement the drag and drop feature? Any clues and suggestions welcomed. Thanks.:-O
-
How to set the position of the blinking text cursor in a CEdit box.Thanks for your input. the SetSel method has worked well for me. Dint investigate the WM_MOUSEACTIVATE method as using mouse position may complicated matters for me. anyway, thanks!;)
-
How to set the position of the blinking text cursor in a CEdit box.Thanks for the sugestion. At least I now know that blinking cursor is called a caret. :laugh:
-
How to set the position of the blinking text cursor in a CEdit box.This is indeed a great method! works nice n sweet. Thanks.:-D
-
How to set the position of the blinking text cursor in a CEdit box.Hi, I am doing some GUI dialogs in MFC. The problem goes like this: I have a parent dialog which can create a modeless child "keyboard" dialog,with some special prescribed keys. The user is suppose to click on keys on the "keyboard" dialog and the input is suppose to appear on an Edit box on the parent dialog. The issue is that I want the user to have the freedom of using both the physical keyboard and the "Keyboard" dialog. So, I tried to use SetFocus() onto the Parent's Edit box after hitting keys on the "Keyboard" dialog. The problem is that the after SetFocus() is issued, the blinking text cursor is always at the beginng left end of the Edit box regardless of whether there is any text in the edit box. This poses a problem when the user changes to using the physical keyboard since text will be input at the beginning of the current text rather than from the end of the text in the Edit box. So my question is how do I set the position of the blinking text cursor to the end of the text after SetFocus()? Thanks alot! :-D