How to tell the users with message box that the path location having a space?
rlyr.file = Dir1.Path & "\" & File1.List(File1.ListIndex)
Printable View
How to tell the users with message box that the path location having a space?
rlyr.file = Dir1.Path & "\" & File1.List(File1.ListIndex)
:confused: What?
I don't understand the question.
I have path location like this
This path location having an empty space between text. How to pop up a message box to tell user that, "no empty space is allowed in the path location, please rename the folder."Code:C:\Database\BOUNDARIES\TKSSBlock C
Code:If InStr(1, Dir1.Path, " ") > 0 Then
MsgBox "no empty space is allowed in the path location, please rename the folder.", vbExclamation, "Error"
End If
Ah, gotcha.
Does your program allow them to make the folder in the first place or is this a folder they make themselves, and then in your program, select?
Yes, the make the folder and I select the folder. I use this code to select the folder Dir1.Path & "\" & File1.List(File1.ListIndex)Quote:
Originally Posted by Hack
Then before you make the folder check for a space. If there is one, don't make it.
Thank you, I already solve this problem
What did you do?Quote:
Originally Posted by matrik02
Used reinholdmesne code, Actually I am not create the folder, the folder was create manually, I just select the folder from VB.Quote:
Originally Posted by Hack
Code:If InStr(1, Dir1.Path, " ") > 0 Then
MsgBox "no empty space is allowed in the path location, please rename the folder.", vbExclamation, "Error"
End If