File Path

P

Pam

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
 
T

Tony Jollans

Do I reference the label name?

The Label name would be a good place to start. And I would use the .Caption
property.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top