Solved

resource for Animation control

Posted on 1998-12-23
3
169 Views
Last Modified: 2010-05-03
Does anyone know of a resource on the internet for AVI files compatible with the Animation control shipped in VB5?
0
Comment
Question by:bear454
3 Comments
 
LVL 13

Expert Comment

by:Mirkwood
ID: 1452213
0
 
LVL 1

Author Comment

by:bear454
ID: 1452214
I am trying to avoid packaging another ocx in my application.  After careful consideration I have chosen the Animation control, because anyone running win32 or better will have it.
I am looking for additional AVI media, not an alternative media player.
0
 
LVL 14

Accepted Solution

by:
waty earned 100 total points
ID: 1452215
Private Declare Function mciSendString Lib "winmm.dll" Alias "mciSendStringA" (ByVal lpstrCommand As String, ByVal lpstrReturnString As String, ByVal uReturnLength As Long, ByVal hwndCallback As Long) As Long

Public Sub PlayAVI(sFileName As String)
   ' #VBIDEUtils#************************************************************
   ' * Programmer Name  : Waty Thierry
   ' * Web Site         : www.geocities.com/ResearchTriangle/6311/
   ' * E-Mail           : waty.thierry@usa.net
   ' * Date             : 20/11/98
   ' * Time             : 09:35
   ' * Module Name      : Multimedia_Module
   ' * Module Filename  : Multimedia.bas
   ' * Procedure Name   : PlayAVI
   ' * Parameters       :
   ' *                    sFileName As String
   ' **********************************************************************
   ' * Comments         : play an AVI video file without using the Multimedia
   ' *  (MCI) Control
   ' *
   ' **********************************************************************
   
   Dim returnstring     As String
   
   returnstring = Space(127)
   
   Call mciSendString("open " & Chr$(34) & sFileName & Chr$(34) & " type avivideo alias video", returnstring, 127, 0)
   Call mciSendString("set video time format ms", returnstring, 127, 0)
   Call mciSendString("play video from 0", returnstring, 127, 0)
   
   ' *** It is important to close the video, even if the file to play has run out.
   
End Sub

Public Sub StopAVI()
   ' #VBIDEUtils#************************************************************
   ' * Programmer Name  : Waty Thierry
   ' * Web Site         : www.geocities.com/ResearchTriangle/6311/
   ' * E-Mail           : waty.thierry@usa.net
   ' * Date             : 20/11/98
   ' * Time             : 09:36
   ' * Module Name      : Multimedia_Module
   ' * Module Filename  : Multimedia.bas
   ' * Procedure Name   : StopAVI
   ' * Parameters       :
   ' **********************************************************************
   ' * Comments         : Close a played AVI
   ' *
   ' * It is important to close the video, even if the file to play has run out.
   ' *
   ' **********************************************************************
   
   Dim returnstring     As String
   
   returnstring = Space(127)
   Call mciSendString("close video", returnstring, 127, 0)
   
End Sub


0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction I needed to skip over some file processing within a For...Next loop in some old production code and wished that VB (classic) had a statement that would drop down to the end of the current iteration, bypassing the statements that were c…
This article describes some techniques which will make your VBA or Visual Basic Classic code easier to understand and maintain, whether by you, your replacement, or another Experts-Exchange expert.
Get people started with the utilization of class modules. Class modules can be a powerful tool in Microsoft Access. They allow you to create self-contained objects that encapsulate functionality. They can easily hide the complexity of a process from…
Show developers how to use a criteria form to limit the data that appears on an Access report. It is a common requirement that users can specify the criteria for a report at runtime. The easiest way to accomplish this is using a criteria form that a…

920 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

16 Experts available now in Live!

Get 1:1 Help Now