c# get Image directory path after selecting image on open file dialog

前端 未结 1 1220
借酒劲吻你
借酒劲吻你 2021-01-29 11:44

is there a way to get the image directory path after selecting in file dialog

example C:\\Users\\Admin\\Desktop\\IMG\\pix200.jpg

i have a code that

相关标签:
1条回答
  • 2021-01-29 12:46

    Try to make use of the Path.GetDirectoryName method. Example:

    string path = Path.GetDirectoryName(openFD.FileName);
    
    0 讨论(0)
提交回复
热议问题