The code below show the file path in a message box, how do I change it
to show the file path in a label on a user form?
Do I reference the label name?
I am using a command button to run it in Word 2003 XP.
Thanks
Pam
Dim fd As FileDialog
Set fd = Application.FileDialog (msoFileDialogFilePicker)
Fd.InitialFileName = \\ushou1fp003\wordp\Contracts\
Dim vrtSelectedItem As Variant
With fd
If .Show = -1 Then
For Each vrtSelectedItem In .SelectedItems
MsgBox "The path is: " & vrtSelectedItem
Next vrtSelectedItem
Else
End If
End With
End Sub
Tony Jollans - 18 Apr 2006 12:58 GMT
> Do I reference the label name?
The Label name would be a good place to start. And I would use the .Caption
property.
--
Enjoy,
Tony
> The code below show the file path in a message box, how do I change it
> to show the file path in a label on a user form?
[quoted text clipped - 20 lines]
> End With
> End Sub