Click here to Skip to main content
15,921,959 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: \r\n -confused Pin
David Crow5-Feb-07 9:56
David Crow5-Feb-07 9:56 
QuestionRe: \r\n -confused Pin
Mark Salsbery5-Feb-07 6:31
Mark Salsbery5-Feb-07 6:31 
QuestionCArchive and long* Pin
eusto4-Feb-07 22:07
eusto4-Feb-07 22:07 
AnswerRe: CArchive and long* Pin
Cedric Moonen4-Feb-07 23:08
Cedric Moonen4-Feb-07 23:08 
GeneralRe: CArchive and long* Pin
eusto4-Feb-07 23:45
eusto4-Feb-07 23:45 
GeneralRe: CArchive and long* Pin
Mark Salsbery5-Feb-07 7:21
Mark Salsbery5-Feb-07 7:21 
QuestionNetwork module Pin
Member 35534024-Feb-07 21:54
Member 35534024-Feb-07 21:54 
AnswerRe: Network module Pin
Don Box4-Feb-07 21:57
Don Box4-Feb-07 21:57 
AnswerRe: Network module Pin
kasturi_haribabu4-Feb-07 22:02
kasturi_haribabu4-Feb-07 22:02 
AnswerRe: Network module Pin
toxcct4-Feb-07 23:01
toxcct4-Feb-07 23:01 
AnswerRe: Network module Pin
ThatsAlok6-Feb-07 20:15
ThatsAlok6-Feb-07 20:15 
QuestionVC6 to VC8 Pin
sheetal_064-Feb-07 20:08
sheetal_064-Feb-07 20:08 
AnswerRe: VC6 to VC8 Pin
Christian Graus4-Feb-07 20:17
protectorChristian Graus4-Feb-07 20:17 
GeneralRe: VC6 to VC8 Pin
sheetal_064-Feb-07 21:22
sheetal_064-Feb-07 21:22 
GeneralRe: VC6 to VC8 Pin
Mark Salsbery5-Feb-07 7:28
Mark Salsbery5-Feb-07 7:28 
QuestionRe: VC6 to VC8 Pin
David Crow5-Feb-07 4:59
David Crow5-Feb-07 4:59 
AnswerRe: VC6 to VC8 Pin
sheetal_065-Feb-07 16:47
sheetal_065-Feb-07 16:47 
Questiondata base connectivity Pin
Naveed Akram4-Feb-07 19:59
Naveed Akram4-Feb-07 19:59 
QuestionRe: data base connectivity Pin
David Crow5-Feb-07 4:57
David Crow5-Feb-07 4:57 
Questionhow can i calculate an angle between pointer of a clock by any time? Pin
Yanshof4-Feb-07 19:40
Yanshof4-Feb-07 19:40 
AnswerRe: how can i calculate an angle between pointer of a clock by any time? Pin
Christian Graus4-Feb-07 19:56
protectorChristian Graus4-Feb-07 19:56 
GeneralRe: how can i calculate an angle between pointer of a clock by any time? Pin
Mark Salsbery5-Feb-07 7:32
Mark Salsbery5-Feb-07 7:32 
GeneralRe: how can i calculate an angle between pointer of a clock by any time? Pin
Christian Graus5-Feb-07 8:54
protectorChristian Graus5-Feb-07 8:54 
AnswerRe: how can i calculate an angle between pointer of a clock by any time? Pin
Stephen Hewitt4-Feb-07 20:19
Stephen Hewitt4-Feb-07 20:19 
No need for trig. First we'll just consider the hour hand. On a clock 12 hours is 360 degrees. So the angle of the hour hand (Ah) is given by the following formula (h is the hours):
Ah = 360.0*h/12.0
This formula assumes that Ah can be fractional so 1:30 would be represented as 1.5.

Now we’ll work in the minute hand (m is minutes). On a clock 60 minutes is 360 degrees, So the angle of the minute hand (Am) is given by the following formula:
Am = 360.0*m/60.0

Now we’ll put this together. First assume that we feed in the hours as an integer since the fraction part can be calculated from the minutes. In this case we should adjust h as follows:
h = h+m/60.0

After this we just use the above two formulas. I’ll leave the rest to you. There are some gotchas.


Steve

GeneralRe: how can i calculate an angle between pointer of a clock by any time? Pin
kasturi_haribabu4-Feb-07 21:12
kasturi_haribabu4-Feb-07 21:12 

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.