473,405 Members | 2,167 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,405 software developers and data experts.

Embed Swing App in .Net Application via a Window (form?)

Hi,

Does anybody have any information on where I can find some details of
how I would go about embedding an existing Java swing application into
the window (form?) of a new .Net application on Windows.

I'd like to take a useful existing java app which I work on day to day
and allow users to view it in a new .Net app the company are working
on.

Is such a thing possible and if so how and what are the constraints
(risizing ?, mouse/keyboard events ? .....)

Thanks

Steve
Jun 27 '08 #1
5 2492
On Tue, 24 Jun 2008 08:11:35 -0700, swebb99 <sw*****@gmail.comwrote:
Does anybody have any information on where I can find some details of
how I would go about embedding an existing Java swing application into
the window (form?) of a new .Net application on Windows.

I'd like to take a useful existing java app which I work on day to day
and allow users to view it in a new .Net app the company are working
on.
Do you need it to interact with your .NET application in any way other
than being presented within it? If not, and if you can make the
application an applet, then the easiest approach might be to do that and
then embed it in a basic HTML page displayed by the WebBrowser control.

Pete
Jun 27 '08 #2
swebb99 wrote:
Does anybody have any information on where I can find some details of
how I would go about embedding an existing Java swing application into
the window (form?) of a new .Net application on Windows.

I'd like to take a useful existing java app which I work on day to day
and allow users to view it in a new .Net app the company are working
on.

Is such a thing possible and if so how and what are the constraints
(risizing ?, mouse/keyboard events ? .....)
I am afraid that you will need to keep them as two separate apps.

It is possible to use Java code from .NET using the IKVM sofware,
but IKVM does not support Swing, so it will not work for you (it
does work fine for some other types of usage).

Arne
Jun 27 '08 #3
Do you need it to interact with your .NET application in any way other *
than being presented within it? *If not, and if you can make the *
application an applet, then the easiest approach might be to do that and *
then embed it in a basic HTML page displayed by the WebBrowser control.

Pete
Still not decided if it should interact or not but the applet idea
seems like a possible way forward. There is an applet version of the
app that interacts with Javascript, does .Net have anyway of receiving
events from javascript ?

Thanks

Steve
Jun 27 '08 #4
On 25 Jun, 00:27, Arne Vajhøj <a...@vajhoej.dkwrote:
swebb99 wrote:
Does anybody have any information on where I can find some details of
how I would go about embedding an existing Java swing application into
the window (form?) of a new .Net application on Windows.
I'd like to take a useful existing java app which I work on day to day
and allow users to view it in a new .Net app the company are working
on.
Is such a thing possible and if so how and what are the constraints
(risizing ?, mouse/keyboard events ? .....)

I am afraid that you will need to keep them as two separate apps.

It is possible to use Java code from .NET using the IKVM sofware,
but IKVM does not support Swing, so it will not work for you (it
does work fine for some other types of usage).

Arne
Thats a shame, I'll have a read about IKVM anyway as it might come in
useful at some point.

Thanks

Steve
Jun 27 '08 #5
On Wed, 25 Jun 2008 00:49:11 -0700, swebb99 <sw*****@gmail.comwrote:
Still not decided if it should interact or not but the applet idea
seems like a possible way forward. There is an applet version of the
app that interacts with Javascript, does .Net have anyway of receiving
events from javascript ?
Not that I know of. But I haven't used the WebBrowser control much. It's
possible you could find something in that control that allows the client
of the control to watch for things coming from Javascript.

I'm far from being an expert in this particular area, so I don't really
know much about what you can do. I _suspect_ that there's really no good
support for integrating Java or Javascript with a .NET application, but I
can't say that for sure.

Pete
Jun 27 '08 #6

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

6
by: Joseph | last post by:
hi 1) i plan on having an awt canvas component (to draw graphs) on a JFrame with other swing components..will this be okay? i've read that swing and awt aren't compatible.. 2)Also, if i...
0
by: Ney André de Mello Zunino | last post by:
Hello. I have decided to look again at Java after a *really* long break. While browsing through the Swing tutorials , I noticed that the basic skeleton of the demo applications had something...
2
by: Raghavendran Muraleetharan | last post by:
I am having an existing VB 6 standard .EXE application. Now I am developing a wrapper application in .Net and I want to launch the VB 6 exe app embedded with in the .Net App window. That is, the...
1
by: Udi | last post by:
Hi All, I need to embed the ethereal process inside my .NET app. ( http://www.ethereal.com ) I assume the best solution would be getting hands on the ethereal main window form and host it in my...
7
by: ScottH | last post by:
Curious how you could embed a console in a Windows form.. any ideas ?
1
by: requeth | last post by:
I'm trying to embed a command window in a form in VB.NET. I remember back in the old days there was a button in the IDE to add the window, and I never really learned how it worked. I just...
6
by: r035198x | last post by:
I have put together this article to give people starting Swing an awareness of issues that need to be considered when creating a Swing application. Most of the Swing tutorials that I have seen just...
8
risk32
by: risk32 | last post by:
Hi all. I have a really confusing problem. I'm using Swing and I'm trying to do a confirmation box : int reply; String message = "Do you want to input another number?"; String title = "Input...
2
dream party
by: dream party | last post by:
Inserting a Flash (SWF, FLV) file into HTML web page is already an old and familiar thing to all of us. It is a rather non-flexible thing that just to edit some options in the template. However, I...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.