Reputation: 5
I am trying to use 2 textboxes in a form to Rename Files, but keep getting "Expression Expected". The first & & is the name of a server and the second & & is the original name of the file. The reason I need them to be textboxes is because those names constantly change.
My.Computer.FileSystem.RenameFile("D:\File1\" & S2Prim.Text & "_Working\Backup\" & PSG.Text &, "group.txt")
Upvotes: 0
Views: 139
Reputation: 380
You have an extra &
character at the end of the first parameter:
"D:\File1\" & S2Prim.Text & "_Working\Backup\" & PSG.Text &
Upvotes: 2