File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes JavaFX and the fly likes Run a flash file(.swf) in javafx Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Java » JavaFX
Bookmark "Run a flash file(.swf) in javafx " Watch "Run a flash file(.swf) in javafx " New topic
Author

Run a flash file(.swf) in javafx

Ruturaj Deshpande
Greenhorn

Joined: Nov 13, 2013
Posts: 3
Hello I'm new to this forum and also new to JavaFX.
In my project, I need to run a .swf file embedded in a JavaFX stage. I also need to update database after running the flash file. So a standalone flash player is not an option.
Any solution?
John Damien Smith
Ranch Hand

Joined: Jan 26, 2012
Posts: 130
    
    9
Use Java 8 with a SwingNode and the DJ project.
I've never tried this combination, it may or may not work.

The JavaFX API itself does not directly support embedded Flash (hence the round-about JavaFX/Swing/embedded flash player recommendation).

I'd say, in general, mixing Flash and JavaFX is one of those not really recommended things, so try it only if you must.

http://djproject.sourceforge.net/ns/
https://jdk8.java.net/download.html
http://download.java.net/jdk8/jfxdocs/javafx/embed/swing/SwingNode.html
Ruturaj Deshpande
Greenhorn

Joined: Nov 13, 2013
Posts: 3
Yes I'd looked at these alternatives but jdk 8 stable release is not available yet.
Also the target platform will need to be upgraded to jdk 8 which is not preferable.
So thanks but let me know if there are other alternatives.
John Damien Smith
Ranch Hand

Joined: Jan 26, 2012
Posts: 130
    
    9
There are no alternatives.
Karthik Shiraly
Ranch Hand

Joined: Apr 04, 2009
Posts: 489
    
    5
Maybe try converting your SWF to HTML5 using something like this and show it in WebView?
Just an alternative approach - I've not tried it out.
Ruturaj Deshpande
Greenhorn

Joined: Nov 13, 2013
Posts: 3
Converting to HTML5 is good idea but the tool you mentioned does not support ActionScript I think
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Run a flash file(.swf) in javafx
 
Similar Threads
SWF contents are not visible when navigating through Servlet.
URL-Pattern, Internet Explorer and Flash Videos
Why should integrate Tomcat with IIS for website
Run flash files in Tomcat6.0
.swf file is not loaded in my machine