Re: Problem opening avi file
I have a sample program (Listed below) that does the same thing as you depict so maybe something is wrong with your file? Two Command buttons, (cmdPlay and cmdStop), a CommonDialog control (DlgOpen) + the Animation control (anmAVI) is all you need to run this sample, with some editing of the dlgOpen.InitDIr statement.
private Sub cmdPlay_Click()
' Configure a CommonDialog control to allow the
' user to find .avi files to play. The CommonDialog
' control is named "dlgOpen." The Animation control
' is named "anmAVI."
dlgOpen.Filter = "avi files (*.avi)|*.avi"
dlgOpen.InitDir = "C:\Program Files\Microsoft Visual Studio\Common\Graphics\Videos"
dlgOpen.ShowOpen
anmAVI.Open dlgOpen.FileName
anmAVI.Play
End Sub
'This code stops the video playing:
private Sub cmdStop_Click()
anmAVI.Stop
End Sub
John G