Private
Sub
CommandButton1_Click()
Dim
strTitle
As
String
Dim
strHyperAlt
As
String
Dim
strHyperNeu
As
String
strTitel = UserForm1.TextBox1.Value
Range(
"A1"
).Activate
ActiveCell.Value = strTitel
MsgBox (strTitel)
strHyperAlt = strTitel
MsgBox
"strHyperAlt is now "
& strHyperAlt
strHyperNeu = Replace(strHyperAlt,
" "
,
"%20"
)
MsgBox
"strHyperNeu is now "
& strHyperNeu
ActiveSheet.Hyperlinks.Add Anchor:=ActiveCell, Address:=
"\\"
& strHyperNeu &
".pdf"
, ScreenTip:= _
"open pdf"
, TextToDisplay:=strHyperNeu
UserForm1.Hide
End
Sub