|
-
Dec 17th, 2003, 03:09 PM
#1
Thread Starter
Addicted Member
Right() [RESOLVED]
I'm getting an error with this code that states the Right command is looking for an integer. What am I doing wrong?
Code:
Dim strPath As String = Application.StartupPath
If Right(strPath, 1) <> "\" Then
strPath = strPath & "\"
End If
Last edited by GSIV; Dec 17th, 2003 at 03:25 PM.
-
Dec 17th, 2003, 03:19 PM
#2
Right() is a vb6 function , try this ... ( which works fine )
VB Code:
Dim strPath As String = Application.StartupPath
If Not strPath.EndsWith("\") Then
strPath += "\"
MessageBox.Show(strPath)
End If
~
if a post is resolved, please mark it as [Resolved]
protected string get_Signature(){return Censored;}
[vbcode][php] please use code tags when posting any code [/php][/vbcode]
-
Dec 17th, 2003, 03:24 PM
#3
Thread Starter
Addicted Member
Cool... thanks!
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|