2014-10-08 147 views
0

我试图拍摄视频快照,并将其保存为缩略图。我发现this question并已完成,因为它在那里。但我得到这个异常:拍摄视频快照

WIN32Exception was unhandled by User-Code - The system cannot find the file specified

我做了什么错?

我的代码是在这里:

FFMPEG f = new FFMPEG(); 
f.GetThumbnail(Server.MapPath("~/Uploads/" + unique), Server.MapPath("~/Thumbnails/" + unique.Remove(unique.IndexOf(".")) + ".jpg"), "1200x223"); 

,并有我的folder structure

+0

它明确指出,它无法找到文件错误的道路。 – 2014-10-08 11:20:20

+0

Okuma.Scott你说得对,但为什么?我认为它应该找到该文件 – gsiradze 2014-10-08 11:23:43

+0

看看[Server.MapPath“〜”](http://stackoverflow.com/q/275781/2596334)。 – 2014-10-08 11:37:11

回答

0

您有

ffmpeg.exe

ffmpeg.StartInfo.FileName = HttpContext.Current.Server.MapPath("~/ffmpeg.exe");