java windows 8 file read write permissions - java

We have a Java-JNI application that runs fine on Windows XP, and Windows 7.
When I try to run it on Windows 8 I basically get a cannot create file error.
If I point the file to be created in the Users/documents folder the application works.
If I point the file to be created in a C:\Tests folder or the Program Files (X86)/application folder it fails.
Similarly If I try to shell an application from the Program Files (X86)/application folder it fails.
It seems that using java on Windows 8 or Windows 8.1 has some file/folder creation restrictions.
Any suggestions. We do not want to migrate the entire application to a users folder at this time.
Thanks, Don

Related

Find the running Jar File in a JPackage Program

How can I find the Jar File that my Program is running from, when it is being packed using jpackage (as a URI, URL or File)? I could easily do this on Windows because I know where it is going to be installed, but I would like to make this work on all platforms (Windows, Linux and MacOS). I am unable to experiment with this since I don't have a Mac nor a Linux Machine.
I want to be able to update my Application before/after starting it.
Thanks!

Create executable OSX file on Windows for .jar file

I have created a java program (in Eclipse). I have successfully compiled it to a .jar file which I can run on windows without any problems. I want to give this program to a friend who has a MacOSX. So my aim is to:
Create a file which can be run on MacOSX
The twist is that I have to configure it on my Windows computer since I don't have access to a Mac. Any advice would be of great help!
I am not sure what you are referring as "create a file which can be run on macOSX"
If you want to run on any OS you just need a JRE on that particular system without it you cant run. It will provide a runtime environment to run a jar file. Then use below command to run the jar.
java -jar Myjar_file.jar

Exe files and Windows SmartScreen

I am trying to make a .exe file from a .jar file, and it is working fine. My only problem is that when trying to run it on another computer that I didn't make it on, Windows SmartScreen says it's an unknown app and blocks it from running. I am running Windows 10. Any ideas?
Thanks!

run a jarfile in a different machine from an sqlserver/issue a terminal command from an sqlserver to another windows machine

I have a series of stored procedures(say, SP1, SP2, SP3) consecutively running on an sqlserver(say, serverA).
After SP3 finishes execution, I want to run a jar file in some machine (say, computerA). Is there a way for me to trigger the run of my jar file in computerA after SP3 finishes executing in serverA?
Note: I can only run my jar file in computerA because my jar file actually retrieves data from Bloomberg API. So, this jar file needs to run in a machine that has Bloomberg terminal on it. Only computerA has a Bloomberg terminal.
I think another way of saying this is how to issue a terminal command from an sqlserver to another windows machine. Because I can just issue the following command to computerA but I really don't know how to make that possible.
java -jar D:\Runnables\myJavaApp.jar

Issue while running a java application in Linux env

I have a java project built in eclipse in my Windows machine. Now i had to run it in Linux machine. I created a jar , and i am trying to run the jar.
The main class, takes a XML file as input. Previously on Windows, i had given path of the file in Windows. Now i kept the .xml file in the root location in Unix.
can i modify the code in Windows, to the root path of Linux machine and try to run the jar.
I did it like this ,
XYZ parsero = new XYZ("//root//workflow.xml");
Created the jar and tried to run in Unix.
I got the below exception.
java.net.UnknownHostException: root
How do i need to run this.
I got the solution. It should be XYZ parsero = new XYZ("/root/workflow.xml"); unlike in Windows

Categories

Resources