ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Combboxes and Testboxes (https://www.excelbanter.com/excel-programming/291723-combboxes-testboxes.html)

James[_19_]

Combboxes and Testboxes
 
I have a form with 2 ComboBoxes which add together to form
both parts of a file URL.

eg. CB1 CB2
My Documents Spreadsheet1
Spreadsheet2


When the desired parts are highlighted a CommandButton is
pressed leading to another form. This second form has a
textbox and I would like it to state the file's address.

eg My documents\Spreadsheet1

Another CommandButton is pressed which then activates the
desired file.

Is this possible? Can anyone help me?

Thanks in Advance

James

Tom Ogilvy

Combboxes and Testboxes
 
Public Sub CommandButton3_Click
sStr = CB1.Value & CB2.Value
userform2.Textbox1 = sStr
Me.hide
userform2.Show
Unload me
End Sub

in Userform2

Public Sub CommandButton1_Click
Workbooks.Open Textbox1.Text
Unload me
End Sub


--
Regards,
Tom Ogilvy


"James" wrote in message
...
I have a form with 2 ComboBoxes which add together to form
both parts of a file URL.

eg. CB1 CB2
My Documents Spreadsheet1
Spreadsheet2


When the desired parts are highlighted a CommandButton is
pressed leading to another form. This second form has a
textbox and I would like it to state the file's address.

eg My documents\Spreadsheet1

Another CommandButton is pressed which then activates the
desired file.

Is this possible? Can anyone help me?

Thanks in Advance

James





All times are GMT +1. The time now is 02:52 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com