Cheat Engine Forum Index Cheat Engine
The Official Site of Cheat Engine
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 


[C++] Managed and native data types (cont.)

 
Post new topic   Reply to topic    Cheat Engine Forum Index -> General programming
View previous topic :: View next topic  
Author Message
nwongfeiying
Grandmaster Cheater
Reputation: 2

Joined: 25 Jun 2007
Posts: 695

PostPosted: Thu Jan 01, 2009 11:43 pm    Post subject: [C++] Managed and native data types (cont.) Reply with quote

I've been trying lurc's and slovach's and everyone's methods to get around the epidemic of managed and data types, but I was wondering if I could do this using a dynamic link library.

The project I'm working on is my alarm clock. I have to start my process in order to close it. Now I want to improve the program by closing a window that the user specified.

The program is mainly .NET except for the closing the window part. How do I read the text from the textbox and use it to specify for the argument in the FindWindow?
Back to top
View user's profile Send private message
HomerSexual
Grandmaster Cheater Supreme
Reputation: 5

Joined: 03 Feb 2007
Posts: 1657

PostPosted: Thu Jan 01, 2009 11:53 pm    Post subject: Re: [C++] Managed and native data types (cont.) Reply with quote

nwongfeiying wrote:
I've been trying lurc's and slovach's and everyone's methods to get around the epidemic of managed and data types, but I was wondering if I could do this using a dynamic link library.

The project I'm working on is my alarm clock. I have to start my process in order to close it. Now I want to improve the program by closing a window that the user specified.

The program is mainly .NET except for the closing the window part. How do I read the text from the textbox and use it to specify for the argument in the FindWindow?


GetDlgItemText? I dont really get the question. Are you using .net to read the textbox or win32. if win32 use GetDlgItemText

_________________
Back to top
View user's profile Send private message
nwongfeiying
Grandmaster Cheater
Reputation: 2

Joined: 25 Jun 2007
Posts: 695

PostPosted: Fri Jan 02, 2009 12:03 am    Post subject: Reply with quote

.NET to read the textbox then using the data received from the textbox to use it for the Win32 FindWindow.
Back to top
View user's profile Send private message
sloppy
Expert Cheater
Reputation: 0

Joined: 17 Aug 2008
Posts: 123

PostPosted: Fri Jan 02, 2009 12:41 am    Post subject: Reply with quote

How to convert from System::String* to Char* in Visual C++
Back to top
View user's profile Send private message
hcavolsdsadgadsg
I'm a spammer
Reputation: 26

Joined: 11 Jun 2007
Posts: 5801

PostPosted: Fri Jan 02, 2009 1:52 am    Post subject: Reply with quote

Look at the marshal class for converting to unmanaged types, and stop using managed C++ for the life of christ, and switch to C#.
Back to top
View user's profile Send private message
nwongfeiying
Grandmaster Cheater
Reputation: 2

Joined: 25 Jun 2007
Posts: 695

PostPosted: Fri Jan 02, 2009 9:43 am    Post subject: Reply with quote

slovach wrote:
Look at the marshal class for converting to unmanaged types, and stop using managed C++ for the life of christ, and switch to C#.


Hey! Managed C++ has feelings too.
Back to top
View user's profile Send private message
HomerSexual
Grandmaster Cheater Supreme
Reputation: 5

Joined: 03 Feb 2007
Posts: 1657

PostPosted: Fri Jan 02, 2009 9:52 am    Post subject: Reply with quote

nwongfeiying wrote:
slovach wrote:
Look at the marshal class for converting to unmanaged types, and stop using managed C++ for the life of christ, and switch to C#.


Hey! Managed C++ has feelings too.


Why not use all win32 then? I dont get why you keep switching back and forth. Make a 100% managed or native function. You could import FindWindow from it's .dll and change the params to managed type?

_________________
Back to top
View user's profile Send private message
nwongfeiying
Grandmaster Cheater
Reputation: 2

Joined: 25 Jun 2007
Posts: 695

PostPosted: Fri Jan 02, 2009 10:18 am    Post subject: Reply with quote

I use managed coding simply for the easier to design GUI. Designing GUI in Win32 confuses me and it never looks as good.
Back to top
View user's profile Send private message
HomerSexual
Grandmaster Cheater Supreme
Reputation: 5

Joined: 03 Feb 2007
Posts: 1657

PostPosted: Fri Jan 02, 2009 10:23 am    Post subject: Reply with quote

nwongfeiying wrote:
I use managed coding simply for the easier to design GUI. Designing GUI in Win32 confuses me and it never looks as good.


You can use ResEdit to create a RC file or direct CreateWindow code.

They look exactly as they do in VC++

http://www.resedit.net/ResEdit-ANSI.zip ANSI Build
http://www.resedit.net/ResEdit-UNICODE.zip UNICODE Build

_________________
Back to top
View user's profile Send private message
nwongfeiying
Grandmaster Cheater
Reputation: 2

Joined: 25 Jun 2007
Posts: 695

PostPosted: Fri Jan 02, 2009 2:13 pm    Post subject: Reply with quote

I'll be the judge of that.
Back to top
View user's profile Send private message
hcavolsdsadgadsg
I'm a spammer
Reputation: 26

Joined: 11 Jun 2007
Posts: 5801

PostPosted: Fri Jan 02, 2009 2:43 pm    Post subject: Reply with quote

nwongfeiying wrote:
I use managed coding simply for the easier to design GUI. Designing GUI in Win32 confuses me and it never looks as good.


So why are you not using C#? It's superior in every way.

Managed C++ has no support anymore.
Back to top
View user's profile Send private message
nwongfeiying
Grandmaster Cheater
Reputation: 2

Joined: 25 Jun 2007
Posts: 695

PostPosted: Sat Jan 03, 2009 10:49 am    Post subject: Reply with quote

slovach wrote:
nwongfeiying wrote:
I use managed coding simply for the easier to design GUI. Designing GUI in Win32 confuses me and it never looks as good.


So why are you not using C#? It's superior in every way.

Managed C++ has no support anymore.


Fine..you convinced me. I'm going to be using C# for .NET programming from now on Smile
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    Cheat Engine Forum Index -> General programming All times are GMT - 6 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Powered by phpBB © 2001, 2005 phpBB Group

CE Wiki   IRC (#CEF)   Twitter
Third party websites