Getting the physical path
Posted
by Brigadier Jigar
on Stack Overflow
See other posts from Stack Overflow
or by Brigadier Jigar
Published on 2010-03-17T12:48:42Z
Indexed on
2010/03/26
11:13 UTC
Read the original article
Hit count: 192
c#
I have to fetch all the files from a folder and i am using the function GetFiles() like
string[] dirImages = Directory.GetFiles(strPathYearImages + intYear , "*.png"); where strPathYearImages="Images\Holiday\2010\"
but when i write the whole path like
string[] dirImages = Directory.GetFiles(@"E:\IWP\Images\Holiday\"+ intYear , "*.png");
i get the required result.
How to solve this problem? I dont want to use the whole path. Help me out.
Regards, Jigar <3
© Stack Overflow or respective owner