Flash .swf in a userform of vba project
-
- PlatinumLounger
- Posts: 4368
- Joined: 26 Apr 2010, 17:36
Flash .swf in a userform of vba project
Can i use and run a .swf macromedia file in a userform of excel?
Possible?
Possible?
-
- Administrator
- Posts: 7218
- Joined: 15 Jan 2010, 22:52
- Location: Middle of England
-
- Administrator
- Posts: 78608
- Joined: 16 Jan 2010, 00:14
- Status: Microsoft MVP
- Location: Wageningen, The Netherlands
Re: Flash .swf in a userform of vba project
Yes, using the Shockwave Flash object - see Embedding flash movies on userforms using the Shockwave Flash Object library.
Best wishes,
Hans
Hans
-
- PlatinumLounger
- Posts: 4368
- Joined: 26 Apr 2010, 17:36
Re: Flash .swf in a userform of vba project
Hans difficult to insert this in a userform can you send me example with atteched file?HansV wrote:Yes, using the Shockwave Flash object - seeEmbedding flash movies on userforms using the Shockwave Flash Object library.
tks.
-
- Administrator
- Posts: 78608
- Joined: 16 Jan 2010, 00:14
- Status: Microsoft MVP
- Location: Wageningen, The Netherlands
Re: Flash .swf in a userform of vba project
Have you placed a Shockwave Flash object on your userform?
Best wishes,
Hans
Hans
-
- PlatinumLounger
- Posts: 4368
- Joined: 26 Apr 2010, 17:36
Re: Flash .swf in a userform of vba project
Ok to lunch the swf... but i cannot intercept the click event on icon...HansV wrote:Have you placed a Shockwave Flash object on your userform?
the original code is a vb6 code but i need to use in a vba userform:
Private Sub swfWelcome_FSCommand(ByVal command As String, ByVal args As String)
MsgBox "You clicked on: " & command
End Sub
here the original link:
http://www.Planet-Source-Code.com/vb/sc ... 2&lngWId=1
-
- Administrator
- Posts: 78608
- Joined: 16 Jan 2010, 00:14
- Status: Microsoft MVP
- Location: Wageningen, The Netherlands
Re: Flash .swf in a userform of vba project
You have set the EmbedMovie property of the ShockWaveFlash control to False, so the movie is linked to your hard disk. This means that it will not run on any other PC.
But even if I use the .swf that you attached earlier, it doesn't do anything. What do you want to do with the movie?
But even if I use the .swf that you attached earlier, it doesn't do anything. What do you want to do with the movie?
Best wishes,
Hans
Hans
-
- PlatinumLounger
- Posts: 4368
- Joined: 26 Apr 2010, 17:36
Re: Flash .swf in a userform of vba project
two question:HansV wrote:You have set the EmbedMovie property of the ShockWaveFlash control to False, so the movie is linked to your hard disk. This means that it will not run on any other PC.
But even if I use the .swf that you attached earlier, it doesn't do anything. What do you want to do with the movie?
- how to not set the path c:\eccc... and use the movie from all
- i nedd to use the click event on one icon
similar:
if i click on one icon the msgbox("eccc.")
-
- Administrator
- Posts: 78608
- Joined: 16 Jan 2010, 00:14
- Status: Microsoft MVP
- Location: Wageningen, The Netherlands
Re: Flash .swf in a userform of vba project
If you set the EmbedMovie property of the ShockWaveFlash control to True, the move specified in the Movie property will be embedded in the userform, so that other users can see it too.
I can't view the movie, so I have no idea what icon you mean, and therefore I can't answer your second question.
I can't view the movie, so I have no idea what icon you mean, and therefore I can't answer your second question.
Best wishes,
Hans
Hans
-
- PlatinumLounger
- Posts: 4368
- Joined: 26 Apr 2010, 17:36
Re: Flash .swf in a userform of vba project
the swf is here is named welcome:HansV wrote:If you set the EmbedMovie property of the ShockWaveFlash control to True, the move specified in the Movie property will be embedded in the userform, so that other users can see it too.
I can't view the movie, so I have no idea what icon you mean, and therefore I can't answer your second question.
http://www.eileenslounge.com/viewtopic ... rn false;
-
- Administrator
- Posts: 78608
- Joined: 16 Jan 2010, 00:14
- Status: Microsoft MVP
- Location: Wageningen, The Netherlands
Re: Flash .swf in a userform of vba project
I know, but I cannot play it on my PC. I only see a still image with a bit of text.
Best wishes,
Hans
Hans
-
- PlatinumLounger
- Posts: 4368
- Joined: 26 Apr 2010, 17:36
Re: Flash .swf in a userform of vba project
possible?HansV wrote:I know, but I cannot play it on my PC. I only see a still image with a bit of text.
I use ver 2003 of excel and i see correct the animation(!?)...
In other case the click event in vb6 work in a vb6 project:
Private Sub swfWelcome_FSCommand(ByVal command As String, ByVal args As String)
MsgBox "You clicked on: " & command
End Sub
but the code:
Private Sub ShockwaveFlash1_FSCommand(ByVal command As String, ByVal args As String)
MsgBox "You clicked on: " & command
End Sub
not generate nothing if i click in one icon in movie!!!
-
- Administrator
- Posts: 78608
- Joined: 16 Jan 2010, 00:14
- Status: Microsoft MVP
- Location: Wageningen, The Netherlands
Re: Flash .swf in a userform of vba project
Sorry, I have no idea. I wouldn't use a shockwave movie on a userform, it's buggy and you have no guarantee that it'll work on other PCs.
Best wishes,
Hans
Hans
-
- PlatinumLounger
- Posts: 4368
- Joined: 26 Apr 2010, 17:36
Re: Flash .swf in a userform of vba project
peraphs you need to copy the dir ICONS from original project into the same path where is the excel file...HansV wrote:Sorry, I have no idea. I wouldn't use a shockwave movie on a userform, it's buggy and you have no guarantee that it'll work on other PCs.
Please dowlod the complete file from PSC posted..
-
- Administrator
- Posts: 78608
- Joined: 16 Jan 2010, 00:14
- Status: Microsoft MVP
- Location: Wageningen, The Netherlands
Re: Flash .swf in a userform of vba project
OK, that helped - I now see the icons rotating. But the ShockwaveFlash1_FSCommand doesn't do anything when I click on an icon. I don't have the slightest idea why, so I can't help you - sorry.
I *still* wouldn't use a shockwave movie on a userform, it's buggy and you have no guarantee that it'll work on other PCs.
I *still* wouldn't use a shockwave movie on a userform, it's buggy and you have no guarantee that it'll work on other PCs.
Best wishes,
Hans
Hans
-
- PlatinumLounger
- Posts: 4368
- Joined: 26 Apr 2010, 17:36
Re: Flash .swf in a userform of vba project
HansV wrote:OK, that helped - I now see the icons rotating. But the ShockwaveFlash1_FSCommand doesn't do anything when I click on an icon. I don't have the slightest idea why, so I can't help you - sorry.
I *still* wouldn't use a shockwave movie on a userform, it's buggy and you have no guarantee that it'll work on other PCs.