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 


VB.NET adding new properties to objects

 
Post new topic   Reply to topic    Cheat Engine Forum Index -> General programming
View previous topic :: View next topic  
Author Message
Jorg hi
I post too much
Reputation: 7

Joined: 24 Dec 2007
Posts: 2276
Location: Minnesota

PostPosted: Tue Mar 31, 2009 5:53 pm    Post subject: VB.NET adding new properties to objects Reply with quote

I'm using the control button but I want to add a property in that control to store data for example 'button1.password="Dark Byte"' , how would I do that?
_________________
CEF will always stay alive.
Back to top
View user's profile Send private message
shhac
Expert Cheater
Reputation: 0

Joined: 30 Oct 2007
Posts: 108

PostPosted: Thu Apr 02, 2009 3:38 pm    Post subject: Reply with quote

Make a new User Control that inherits System.Window.Forms.Button then add the extra things you want to it, then use the new control that you've made rather than the normal Button when designing the form.
I gave it a try but couldn't work out how to make the new control appear in the toolbox. Good Luck!
Back to top
View user's profile Send private message
samuri25404
Grandmaster Cheater
Reputation: 7

Joined: 04 May 2007
Posts: 955
Location: Why do you care?

PostPosted: Thu Apr 02, 2009 4:19 pm    Post subject: Reply with quote

There is a property on controls called "Tag" of object type, so you can assign anything to it, but I don't think that suits your current need. What I would suggest is simply storing a string variable which contains your password.
_________________
Wiccaan wrote:

Oh jeez, watchout I'm a bias person! Locked.


Auto Assembly Tuts:
In Depth Tutorial on AA
Extended
Back to top
View user's profile Send private message
Jorg hi
I post too much
Reputation: 7

Joined: 24 Dec 2007
Posts: 2276
Location: Minnesota

PostPosted: Thu Apr 02, 2009 8:44 pm    Post subject: Reply with quote

samuri25404 wrote:
There is a property on controls called "Tag" of object type, so you can assign anything to it, but I don't think that suits your current need. What I would suggest is simply storing a string variable which contains your password.


Ya but I'm using 10+ buttons that are being created at runtime & it would be hard to keep track of them doing that.

_________________
CEF will always stay alive.
Back to top
View user's profile Send private message
shhac
Expert Cheater
Reputation: 0

Joined: 30 Oct 2007
Posts: 108

PostPosted: Thu Apr 02, 2009 9:18 pm    Post subject: Reply with quote

Jorg hi wrote:
samuri25404 wrote:
There is a property on controls called "Tag" of object type, so you can assign anything to it, but I don't think that suits your current need. What I would suggest is simply storing a string variable which contains your password.


Ya but I'm using 10+ buttons that are being created at runtime & it would be hard to keep track of them doing that.
You could use the tag to store an integer then have a multidimensional array with the tag's value as the index of extra things you want.
Back to top
View user's profile Send private message
Jorg hi
I post too much
Reputation: 7

Joined: 24 Dec 2007
Posts: 2276
Location: Minnesota

PostPosted: Fri Apr 03, 2009 5:44 am    Post subject: Reply with quote

shhac wrote:
Jorg hi wrote:
samuri25404 wrote:
There is a property on controls called "Tag" of object type, so you can assign anything to it, but I don't think that suits your current need. What I would suggest is simply storing a string variable which contains your password.


Ya but I'm using 10+ buttons that are being created at runtime & it would be hard to keep track of them doing that.
You could use the tag to store an integer then have a multidimensional array with the tag's value as the index of extra things you want.


or could I make the tag object like a list collection?

_________________
CEF will always stay alive.
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