| | |
Macro in MSExcel
![]() |
•
•
Join Date: Mar 2007
Posts: 59
Reputation:
Solved Threads: 5
you can make a userform that fullfils your needs.
use:
to show the form
put u commandbutton on the form to close the form
put the following code in the commandbutton click event:
The textbox properties are still readable after this.
Now you can read the values from the forms textboxes:
etc.
after that you can unload the form:
The textbox properties are lost after this.
use:
Visual Basic 4 / 5 / 6 Syntax (Toggle Plain Text)
UserForm1.Show vbModal
put u commandbutton on the form to close the form
put the following code in the commandbutton click event:
Visual Basic 4 / 5 / 6 Syntax (Toggle Plain Text)
Sub Command1.Click UserForm1.Hide End Sub
Now you can read the values from the forms textboxes:
Visual Basic 4 / 5 / 6 Syntax (Toggle Plain Text)
Dim sAnswer as String sAnswer = Userform1.Textbox1.Text
after that you can unload the form:
Visual Basic 4 / 5 / 6 Syntax (Toggle Plain Text)
Unload UserForm1
![]() |
Similar Threads
- Macro Media Flashplayer 7 popups (Windows NT / 2000 / XP)
- Macro Problems (Windows Software)
- Need Help Reading a csv file created from MSExcel (C)
- Excel Macro using vba :( (Visual Basic 4 / 5 / 6)
- Trying to run Showcase thru a Macro built in VB (Visual Basic 4 / 5 / 6)
- Need help with including C++ code in Word macro (C++)
Other Threads in the Visual Basic 4 / 5 / 6 Forum
- Previous Thread: sendmessage to a password box?
- Next Thread: Image.picture - need some help
| Thread Tools | Search this Thread |
* 6 429 2007 access activex add age application basic beginner birth bmp calculator cd cells.find click client code college component connection connectionproblemusingvb6usingoledb copy creat ctrl+f data database datareport date delete dissertations dissertationthesis dissertationtopic edit error excel excelmacro file filename form hardware header iamthwee image inboxinvb internetfiledownload keypress label listbox listview liveperson login looping machine microsoft movingranges number objectinsert open oracle password prime program prompt range-objects readfile reading record refresh remotesqlserverdatabase report save search sendbyte sites sort sql sql2008 sqlserver subroutine tags textbox time urldownloadtofile vb vb6 vb6.0 vba visual visualbasic visualbasic6 web window windows





