|
-
Jun 28th, 2006, 08:22 PM
#1
Junior Member
Re: Someone Help me in Zooming my Form!!
if i understand what you are trying to do correctly then this should work:
when you press the minimise button the code for the imagebox should be something like this (makes it halfsize)
VB Code:
ImageBox.Height = ImageBox.Height/2
ImageBox.Width = ImageBox.Width/2
and then to maximise it again
VB Code:
ImageBox.Height = ImageBox.Height*2
ImageBox.Width = ImageBox.Width*2
ive never used a circle so im not sure how they work but they would either have a radius, or a X1-X2, Y1-Y2.
If they have a radius control, ie circle.radius then you need to do the same as above:
VB Code:
Circle.Radius = Circle.Radius/2
if it uses the X1-X2, Y1-Y2 method, i would think you need something like this:
VB Code:
Circle.X2 = (Circle.X1 + Circle.X2) / 2
Circle.Y2 = (Circle.Y1 + Circle.Y2) / 2
this will keep the top left corner in the same place and shrink the rest to halfsize
my explanations tend to be longwinded but hopefully you get the idea.
matt
-
Jun 28th, 2006, 11:57 PM
#2
Thread Starter
Registered User
Not this
Thank You Asiladying for your help ;
what i need is not Zooming the Image or the Circle....
But Infact, i do zooming in and out applied on the FORM itself, and so when i make zoom in to it , it will be zoomed with its Components (as circle and imagebox) ........ I hope the help
-
Jun 29th, 2006, 01:31 PM
#3
Addicted Member
Re: Someone Help me in Zooming my Form!!
Hi Captain-alan,
I don't believe you can "zoom the form". You would have to resize and reposition all the controls. There's plenty of messages in this forum about re-sizing controls.
The basics would be like asilaydying said. But instead of using a fixed number I would use a variable. And then just set the number less than one to shrink and greater than one to enlarge.
I.E. width=width*ratio. { ratio=.5 (shrink) ratio=2 (enlarge) }
Keith_VB6
If you have any further questions, just ask.
If this solves things, then please mark the thread resolved.
[Thread Tools] --> [Mark Thread Resolved]
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|