Need help with Visual BASIC 6 for a final project
Moderator: Thanas
-
- Youngling
- Posts: 90
- Joined: 2005-09-18 12:05am
Need help with Visual BASIC 6 for a final project
My programming class is winding down, and I am writing my final project. It is a basic Star Trek scrolling game where you shoot down the oncoming ships. Now I wanted to use a small video clip to show when you have lost. I chose a clip from TNG "Cause and Effect" where Picard is screaming "All hands abandon ship". Now, how can I insert this clip into a form and have it play?
msdn.microsoft.com
Everything you'll ever want to know about an MS programming language.
But, quite frankly, you'll probably have to dig into the ugly API for this one. It's not a thing done lightly.
Try this link for a little help....
Oh, and don't worry. When you start using .NET, it's all MUCH prettier.
Everything you'll ever want to know about an MS programming language.
But, quite frankly, you'll probably have to dig into the ugly API for this one. It's not a thing done lightly.
Try this link for a little help....
Oh, and don't worry. When you start using .NET, it's all MUCH prettier.
"Peace on Earth and goodwill towards men? We are the United States Goverment - we don't DO that sort of thing!" - Sneakers. Best. Quote. EVER.
Periodic Pwnage Pantry:
"Faith? Isn't that another term for ignorance?" - Gregory House
"Isn't it interesting... religious behaviour is so close to being crazy that we can't tell them apart?" - Gregory House
"This is usually the part where people start screaming." - Gabriel Sylar
Periodic Pwnage Pantry:
"Faith? Isn't that another term for ignorance?" - Gregory House
"Isn't it interesting... religious behaviour is so close to being crazy that we can't tell them apart?" - Gregory House
"This is usually the part where people start screaming." - Gabriel Sylar
One way of doing it (as is done in C, for instance)is to embed the video file into the resources, load it into memory during runtime, and finally play it from memory.
After a quick googling, I found the following:
http://64.233.161.104/search?q=cache:Rk ... Data&hl=en
It appears to be far more simple, with the Animation ActiveX control handling most of the tough stuff.
Best of luck with the project.
After a quick googling, I found the following:
http://64.233.161.104/search?q=cache:Rk ... Data&hl=en
Code: Select all
Option Explicit
Private Const WM_USER = &H400&
Private Const ACM_OPEN = WM_USER + 100&
Private Declare Function SendMessage Lib "user32" Alias "SendMessageA" (ByVal hwnd As Long, ByVal wMsg As Long, ByVal wParam As Long, ByVal lParam As Any) As Long
Private Sub Command1_Click()
Dim ResID As Long
ResID = 101
SendMessage Animation1.hwnd, ACM_OPEN, App.hInstance, ResID
End Sub
Best of luck with the project.
-
- Youngling
- Posts: 90
- Joined: 2005-09-18 12:05am