[help] Process Handle and multithreading menu

User Tag List

Results 1 to 5 of 5
  1. #1
    Myryador's Avatar Private
    Reputation
    1
    Join Date
    Nov 2011
    Posts
    3
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    [help] Process Handle and multithreading

    [c#]

    Hello guys,

    I tried last days, 6 full days exactly, to solve my problem , no succes.

    On mostly examples here and on the web we can see that :

    [samevoid,except statics]
    Open Process
    Read,Write .....
    Close Handle

    But i need to acces to the process into 3 threads , but when i try, sometime that's say "Process Not opened" .

    That's not the real code , it's just to give a idea of what i mean.
    Code:
        public partial class Test : Form
        {
    
            public IntPtr Process;
    
            private void Test_Load(object sender, EventArgs e)
            {
                     Process[] processes = Process.GetProcessesByName("wow");
                     OpenProcess(DesiredAccess, 0, Process[0])
                     new Thread(new ThreadStart(ThreadTest1));
                     new Thread(new ThreadStart(ThreadTest2));
                     new Thread(new ThreadStart(ThreadTest3));
                     new Thread(new ThreadStart(ThreadTest4));
            }
    
    
            public void ThreadTest1()
            {
                Log("Thread 1" + Convert.ToString(CheckIntPtrProcessOpened(Process)))
            }
            public void ThreadTest2()
            {
                Log("Thread 2" + Convert.ToString(CheckIntPtrProcessOpened(Process)))
            }
            public void ThreadTest3()
            {
                Log("Thread 3" + Convert.ToString(CheckIntPtrProcessOpened(Process)))
            }
            public void ThreadTest4()
            {
                Log("Thread 4" + Convert.ToString(CheckIntPtrProcessOpened(Process)))
            }
    
        }
    First Test Result :
    Code:
    Thread 1True
    Thread 4False
    Thread 2False
    Thread 3False
    Second Test Result :
    Code:
    Thread 3True
    Thread 4true
    Thread 2False
    Thread 1False
    Third Test Result :
    Code:
    Thread 3False
    Thread 4False
    Thread 2False
    Thread 1False

    So, that suck a lot , and i not understand why sometime all is well , sometime not ......
    I really hope someone have an issue, i spent 6days on .........

    Thanks
    Last edited by Myryador; 11-02-2011 at 03:38 PM.

    [help] Process Handle and multithreading
  2. #2
    Frosttall's Avatar Active Member
    Reputation
    64
    Join Date
    Feb 2011
    Posts
    261
    Thanks G/R
    16/3
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Erm how is it possible that Thread 4 gets executed twice? :O

  3. #3
    Myryador's Avatar Private
    Reputation
    1
    Join Date
    Nov 2011
    Posts
    3
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Originally Posted by Frosttall View Post
    Erm how is it possible that Thread 4 gets executed twice? :O
    Bad copy past , edited , thanks .

  4. #4
    !@^^@!'s Avatar Active Member
    Reputation
    23
    Join Date
    Feb 2007
    Posts
    155
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    The question is why on earth you would need to make it multithreaded?
    “Programmers are in a race with the Universe to create bigger and better idiot-proof programs, while the Universe is trying to create bigger and better idiots. So far the Universe is winning.” - Rich Cook

  5. #5
    sitnspinlock's Avatar Elite User CoreCoins Purchaser
    Reputation
    398
    Join Date
    Sep 2010
    Posts
    439
    Thanks G/R
    0/1
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Originally Posted by !@^^@! View Post
    The question is why on earth you would need to make it multithreaded?
    why parallelization of course!

Similar Threads

  1. Need Help - Spell Cooldown and Out of Process Targeting
    By Evansbee in forum WoW Memory Editing
    Replies: 6
    Last Post: 07-11-2015, 04:37 PM
  2. [Request + Help] Adding malls and teleports to there
    By frostyblade in forum World of Warcraft Emulator Servers
    Replies: 4
    Last Post: 12-26-2007, 01:37 PM
  3. Need help GM levels And changing commands will +rep
    By crazyc in forum World of Warcraft Emulator Servers
    Replies: 12
    Last Post: 11-30-2007, 01:11 PM
  4. Need help finding shrubs and bushes
    By blah7 in forum WoW ME Questions and Requests
    Replies: 3
    Last Post: 07-27-2007, 03:41 AM
  5. Few model changes. please help :) , tryed self and failed
    By luddo9 in forum WoW ME Questions and Requests
    Replies: 12
    Last Post: 07-04-2007, 12:32 PM
All times are GMT -5. The time now is 11:58 AM. Powered by vBulletin® Version 4.2.3
Copyright © 2025 vBulletin Solutions, Inc. All rights reserved. User Alert System provided by Advanced User Tagging (Pro) - vBulletin Mods & Addons Copyright © 2025 DragonByte Technologies Ltd.
Google Authenticator verification provided by Two-Factor Authentication (Free) - vBulletin Mods & Addons Copyright © 2025 DragonByte Technologies Ltd.
Digital Point modules: Sphinx-based search