A
Anil Gupte/iCinema.com
I am trying to create a simple FlashPlayer in VB. I used the following:
Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As
System.EventArgs) Handles MyBase.Load
Dim axShockwaveFlash As New AxShockwaveFlash
axShockwaveFlash.Location = New System.Drawing.Point(10, 10)
Me.Controls.Add(axShockwaveFlash)
axShockwaveFlash.Movie = "D:\Projects\Flash\Learning\Learning-2.swf"
axShockwaveFlash.Size = New System.Drawing.Size(400, 400)
Dim flvFileName As String = "D:\Video\Clips\PoliceBikeChase.flv"
Try
axShockwaveFlash.FlashVars = "flvurl=" & flvFileName
'axShockwaveFlash.CallFunction("<invoke name=""loadFLV""
returntype=""xml""><arguments><string>" + flvFileName +
"</string></arguments></invoke>")
' The above generates an error
Catch ex As Exception
End Try
axShockwaveFlash.Play()
End Sub
When I inspect FlashVars, it shows as blank, both before and after the
statement inside Try above. Also the commented out statement immediately
below that generates and error:
{"Error HRESULT E_FAIL has been returned from a call to a COM component."}
System.Exception
How do I get it to work?
Thanx in advance,
Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As
System.EventArgs) Handles MyBase.Load
Dim axShockwaveFlash As New AxShockwaveFlash
axShockwaveFlash.Location = New System.Drawing.Point(10, 10)
Me.Controls.Add(axShockwaveFlash)
axShockwaveFlash.Movie = "D:\Projects\Flash\Learning\Learning-2.swf"
axShockwaveFlash.Size = New System.Drawing.Size(400, 400)
Dim flvFileName As String = "D:\Video\Clips\PoliceBikeChase.flv"
Try
axShockwaveFlash.FlashVars = "flvurl=" & flvFileName
'axShockwaveFlash.CallFunction("<invoke name=""loadFLV""
returntype=""xml""><arguments><string>" + flvFileName +
"</string></arguments></invoke>")
' The above generates an error
Catch ex As Exception
End Try
axShockwaveFlash.Play()
End Sub
When I inspect FlashVars, it shows as blank, both before and after the
statement inside Try above. Also the commented out statement immediately
below that generates and error:
{"Error HRESULT E_FAIL has been returned from a call to a COM component."}
System.Exception
How do I get it to work?
Thanx in advance,