2014-10-08 130 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");