This discussion is archived
0 Replies Latest reply: Dec 2, 2010 6:53 AM by 820585 RSS

Problem with reading files

820585 Newbie
Currently Being Moderated
I have method which try to read file. I was trying "InputStream in = SecureNotes.getInstance().getClass().getResourceAsStream(fileName);" - this works perfect on emulator but did not work at phone. Now I'm trying "FileConnection fc = (FileConnection), Connector.READ);". It says: "java.lang.SecurityException: Application not authorized to access the restricted API".
I try

1.close Eclipse java wireless toolkit (my version is 2.5.2) edit -> preferences the preferences dialog , click on the security node of default emulator tree
5.under security , change the security domain to manufacturer project in Eclipse

but it did not help me.

It didn't give me this kind of error for the first time. I went to jwt and open thouse prefs. There were no selected options. Then I open dropdown menu and it automaticaly select "Security Domain" and "Locale". Now i set as "manufacturer" for "Security Domain" and "en: for "Locale".

What I have to do to start this work? :-)


  • Correct Answers - 10 points
  • Helpful Answers - 5 points