Results 1 to 3 of 3
  1. #1
    shadab is offline Member
    Join Date
    Aug 2008
    Location
    pune
    Posts
    2
    Rep Power
    0

    Exclamation how to solve capital country program in java applet

    hi i wrote java applet country capital program .in which user will enter the the country name
    in one text field and their capital will be seen on another text field .for the time .I kept all country in one string array and capital on another string array.But i want to access capital country from file and then read it to string arrays. Any one can help me to solve such problem.......:cool:

  2. #2
    shadab is offline Member
    Join Date
    Aug 2008
    Location
    pune
    Posts
    2
    Rep Power
    0

    Default

    problem in appplet

  3. #3
    Norm's Avatar
    Norm is offline Moderator
    Join Date
    Jun 2008
    Location
    Eastern Florida
    Posts
    17,902
    Rep Power
    25

    Default

    For an applet to read a file, it should use getResouceAsStream() vs a File class. Applets are NOT allowed to read files from the local disk by File classes. Using the above method, the system will find the file and connect the program to it to allow reading the file without violating the permission requirement.
    Use search to find code examples.

Similar Threads

  1. Please help me solve these Java Problems
    By saculellav in forum New To Java
    Replies: 9
    Last Post: 07-06-2014, 10:25 AM
  2. how can i turn this java program to an applet
    By anotsu in forum New To Java
    Replies: 5
    Last Post: 03-11-2008, 12:48 AM
  3. A great doubt in Java Applet,will u solve it!!
    By anithababu in forum Java Applets
    Replies: 6
    Last Post: 01-27-2008, 02:20 PM
  4. Convert a program to Applet
    By carl in forum Java Applets
    Replies: 2
    Last Post: 08-09-2007, 10:33 PM
  5. Export to Java program, applet or c/c++
    By fernando in forum New To Java
    Replies: 1
    Last Post: 08-07-2007, 07:55 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •