Click here to Skip to main content
15,895,283 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: Phone Bill Pin
Christian Graus25-Nov-02 15:39
protectorChristian Graus25-Nov-02 15:39 
GeneralRe: Phone Bill Pin
Autunmsky25-Nov-02 15:48
Autunmsky25-Nov-02 15:48 
GeneralRe: Phone Bill Pin
Christian Graus25-Nov-02 15:57
protectorChristian Graus25-Nov-02 15:57 
GeneralRe: Phone Bill Pin
Autunmsky25-Nov-02 16:09
Autunmsky25-Nov-02 16:09 
GeneralRe: Phone Bill Pin
Christian Graus25-Nov-02 16:15
protectorChristian Graus25-Nov-02 16:15 
GeneralRe: Phone Bill Pin
Autunmsky25-Nov-02 16:27
Autunmsky25-Nov-02 16:27 
GeneralRe: Phone Bill Pin
Autunmsky25-Nov-02 16:34
Autunmsky25-Nov-02 16:34 
GeneralRe: Phone Bill Pin
Christian Graus25-Nov-02 16:40
protectorChristian Graus25-Nov-02 16:40 
I'd use a do-while, then have it run while the number of minutes > 59. Thus it will keep asking until a valid time is entered.

Autunmsky wrote:
an error statement message

What do you mean by this ? You want to use cerr ?

Autunmsky wrote:
but that would give me every number above 60 as an error.....

No, strip it into minutes and hours first, then check the minutes. The bit I entered to do that may be confusing, but basically an & ( a bitwise and ) only stores values common to both. Therefore it will only return the portion of the number that is < 100, which is the minutes.

So 1102 & 99 = 2, 34534535023 & 99 = 23, etc.



Christian

No offense, but I don't really want to encourage the creation of another VB developer. - Larry Antram 22 Oct 2002

Hey, at least Logo had, at it's inception, a mechanical turtle. VB has always lacked even that... - Shog9 04-09-2002

Again, you can screw up a C/C++ program just as easily as a VB program. OK, maybe not as easily, but it's certainly doable. - Jamie Nordmeyer - 15-Nov-2002
GeneralRe: Phone Bill Pin
Autunmsky25-Nov-02 16:44
Autunmsky25-Nov-02 16:44 
GeneralRe: Phone Bill Pin
Christian Graus25-Nov-02 16:48
protectorChristian Graus25-Nov-02 16:48 
GeneralCreateBitmap problem Pin
Anonymous25-Nov-02 13:16
Anonymous25-Nov-02 13:16 
GeneralRe: CreateBitmap problem Pin
Christian Graus25-Nov-02 13:26
protectorChristian Graus25-Nov-02 13:26 
GeneralRe: CreateBitmap problem Pin
Anonymous25-Nov-02 13:39
Anonymous25-Nov-02 13:39 
GeneralRe: CreateBitmap problem Pin
Christian Graus25-Nov-02 14:35
protectorChristian Graus25-Nov-02 14:35 
GeneralRe: CreateBitmap problem Pin
Anonymous26-Nov-02 3:41
Anonymous26-Nov-02 3:41 
GeneralActiveX control repaint Pin
billhao25-Nov-02 13:14
billhao25-Nov-02 13:14 
GeneralRe: ActiveX control repaint Pin
Roger Allen26-Nov-02 1:45
Roger Allen26-Nov-02 1:45 
GeneralRe: ActiveX control repaint Pin
billhao26-Nov-02 17:07
billhao26-Nov-02 17:07 
GeneralRe: ActiveX control repaint Pin
billhao28-Nov-02 21:47
billhao28-Nov-02 21:47 
GeneralDatabase problem in vc++(ODBC) Pin
MFC is the Best25-Nov-02 12:25
MFC is the Best25-Nov-02 12:25 
GeneralRe: Database problem in vc++(ODBC) Pin
dima_t25-Nov-02 17:19
dima_t25-Nov-02 17:19 
GeneralRe: Database problem in vc++(ODBC) Pin
MFC is the Best25-Nov-02 22:00
MFC is the Best25-Nov-02 22:00 
GeneralRe: Database problem in vc++(ODBC) Pin
dima_t26-Nov-02 0:57
dima_t26-Nov-02 0:57 
GeneralStatic library, Threads and Dialog boxes Pin
Clay25-Nov-02 11:17
Clay25-Nov-02 11:17 
GeneralRe: Static library, Threads and Dialog boxes Pin
Joaquín M López Muñoz25-Nov-02 11:31
Joaquín M López Muñoz25-Nov-02 11:31 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.