Home |
Search |
Today's Posts |
#1
|
|||
|
|||
Load User form
Hi everyone
I have already designed user form there is a text box and Button ok and button cancel Already assign the text box to cellA1 Now I load it enter the value in the text box and already see in cell A1 but when I click the ok button the form remain on the screen and when i cancel it it disappear now i load it again the value still in the text box What I want is(A) I click to open the user form (B) I insert the value (C) I click ok the value transfer to cellA1 and the userform close and when i reopen it the text box is empty Thnxs for help Bakar |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Load User form
Hi Bakar,
Am Fri, 19 Oct 2012 10:30:38 +0000 schrieb Bakar: What I want is(A) I click to open the user form (B) I insert the value (C) I click ok the value transfer to cellA1 and the userform close and when i reopen it the text box is empty you can show the userform by double clicking in your sheet. Put foolwoing code in the code module of your sheet: Private Sub Worksheet_BeforeDoubleClick(ByVal Target As Range, _ Cancel As Boolean) UserForm1.Show Cancel = True End Sub and for your OK button, use: Private Sub cmdOK_Click() [A1] = TextBox1.Text Unload UserForm1 End Sub Regards Claus Busch -- Win XP PRof SP2 / Vista Ultimate SP2 Office 2003 SP2 /2007 Ultimate SP2 |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
User Form - how to load it | Excel Discussion (Misc queries) | |||
Load user form?? | Excel Programming | |||
How can I load a user form from within a worksheet subroutine? | Excel Programming | |||
how to load chart in user form | Excel Programming | |||
Userform doesn't recognize other user form upon re-load | Excel Programming |