如何以独立于平台的方式在netbeans的Java框架内运行外部程序? [英] How do I run an external program inside a Java frame in netbeans in a platform independent manner?

查看:124
本文介绍了如何以独立于平台的方式在netbeans的Java框架内运行外部程序?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我目前正在为某大学的研究项目工作,在该项目中,我与数据库进行GUI交互,并基于数据启动了一个外部程序.我正在使用运行时命令(一旦检测到操作系统)来启动具有所选数据的外部程序.

I am currently working on a research project for a University in which I am doing GUI interactions with my database and launching an external program based on the data. I'm using runtime commands (once the OS is detected) to launch that external program with the selected data.

我的问题是,即使可以远程实现,如何将外部程序的GUI嵌入Java框架中?

My question is how can I embed an external program's GUI inside a Java frame, if that is even remotely possible?

推荐答案

给出关于该问题的清晰注释,简短的回答是不,你不能那样做".

Given the clarifying comments on the question, the short answer is "no, you can't do that".

即使目标程序实际上被设计为允许其GUI出现在另一个程序的框架中,Java也无法在JFrame中显示本机程序的GUI.

Java cannot display a native program's GUI within a JFrame, even if the target program was actually architected to allow it's GUI to be presented within another program's frame.

这篇关于如何以独立于平台的方式在netbeans的Java框架内运行外部程序?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆