Search:

Type: Posts; User: JasonD

Page 1 of 12 1 2 3 4

Search: Search took 0.02 seconds.

  1. Ken Fitlike, thanks for the reply. 1. I...

    Ken Fitlike, thanks for the reply.

    1. I created a very small test program to test this out, and now I find that setting the extended style within WM_INITDIALOG is completely fine, even if the...
  2. I agree. It is highly recommended, and worth...

    I agree. It is highly recommended, and worth every penny.
  3. WS_EX_COMPOSITED style (double buffering) problems

    Hello,

    I have two problems with this style:

    1. If a dialog box is given this style during the WM_INITDIALOG message (i.e. as the dialog is being created, before it is displayed), AND if the...
  4. Replies
    14
    Views
    5,594

    Micko, regarding your private message, I believe...

    Micko, regarding your private message, I believe it is best to reply on the forum (and I will apologize right now for not having read any of the posts so far):

    There is an MSDN page that explains...
  5. Replies
    9
    Views
    3,677

    Oh, ok. No problem. It's hard to answer...

    Oh, ok. No problem.

    It's hard to answer questions like the above because it really gets into deeper issues that shouldn't concern a beginner. I really believe that rectangle program should have...
  6. Replies
    9
    Views
    3,677

    Yes, games are quite different from other Windows...

    Yes, games are quite different from other Windows programs. This is sort of the point I was touching upon earlier. The program Petzold wrote is similar to an old graphics DOS program, and games are...
  7. Replies
    9
    Views
    3,677

    Ok, I jumped the gun by saying that no one uses...

    Ok, I jumped the gun by saying that no one uses return codes. I should say that most people do not use them, as most normal applications do not require their use. I still pass back different values...
  8. Replies
    9
    Views
    3,677

    Micko, 1. Yes, just cast it to an int. ...

    Micko,

    1. Yes, just cast it to an int. Microsoft says to pass the message's wParam, so it should be ok. Since DOS, no one really cares about the return value anymore, anyway.

    2. This program...
  9. Thread: Tutorials

    by JasonD
    Replies
    6
    Views
    1,103

    I started learning Windows through tutorials on...

    I started learning Windows through tutorials on the 'net, and realized that they just did not explain anything in much detail. At this point, I was basically hacking. It's not a good feeling. I...
  10. Thanks for the info, Codeplug. I am not using...

    Thanks for the info, Codeplug. I am not using MFC, though. It is just a pure Win32 application, so this could not be the problem. Unless it is possible that these MFC headers are being accessed in...
  11. Dante, thanks for the reply. No, I am not...

    Dante, thanks for the reply.

    No, I am not using any 3rd party libs. I have searched every function (that my programming team created) of the entire project, and InitCommonControls(Ex) is nowhere...
  12. Is comctl32.lib required for progress bar controls?

    Hello,

    In a test application, I have a progress bar defined in one of my dialog boxes. In order for CreateDialog to succeed, I need to add comctl32.lib to my project, and also call...
  13. Replies
    4
    Views
    1,516

    I see that I am not the only one perplexed by...

    I see that I am not the only one perplexed by this. Note that the MSDN page states: "...message is sent to all top-level windows when the system detects more than 12.5 percent of system time over a...
  14. Replies
    4
    Views
    1,516

    Is WM_COMPACTING obsolete?

    Is the WM_COMPACTING notification obsolete? Its MSDN page states that the message is provided "only for compatibility with 16-bit Microsoft® Windows®-based applications".

    Should it be processed,...
  15. Thread: Random Number

    by JasonD
    Replies
    42
    Views
    5,069

    The easiest way is this: 1. create the list...

    The easiest way is this:

    1. create the list storing 1..25, in order, in the indices 0..24
    2. loop through the indicies, i = 0..24, pick a random index, j = 0..24, and swap the two.

    This way,...
  16. Thread: Random Number

    by JasonD
    Replies
    42
    Views
    5,069

    The book's contents may be truly random numbers,...

    The book's contents may be truly random numbers, like those obtained by throwing dice, rather than pseudo random numbers generated by a computer. Basically, one set can be reproduced exactly, the...
  17. Thread: Random Number

    by JasonD
    Replies
    42
    Views
    5,069

    That would be a very simple one that doesn't work...

    That would be a very simple one that doesn't work well, but, yes, that is the general idea (it should also store the new result back into seed, however). It is a formula that uses the last number...
  18. Thread: Random Number

    by JasonD
    Replies
    42
    Views
    5,069

    Take a look at this site: http://www.lavarnd.org/

    Take a look at this site:
    http://www.lavarnd.org/
  19. Thread: Random Number

    by JasonD
    Replies
    42
    Views
    5,069

    Give me the same random number generator and the...

    Give me the same random number generator and the same starting seed as you use, and I can tell you what numbers will appear when. Imagine if a VLT used such a method, and you found out how it...
  20. Thread: Random Number

    by JasonD
    Replies
    42
    Views
    5,069

    Another problem with using % is that some...

    Another problem with using % is that some numbers, such as 6 in the case of a dice game, are not divisible into RAND_MAX+1 (the number of possible return values from rand() ). This means the...
  21. Replies
    4
    Views
    2,506

    The code may have been taken from Petzold. Here...

    The code may have been taken from Petzold. Here is his code:



    int CDECL MessageBoxPrintf (TCHAR * szCaption, TCHAR * szFormat, ...)
    {
    TCHAR szBuffer [1024] ;
    va_list pArgList ;...
  22. Replies
    4
    Views
    2,255

    Btw, since you are NOT using the latest SDK, then...

    Btw, since you are NOT using the latest SDK, then you should be able to compile the program using the OLD style DialogProc, like so:

    BOOL CALLBACK DialogProc( HWND hwndDlg,
    UINT...
  23. Replies
    4
    Views
    2,255

    You need the latest SDK to access the latest...

    You need the latest SDK to access the latest Windows Data Types:
    http://msdn.microsoft.com/library/en-us/win64/win64/the_new_data_types.asp

    INT_PTR is 32-bits in size for 32-bit Windows, and...
  24. Yes, there should already be two default...

    Yes, there should already be two default configurations - Debug and Release. You should be able to select the Release configuration, and then modify it to your liking (i.e. change the run time...
  25. Replies
    1
    Views
    951

    I have never tried the program with a shared...

    I have never tried the program with a shared printer. Let me know if you resolve the problem. If it is a bug in the code, or even some worthwhile noting for other readers, I will add it to my...
Results 1 to 25 of 278
Page 1 of 12 1 2 3 4