Can someone provide me links to Windows API Thread tutorials.

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • ppuniversal
    New Member
    • Feb 2007
    • 52

    Can someone provide me links to Windows API Thread tutorials.

    Can someone provide me links to some Windows API Thread tutorials.
    Or links to some books for the same.

    Pawan
  • horace1
    Recognized Expert Top Contributor
    • Nov 2006
    • 1510

    #2
    Originally posted by ppuniversal
    Can someone provide me links to some Windows API Thread tutorials.
    Or links to some books for the same.

    Pawan
    have a look at
    Latest news coverage, email, free stock quotes, live scores and video are just the beginning. Discover more every day at Yahoo!



    try this simple program
    Code:
    #include <iostream>
    #include <process.h>
    
    using namespace std;
    
    void myFunction( void* number){
         
         int myNumber = *(int*)number;
    
         cout << "This is prcosses number: " << myNumber << "\n";
              
         _endthread();
    
    }
    
    int main(int argc, char *argv[])
    {
        int tempNum[10];
    
        for( int i = 0; i <= 9; i++){
             tempNum[i] = i;
             _beginthread( myFunction, 0, (void*)&tempNum[i]);
        }
        
        system("PAUSE");
        return 0;
    }

    Comment

    • sicarie
      Recognized Expert Specialist
      • Nov 2006
      • 4677

      #3
      Originally posted by ppuniversal
      Can someone provide me links to some Windows API Thread tutorials.
      Or links to some books for the same.

      Pawan
      I think a Google search of 'c++ win32 api' returned some items you would find useful.

      Comment

      • ppuniversal
        New Member
        • Feb 2007
        • 52

        #4
        The Samuels page did have Threading tutorial but I think its not that interesting that I want. Please help.

        I dont want to make any GUI based application, its just that I want to meet certain Synchronization s in my application. So I wanted a tutorial which can provide me with such details in a good manner.

        Pawan

        Comment

        • horace1
          Recognized Expert Top Contributor
          • Nov 2006
          • 1510

          #5
          Originally posted by ppuniversal
          The Samuels page did have Threading tutorial but I think its not that interesting that I want. Please help.

          I dont want to make any GUI based application, its just that I want to meet certain Synchronization s in my application. So I wanted a tutorial which can provide me with such details in a good manner.

          Pawan
          have a look at these tutorials on synchronization
          http://www.codeguru.co m/cpp/w-d/dislog/win32/article.php/c9823/
          http://www.codeproject .com/threads/Synchronization .asp

          Comment

          • ppuniversal
            New Member
            • Feb 2007
            • 52

            #6
            Thanks, I think this link :

            http://www.codeguru.co m/cpp/w-d/dislog/win32/article.php/c9823/

            will provide me with sufficient details on Thread Synchronization .

            Pawan

            Comment

            Working...