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 


[VB6] Any way to add custom made buttons?
Goto page 1, 2  Next
 
Post new topic   Reply to topic    Cheat Engine Forum Index -> General programming
View previous topic :: View next topic  
Author Message
I'm C.H.
Grandmaster Cheater Supreme
Reputation: 0

Joined: 02 Dec 2006
Posts: 1000
Location: Sweden

PostPosted: Tue Jan 29, 2008 10:45 am    Post subject: [VB6] Any way to add custom made buttons? Reply with quote

Well I have a button in a .png format and is there any way to add it to my forms?
_________________
Omg. I need something to do...

*-* My Flash Trainers *-*

*-* My Mouse Vac Tut *-*

Back to top
View user's profile Send private message
atom0s
Moderator
Reputation: 205

Joined: 25 Jan 2006
Posts: 8587
Location: 127.0.0.1

PostPosted: Tue Jan 29, 2008 10:54 am    Post subject: Reply with quote

Create your own controls. Or, you can use a PictureBox and handle it as a button with the mouse down event.
_________________
- Retired.
Back to top
View user's profile Send private message Visit poster's website
I'm C.H.
Grandmaster Cheater Supreme
Reputation: 0

Joined: 02 Dec 2006
Posts: 1000
Location: Sweden

PostPosted: Tue Jan 29, 2008 10:59 am    Post subject: Reply with quote

Well .png files is invalid according to vb6.
_________________
Omg. I need something to do...

*-* My Flash Trainers *-*

*-* My Mouse Vac Tut *-*

Back to top
View user's profile Send private message
atom0s
Moderator
Reputation: 205

Joined: 25 Jan 2006
Posts: 8587
Location: 127.0.0.1

PostPosted: Tue Jan 29, 2008 11:03 am    Post subject: Reply with quote

CheatingHacker wrote:
Well .png files is invalid according to vb6.


Then convert the picture to another format. You can open it in Paint and resave it as something else such as gif, bmp, or jpg.

_________________
- Retired.
Back to top
View user's profile Send private message Visit poster's website
I'm C.H.
Grandmaster Cheater Supreme
Reputation: 0

Joined: 02 Dec 2006
Posts: 1000
Location: Sweden

PostPosted: Tue Jan 29, 2008 11:05 am    Post subject: Reply with quote

Yeah I know but it's a button that when mouse is over it, the button will shine.
_________________
Omg. I need something to do...

*-* My Flash Trainers *-*

*-* My Mouse Vac Tut *-*

Back to top
View user's profile Send private message
Symbol
I'm a spammer
Reputation: 0

Joined: 18 Apr 2007
Posts: 5094
Location: Israel.

PostPosted: Tue Jan 29, 2008 11:35 am    Post subject: Reply with quote

Make it change the picture/pixels colors onmouseover, onmousedown, etc... or you can make a flat button with that image streched.
Back to top
View user's profile Send private message
I'm C.H.
Grandmaster Cheater Supreme
Reputation: 0

Joined: 02 Dec 2006
Posts: 1000
Location: Sweden

PostPosted: Tue Jan 29, 2008 11:43 am    Post subject: Reply with quote

I didn't get much of that. What's the code for onmouseover and onmousedown? I need some help with that. Btw, I have an Idea that might work.

[Mouseover Code]
Command1.Picture [The rest of the code that I dunno]
[End code if needed]

_________________
Omg. I need something to do...

*-* My Flash Trainers *-*

*-* My Mouse Vac Tut *-*

Back to top
View user's profile Send private message
pimpstonie
Advanced Cheater
Reputation: 0

Joined: 27 Sep 2007
Posts: 70

PostPosted: Tue Jan 29, 2008 11:46 am    Post subject: FU! Reply with quote

FU!

Last edited by pimpstonie on Wed Jan 30, 2008 8:26 am; edited 1 time in total
Back to top
View user's profile Send private message
I'm C.H.
Grandmaster Cheater Supreme
Reputation: 0

Joined: 02 Dec 2006
Posts: 1000
Location: Sweden

PostPosted: Tue Jan 29, 2008 12:03 pm    Post subject: Reply with quote

Thanks but is there any way to add your own pictures cause I keep getting Invalid Picture -.-
_________________
Omg. I need something to do...

*-* My Flash Trainers *-*

*-* My Mouse Vac Tut *-*

Back to top
View user's profile Send private message
pimpstonie
Advanced Cheater
Reputation: 0

Joined: 27 Sep 2007
Posts: 70

PostPosted: Tue Jan 29, 2008 12:18 pm    Post subject: FU! Reply with quote

FU!

Last edited by pimpstonie on Wed Jan 30, 2008 8:26 am; edited 1 time in total
Back to top
View user's profile Send private message
I'm C.H.
Grandmaster Cheater Supreme
Reputation: 0

Joined: 02 Dec 2006
Posts: 1000
Location: Sweden

PostPosted: Tue Jan 29, 2008 12:29 pm    Post subject: Reply with quote

I have got:

CQ.bmp but it says it's invalid.

_________________
Omg. I need something to do...

*-* My Flash Trainers *-*

*-* My Mouse Vac Tut *-*

Back to top
View user's profile Send private message
pimpstonie
Advanced Cheater
Reputation: 0

Joined: 27 Sep 2007
Posts: 70

PostPosted: Tue Jan 29, 2008 12:33 pm    Post subject: FU! Reply with quote

FU!

Last edited by pimpstonie on Wed Jan 30, 2008 8:25 am; edited 1 time in total
Back to top
View user's profile Send private message
I'm C.H.
Grandmaster Cheater Supreme
Reputation: 0

Joined: 02 Dec 2006
Posts: 1000
Location: Sweden

PostPosted: Tue Jan 29, 2008 1:33 pm    Post subject: Reply with quote

Yea here: http://rapidshare.com/files/87620927/Pics.rar.html
_________________
Omg. I need something to do...

*-* My Flash Trainers *-*

*-* My Mouse Vac Tut *-*

Back to top
View user's profile Send private message
Blader
I post too much
Reputation: 2

Joined: 19 Jan 2007
Posts: 2049

PostPosted: Tue Jan 29, 2008 2:34 pm    Post subject: Reply with quote

Picture1.Picture = LoadPicture(App.Path & "\CQ.bmp")
Try that if you haven't already, although it should be able to work with just setting it in the properties.

EDIT: I just tried it and it didn't work. Try making it again and save it as a .bmp.
Btw, you can't just change .png to .bmp, that wouldn't work if you were doing that.

_________________
Back to top
View user's profile Send private message
XxOsirisxX
Grandmaster Cheater Supreme
Reputation: 0

Joined: 30 Oct 2006
Posts: 1597

PostPosted: Tue Jan 29, 2008 11:51 pm    Post subject: Reply with quote

Confused

Just...

open VB, add a Image control. at the right side (propieties, default location) look at
Quote:
Picture (None) [...]
press
Quote:
[...]
And it will browser a picture with the extentions: .bmp, .dib, .gif, .jpg, .wmf, .emf, .ico and .cur.

After you select you picture (After changing that .PNG to any other in list [recomended .bmp]) them, double click the picture, and you will be at code "section" of the image you did double clicked.

Code:
Private Sub Image1_Click()

End Sub


At this point, you may noticed that event is
Code:
"Click"
, so, we wants to change the picture when the mouse is over. So, at the top right of the code "section" and being at image sub, then we just change the event
Code:
"Click"
to
Code:
MouseMove
.

So, we will see this.

Code:
Private Sub Image1_MouseMove(Button As Integer, Shift As Integer, X As Single, Y As Single)

End Sub


So, now that we got our wished event, lest make the functions. So, we put "Image1.Visible = false" "Image2.Visible = True" (Image2 must be created at the moment of executing the programming, and for you target, it must be the effect that does the .PNG when is MouseOver).

So we got this.

Code:
Private Sub Image1_MouseMove(Button As Integer, Shift As Integer, X As Single, Y As Single)
Image1.Visible = False
Image2.Visible = True
End Sub


So, when the mouse is over the image1, the image2 will show up. This must be applied to the background/form to make it better and no "glitches".

Of course there are better ways to do this, but this is just t show you the BASIC way, since i been read that you don't get it.

_________________

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
Goto page 1, 2  Next
Page 1 of 2

 
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