• Post Reply Bookmark Topic Watch Topic
  • New Topic

Java app for windows  RSS feed

 
Roger Wells
Ranch Hand
Posts: 51
1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I have my application running on a mac and have been able to create a dmg file.

How do I create a windows .exe version using my app and mac? Do I need a windows system to do this or can I do it
on the mac? Are there any tutorials for doing this? Can I test the .exe file using crossover?


Thanks
Roger
 
Norm Radder
Rancher
Posts: 2240
28
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
If the windows system has a JRE installed, there is no need to create an exe file.  The jar file will execute on Windows when openned.
 
Roger Wells
Ranch Hand
Posts: 51
1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks Norm

That lets me know how.

My biggest concern is testing the app now. I use the plist in my app and it works great on a mac but for windows
I suspect that it will use the register file? If so and I do something to mess up someones registry file on
windows they will not be very happy.

Any suggestions on how to test it?

Thanks
Roger
 
Norm Radder
Rancher
Posts: 2240
28
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
What classes and methods are you using that you think will write to the Windows registry?
 
Carey Brown
Saloon Keeper
Posts: 3310
46
Eclipse IDE Firefox Browser Java MySQL Database VI Editor Windows
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Roger Wells wrote:...  I use the plist in my app and it works great on a mac but for windows I suspect that it will use the register file?

Not being a mac person, I'm curious, what is a "plist" and how does your Java code interact with it (API)?
 
Maneesh Godbole
Bartender
Posts: 11445
18
Android Eclipse IDE Google Web Toolkit Java Mac Ubuntu
  • Likes 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Carey Brown wrote:
Roger Wells wrote:...  I use the plist in my app and it works great on a mac but for windows I suspect that it will use the register file?

Not being a mac person, I'm curious, what is a "plist" and how does your Java code interact with it (API)?


plist is the Mac version of preference file.
https://discussions.apple.com/thread/1869002?tstart=0

Ideally one should be using the preferences API so as to make it platform independent.
 
Tim Moores
Saloon Keeper
Posts: 4024
94
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Maneesh Godbole wrote: one should be using the preferences API so as to make it platform independent.


+1
 
Roger Wells
Ranch Hand
Posts: 51
1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks maybe I am doing it right?  Here is the code I use to write to what I am calling the plist.

Will this write to the plist for mac and the preference file for windows? I am not a windows person but I thought
that this would write to the windows registry?



My concern is that if I send my code to someone with windows it might mess up their registry. So I need
to find a way to test it on a mac or find some brave person to try it on windows.

The other question is do you have to have the JRE installed on the mac or windows to run the app? Or will the
app contain everything needed so the user will not have to install the JRE?

Thanks
Roger
 
Tim Moores
Saloon Keeper
Posts: 4024
94
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
That code will use the Windows Registry, but it's not a problem because Java app preferences are in their own section that does not interfere with anything else. The package name is also part of the naming scheme, so as long as you make that unique, it won't interfere with other Java apps.

The JRE is required to run Java apps, so your users need to have that installed.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!