Quote:
Originally Posted by monty747
How do I programatically make changes to the width/height of a UIImageView? This would be a single instance of the view but would have different sizes depending on which button the user selects on-screen. I can get it to display the first time with the place and size I want but then it needs to change size and I'm not finding a way to access width/height numbers without doing a CGRectMake again. I already initialized it so doing it a second time would create a second view in addition to the first. I guess I'm looking for a:
myImageView.w = 10;
myImageView.h = 20;
type deal. Any thoughts?
|
You need to set a complete frame of the imageView.
For the above values it will be done as
Code:
[myImageView setFrame:CGRectMake(myImageView.frame.origin.x,
myImageView.frame.origin.y,10,20)];
Hope this helps...
Regards,
Akshay Shah.
__________________
If you think I did help you, you can always thank me by buying
iHoldMore - A very nice and addictive game...
Need a mobile app. Contact Us.
Ruby Solutions Pvt. Ltd.
You can mail me at
akshay@ruby-solutions.com