Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
shape object on a userform?
I want to create a UserForm1. On the UserFrom I want to create a Trapazoid
shape object and three text boxes. The text boxes would define the trapazoid height and both lengths. When the user inputs a new number in the text box the trapazoid shape would change size. Is this possible? If I could get the shape drawn on the UserForm I believe I could code the rest. TIA. Alan |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
shape object on a userform?
It is not trivial to draw on a UserForm. It may be possible to do with some
complicated API programming, but there is no direct way to do it. -- Vasant "Alan Ibbotson" wrote in message ... I want to create a UserForm1. On the UserFrom I want to create a Trapazoid shape object and three text boxes. The text boxes would define the trapazoid height and both lengths. When the user inputs a new number in the text box the trapazoid shape would change size. Is this possible? If I could get the shape drawn on the UserForm I believe I could code the rest. TIA. Alan |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
shape object on a userform?
As Vasant says, you can't draw, but you might get away with using a control,
lile a label Private Sub CommandButton1_Click() Label1.Width = TextBox1 Label1.Height = TextBox2 End Sub Private Sub UserForm_Initialize() TextBox1.Text = Label1.Width TextBox2.Text = Label1.Height End Sub "Alan Ibbotson" wrote: I want to create a UserForm1. On the UserFrom I want to create a Trapazoid shape object and three text boxes. The text boxes would define the trapazoid height and both lengths. When the user inputs a new number in the text box the trapazoid shape would change size. Is this possible? If I could get the shape drawn on the UserForm I believe I could code the rest. TIA. Alan |
#4
Posted to microsoft.public.excel.programming
|
|||
|
|||
shape object on a userform?
Hi Patrick:
If I understood the OP correctly, a trapezoid has angled lines, so I don't think a Label control would work. Regards, Vasant "Patrick Molloy" wrote in message ... As Vasant says, you can't draw, but you might get away with using a control, lile a label Private Sub CommandButton1_Click() Label1.Width = TextBox1 Label1.Height = TextBox2 End Sub Private Sub UserForm_Initialize() TextBox1.Text = Label1.Width TextBox2.Text = Label1.Height End Sub "Alan Ibbotson" wrote: I want to create a UserForm1. On the UserFrom I want to create a Trapazoid shape object and three text boxes. The text boxes would define the trapazoid height and both lengths. When the user inputs a new number in the text box the trapazoid shape would change size. Is this possible? If I could get the shape drawn on the UserForm I believe I could code the rest. TIA. Alan |
#5
Posted to microsoft.public.excel.programming
|
|||
|
|||
shape object on a userform?
Hi,
As the other guys have said it's not straightforward. But you may find you can make use of the techniques I use in my example. http://www.andypope.info/vba/userformdraw.htm Cheers Andy Alan Ibbotson wrote: I want to create a UserForm1. On the UserFrom I want to create a Trapazoid shape object and three text boxes. The text boxes would define the trapazoid height and both lengths. When the user inputs a new number in the text box the trapazoid shape would change size. Is this possible? If I could get the shape drawn on the UserForm I believe I could code the rest. TIA. Alan -- Andy Pope, Microsoft MVP - Excel http://www.andypope.info |
#6
Posted to microsoft.public.excel.programming
|
|||
|
|||
shape object on a userform?
That's awesome stuff, Andy!
Regards, Vasant "Andy Pope" wrote in message ... Hi, As the other guys have said it's not straightforward. But you may find you can make use of the techniques I use in my example. http://www.andypope.info/vba/userformdraw.htm Cheers Andy Alan Ibbotson wrote: I want to create a UserForm1. On the UserFrom I want to create a Trapazoid shape object and three text boxes. The text boxes would define the trapazoid height and both lengths. When the user inputs a new number in the text box the trapazoid shape would change size. Is this possible? If I could get the shape drawn on the UserForm I believe I could code the rest. TIA. Alan -- Andy Pope, Microsoft MVP - Excel http://www.andypope.info |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
macro associated with shape object, useful approach if can be solv | Excel Programming | |||
How to tell wich object/shape was clicked | Excel Programming | |||
XL2000: Shape object events | Excel Programming | |||
Hyperlink within the TextFrame of Shape Object..? | Excel Programming | |||
How to hide Excel window when activating a Shape object | Excel Programming |