473,385 Members | 1,907 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,385 software developers and data experts.

Im trying to GetFrameFromVideo file but im getting exception error file not found:

Thats not the complete code but thats the line givem e the exception:



Expand|Select|Wrap|Line Numbers
  1. using System;
  2. using System.Collections.Generic;
  3. using System.ComponentModel;
  4. using System.Data;
  5. using System.Drawing;
  6. using System.Linq;
  7. using System.Text;
  8. using System.Windows.Forms;
  9. using System.Media;
  10. using Microsoft.VisualBasic;
  11. using Microsoft.VisualBasic.Devices;
  12. using System.Runtime.InteropServices;
  13. using Text_Adventure_Escape_The_Room;
  14. using DexterLib;
  15. using JockerSoft.Media;
  16.  
  17. namespace Text_Adventure_Escape_The_Room
  18. {
  19.     public partial class Form1 : Form
  20.     {
  21.         IMediaDet IMedia;
  22.         ISampleGrabber grabb;
  23.         SoundPlayer sp = new SoundPlayer(@"d:\door_closing2.wav");
  24.         string Video_File_To_Play;
  25.         string s;
  26.         string inventory;
  27.         char[] chars;
  28.         int i=0;
  29.         public Form1()
  30.         {
  31.             InitializeComponent();
  32.             textBox1.Enabled = false;
  33.             Video_File_To_Play = @"d:\lightnings3.avi";
  34.             FrameGrabber.GetFrameFromVideo(Video_File_To_Play, 0.2d);
  35.  

The file exist 100% i did breakpoint and saw it checked my hard disk and im also using this file with a control i did long time ago on this project and display the file in picturebox and its working ok.

But this line : FrameGrabber.GetFrameFromVideo(Video_File_To_Play, 0.2d); give me the exception:

Could not load file or assembly 'Interop.DexterLib, Version=1.0.0.0, Culture=neutral, PublicKeyToken=59345589f61c4f31' or one of its dependencies. The system cannot find the file specified.



Im using .NET 4.0

And windows 7 64bit

In this project References i added : Interop.DexterLib and JockerSoft.Media

Maybe the Interop.DexterLib need another version?



This is the complete exception:



Expand|Select|Wrap|Line Numbers
  1. System.IO.FileNotFoundException was unhandled
  2.   Message=Could not load file or assembly 'Interop.DexterLib, Version=1.0.0.0, Culture=neutral, PublicKeyToken=59345589f61c4f31' or one of its dependencies. The system cannot find the file specified.
  3.   Source=JockerSoft.Media
  4.   FileName=Interop.DexterLib, Version=1.0.0.0, Culture=neutral, PublicKeyToken=59345589f61c4f31
  5.   FusionLog==== Pre-bind state information ===
  6. LOG: User = Chocolade-PC\Chocolade
  7. LOG: DisplayName = Interop.DexterLib, Version=1.0.0.0, Culture=neutral, PublicKeyToken=59345589f61c4f31
  8.  (Fully-specified)
  9. LOG: Appbase = file:///D:/C-Sharp/Escape_The_Room_Game/Text_Adventure_Escape_The_Room/Text_Adventure_Escape_The_Room/bin/Debug/
  10. LOG: Initial PrivatePath = NULL
  11. Calling assembly : JockerSoft.Media, Version=1.0.0.1, Culture=neutral, PublicKeyToken=59345589f61c4f31.
  12. ===
  13. LOG: This bind starts in default load context.
  14. LOG: No application configuration file found.
  15. LOG: Using host configuration file: 
  16. LOG: Using machine configuration file from C:\Windows\Microsoft.NET\Framework\v4.0.30319\config\machine.config.
  17. LOG: Post-policy reference: Interop.DexterLib, Version=1.0.0.0, Culture=neutral, PublicKeyToken=59345589f61c4f31
  18. LOG: Attempting download of new URL file:///D:/C-Sharp/Escape_The_Room_Game/Text_Adventure_Escape_The_Room/Text_Adventure_Escape_The_Room/bin/Debug/Interop.DexterLib.DLL.
  19. LOG: Attempting download of new URL file:///D:/C-Sharp/Escape_The_Room_Game/Text_Adventure_Escape_The_Room/Text_Adventure_Escape_The_Room/bin/Debug/Interop.DexterLib/Interop.DexterLib.DLL.
  20. LOG: Attempting download of new URL file:///D:/C-Sharp/Escape_The_Room_Game/Text_Adventure_Escape_The_Room/Text_Adventure_Escape_The_Room/bin/Debug/Interop.DexterLib.EXE.
  21. LOG: Attempting download of new URL file:///D:/C-Sharp/Escape_The_Room_Game/Text_Adventure_Escape_The_Room/Text_Adventure_Escape_The_Room/bin/Debug/Interop.DexterLib/Interop.DexterLib.EXE.
  22.  
  23.   StackTrace:
  24.        at JockerSoft.Media.FrameGrabber.GetFrameFromVideo(String videoFile, Double percentagePosition, Double& streamLength, Size target)
  25.        at JockerSoft.Media.FrameGrabber.GetFrameFromVideo(String videoFile, Double percentagePosition)
  26.        at Text_Adventure_Escape_The_Room.Form1..ctor() in D:\C-Sharp\Escape_The_Room_Game\Text_Adventure_Escape_The_Room\Text_Adventure_Escape_The_Room\Form1.cs:line 34
  27.        at Text_Adventure_Escape_The_Room.Program.Main() in D:\C-Sharp\Escape_The_Room_Game\Text_Adventure_Escape_The_Room\Text_Adventure_Escape_The_Room\Program.cs:line 18
  28.        at System.AppDomain._nExecuteAssembly(RuntimeAssembly assembly, String[] args)
  29.        at System.AppDomain.ExecuteAssembly(String assemblyFile, Evidence assemblySecurity, String[] args)
  30.        at Microsoft.VisualStudio.HostingProcess.HostProc.RunUsersAssembly()
  31.        at System.Threading.ThreadHelper.ThreadStart_Context(Object state)
  32.        at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean ignoreSyncCtx)
  33.        at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state)
  34.        at System.Threading.ThreadHelper.ThreadStart()
  35.   InnerException: 



Thanks.
Jan 16 '11 #1
2 3890
turn this line:
Expand|Select|Wrap|Line Numbers
  1. FrameGrabber.GetFrameFromVideo(Video_File_To_Play, 0.2d);
into this:
Expand|Select|Wrap|Line Numbers
  1. if (System.IO.FileExists(Video_File_To_Play)
  2.     FrameGrabber.GetFrameFromVideo(Video_File_To_Play, 0.2d);
That just makes it fool-proof.

Currently working on a solution.
Jan 16 '11 #2
Try this way of doing it.
The function was released by microsoft so it may implement easier.

http://www.c-sharpcorner.com/uploadf...yingvideo.aspx

Otherwise im too unfamiliar with DexterLib to be of any help.
Jan 17 '11 #3

Sign in to post your reply or Sign up for a free account.

Similar topics

6
by: Giulio Neri | last post by:
Hi, I have a short basic script to upload files. It works fine with small files, but with longer files it gets stuck. Here's the fragment, the input file is loaded in "$file" from an HTML form...
1
by: Borek | last post by:
Hello, I am getting the beforementioned error when trying to populate DataSet object with data taken from SQL2k database. Then I want to bind DataSet to GridView control. But when I use...
2
by: David Hearn | last post by:
Timeout expired. The timeout period elapsed prior to completion of the operation or the server is not responding. Description: An unhandled exception occurred during the execution of the current...
3
by: JackO | last post by:
I am getting the following error: Exception Details: System.NullReferenceException: Object reference not set to an instance of an object. Source Error: Line 192: Line 193: Private Sub...
9
by: Ron | last post by:
my application is throwing an exception error when closing if I run a procedure in the app. I can't even trap the error with try/catch ex As Exception. Is there a way to completely shut down the...
4
by: PAPutzback | last post by:
Message Exception: The process cannot access the file "K:\EDI DATA\ANS\OUTBOUND\ARCHIVE\IPHC20041207.TXT" because it is being used by another process. StackTrace Exception: at...
8
by: Philip Colmer | last post by:
I'm rewriting some existing VBScript into VB.Net code. It was all going well until I hit the following error when testing the code: System.Runtime.InteropServices.COMException (0x80041003) at...
1
by: SQLJunkie | last post by:
Hi, I have installed SQL 2005 RTM on a new server and I keep getting this error (described below) quite frequently. Was wondering if anyone has a clue on what's happening here. I tried googling...
1
by: hzgt9b | last post by:
(FYI, using VB .NET 2003) Can someone help me with this... I'm trying to read in an XML file... it appears to work in that the DataSet ReadXML method dose not fail and then I am able to access the...
1
by: g35rider | last post by:
Hi, I am trying to understand from C++ point of view what the problem is. I have a file called. Controllers.h in which I have a base class Controller and couple of other sub classes...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.