Vb.net Process.GetCurrentProcess

Get help with just about anything and everything NOT Warcraft related. Computers, consoles, phones, whatever!
Post Reply
owner123
Super Moderator
Posts: 2394
Joined: February 3rd, 2009, 11:28 pm

Vb.net Process.GetCurrentProcess

Post by owner123 »

So I'm trying to make a boss key in VB
(See this useful-tools-f69/a-boss-tool-t944.html)
I have everything working, I know how to hide it and I know how to make the hotkey.
The problem is getting the application I want to hide. I used this.

Code: Select all

Dim p as Process.GetCurrentProcess()

thinking that it would give me the process that is currently maximized.
But instead of that, it always returns the application that is running (My application)

I already did a google search with no results, so I'm asking any vb users here, how do you find the process that is currently maximized.
User avatar
haxorico
Super Moderator
Posts: 3816
Joined: February 24th, 2009, 1:31 pm
Location: JEW LAND
Contact:

Re: Vb.net Process.GetCurrentProcess

Post by haxorico »

From my expirience, GetCurrentProcess() is used when injecting a code into a working process. Usually used for hacks or stuff like that.
So if your turn your .exe to a .dll and inject it. It should work (based on the theory that your code is correct)
Image
Spoiler:
(02:24:09)

Code: Select all

ChatBot: FatherSpace logs into the Chat.
(02:24:28) Lanaya: Gtfo ken.
(02:24:33) ChatBot: FatherSpace logs out of the Chat.
(02:24:40) Lanaya: Thought so. bitch.
(02:24:44) ChatBot: FatherSpace logs into the Chat.
(02:24:48) FatherSpace: Can I come back yet?
(02:24:51) Lanaya: What'd i say earlier.
(02:24:51) Lanaya: No.
(02:24:58) FatherSpace: Let's try this...
(02:25:01) ChatBot: Lanaya has been logged out (Kicked).

Code: Select all


(14:33:51) 2Pac: Do you know what'S so funny?
(14:34:01) Lanaya: No, please show me.
(14:34:07) 2Pac: This.
(14:34:09) ChatBot: Lanaya has been logged out (Kicked).
(14:34:10) 2Pac:


Code: Select all

(14:35:59) haxorico: No one will belive me if I say "I got this song from 2pac on MSN" lolz ^^
(14:36:02) Lanaya: lolz.
(14:36:16) 2Pac: I AIN'T DEAD FFS.
(14:36:26) 2Pac: I'm a living legend, y'now.
(14:37:17) haxorico: why is 2Pac a legend?
(14:37:28) Lanaya: He's the worse rapper evar.

Code: Select all

(15:42:51) Lanaya: can i suck , . . .

Code: Select all

(13:55:21) ChatBot: 2Pac rolls 1d100 and gets 1.
(13:55:21) ChatBot: haxorico rolls 1d2 and gets 2.
(13:55:27) haxorico: owned?

Code: Select all

GeorgeMots: xplain what happens in SP. Why cant you save?
dast.-:i need play with 2 players

Code: Select all

(21:53:08) (673237): plzplzplz, im sorry about before.
(21:53:26) FatherSpace: I'm sorry you were born.
(21:53:31) ChatBot: (673237) has been logged out (Kicked).


Code: Select all

(10:08:02) Bartimaeus: you do know run I youtube channel for my favorite music, right?
owner123
Super Moderator
Posts: 2394
Joined: February 3rd, 2009, 11:28 pm

Re: Vb.net Process.GetCurrentProcess

Post by owner123 »

I don't know DLL injection, and neither did my Visual Basic teacher :( (he doesn't know any advanced stuff =\).

I just made a work-around, so I'm closing this.
User avatar
haxorico
Super Moderator
Posts: 3816
Joined: February 24th, 2009, 1:31 pm
Location: JEW LAND
Contact:

Re: Vb.net Process.GetCurrentProcess

Post by haxorico »

Even though its closed, i feel the need to share my knoledge.
In Visual Studio you can make instead of a win32 application, a dll application (or is it instead of a form inside the win32 app?).
You get all your code in there, and after compiling, youll get a .dll file. Which you can inject into any process using an injector like winject.
Image
Spoiler:
(02:24:09)

Code: Select all

ChatBot: FatherSpace logs into the Chat.
(02:24:28) Lanaya: Gtfo ken.
(02:24:33) ChatBot: FatherSpace logs out of the Chat.
(02:24:40) Lanaya: Thought so. bitch.
(02:24:44) ChatBot: FatherSpace logs into the Chat.
(02:24:48) FatherSpace: Can I come back yet?
(02:24:51) Lanaya: What'd i say earlier.
(02:24:51) Lanaya: No.
(02:24:58) FatherSpace: Let's try this...
(02:25:01) ChatBot: Lanaya has been logged out (Kicked).

Code: Select all


(14:33:51) 2Pac: Do you know what'S so funny?
(14:34:01) Lanaya: No, please show me.
(14:34:07) 2Pac: This.
(14:34:09) ChatBot: Lanaya has been logged out (Kicked).
(14:34:10) 2Pac:


Code: Select all

(14:35:59) haxorico: No one will belive me if I say "I got this song from 2pac on MSN" lolz ^^
(14:36:02) Lanaya: lolz.
(14:36:16) 2Pac: I AIN'T DEAD FFS.
(14:36:26) 2Pac: I'm a living legend, y'now.
(14:37:17) haxorico: why is 2Pac a legend?
(14:37:28) Lanaya: He's the worse rapper evar.

Code: Select all

(15:42:51) Lanaya: can i suck , . . .

Code: Select all

(13:55:21) ChatBot: 2Pac rolls 1d100 and gets 1.
(13:55:21) ChatBot: haxorico rolls 1d2 and gets 2.
(13:55:27) haxorico: owned?

Code: Select all

GeorgeMots: xplain what happens in SP. Why cant you save?
dast.-:i need play with 2 players

Code: Select all

(21:53:08) (673237): plzplzplz, im sorry about before.
(21:53:26) FatherSpace: I'm sorry you were born.
(21:53:31) ChatBot: (673237) has been logged out (Kicked).


Code: Select all

(10:08:02) Bartimaeus: you do know run I youtube channel for my favorite music, right?
Post Reply