|
-
Jan 15th, 2004, 02:49 AM
#1
Path.Combine... aint working right
I want to combine "C:\windows\" with "..\System" and get "C:\windows\system"
I'm using Path.Combine() and it just returns "C:\windows\..\system" which is wrong. I thought there is a way to combine these kind of paths.
am I doing anything wrong? or is it just the way it is?
rate my posts if they help ya!
Extract thumbnail without reading the whole image file: (C# - VB)
Apply texture to bitmaps: (C# - VB)
Extended console library: (VB)
Save JPEG with a certain quality (image compression): (C# - VB )
VB.NET to C# conversion tips!!
-
Jan 15th, 2004, 03:05 AM
#2
Sleep mode
That's how I did it and worked . Do you have any white space before string paths ?
VB Code:
Dim path1 As String = "c:\windows\"
Dim path2 As String = "system32\"
Dim tmp As String = IO.Path.Combine(path1, path2)
MessageBox.Show(tmp)
-
Jan 15th, 2004, 03:07 AM
#3
well I'm combining it with "..\system32" not with "system32"
windows should be still able to access the path anyways, but I was wondering if I was doing it wonrg I guess it's the way it is, bleh
rate my posts if they help ya!
Extract thumbnail without reading the whole image file: (C# - VB)
Apply texture to bitmaps: (C# - VB)
Extended console library: (VB)
Save JPEG with a certain quality (image compression): (C# - VB )
VB.NET to C# conversion tips!!
-
Jan 15th, 2004, 03:11 AM
#4
Sleep mode
It sounds you're trying to go difficult . How about now with Join function !
VB Code:
Dim path1 As String = "c:\windows"
Dim path2 As String = "system32"
Dim tmp As String = String.Join("\", New String() {path1, path2})
MessageBox.Show(tmp)
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
|