首页 > 解决方案 > Could not find file '/app/"Dynamic path which user selects picture"' in .net core web api

问题描述

FileInfo fInfo = new FileInfo(sPath);long numBytes = fInfo.Length;

string path=@User.Profilepicture;string imgPath = **System.IO.File.ReadAllText(User.Profilepicture);**  
byte[] byteData = System.IO.File.ReadAllBytes(imgPath);

System.IO.FileNotFoundException: Could not find file '/app/@D:\projectpic.png'. File name: '/app/@D:\projectpic.png'

Unable to access the selected file

标签: microservicesasp.net-core-webapi

解决方案


推荐阅读