Applets and files in one

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • pankhudi
    New Member
    • Apr 2007
    • 14

    #1

    Applets and files in one

    How can we perform file handling in applets ?
    It's keeps on giving unreported exception,even if try-catch block is used.

    How can we perform client server action in applet.Actually i want my applet to be the front end for the application and when the user would click "Start"butt on on the applet ,then using ActionListener i have tried to start the client connection.But, stream handling and file opening is not possible.How can it be done? My file should be copied from the server to client and once loaded should start playing.

    What is the limit of size of file(in bytes) that can be sent over a network using Input/OutputStreams.
  • JosAH
    Recognized Expert MVP
    • Mar 2007
    • 11453

    #2
    Originally posted by pankhudi
    How can we perform file handling in applets ?
    It's keeps on giving unreported exception,even if try-catch block is used.

    How can we perform client server action in applet.Actually i want my applet to be the front end for the application and when the user would click "Start"butt on on the applet ,then using ActionListener i have tried to start the client connection.But, stream handling and file opening is not possible.How can it be done? My file should be copied from the server to client and once loaded should start playing.

    What is the limit of size of file(in bytes) that can be sent over a network using Input/OutputStreams.
    Applets run in a very restrictive sandbox, e.g. they are not allowed to fiddle-diddle
    with the filing system of the computer they run on (your client's machine) nor
    are they allowed to establish connections to other machine except to the server
    they were downloaded from. You need to sign your Applet to make it a trusted Applet.

    There's no limit w.r.t. the number of bytes read over a network.

    kind regards,

    Jos

    Comment

    • pankhudi
      New Member
      • Apr 2007
      • 14

      #3
      Originally posted by JosAH
      Applets run in a very restrictive sandbox, e.g. they are not allowed to fiddle-diddle
      with the filing system of the computer they run on (your client's machine) nor
      are they allowed to establish connections to other machine except to the server
      they were downloaded from. You need to sign your Applet to make it a trusted Applet.

      There's no limit w.r.t. the number of bytes read over a network.

      kind regards,

      Jos
      Ya,i just read about signed applets,but actually i am working on my college project and we have been taught simply applets only.

      Is is possible to complete the project?i mean ,i want to know how can we then build this application.
      the objective goes like-
      building an audio online exam system.the audio streaming part is done,now i want that the client first starts with an applet,then when "start exam"is pressed the client code is executed,the file is brought from server and then when the questions have been solved,answers are submitted back

      Another query is when i open an frame from within an applet or frame,i want the former one to be destroyed.
      eg when student clicks on "start exam",anorther frame window opens showing "loading" and then questions in it,but the window from which this action started is needed no more,tried clling destroy,but no help

      Sir.i have sent you my codes too

      Comment

      • JosAH
        Recognized Expert MVP
        • Mar 2007
        • 11453

        #4
        You can certainly load data from the place where your Applet came from, you
        just can't read/write from/to the local filing system (your client's machin). Once
        you've read the data from the server simply keep it in memory and create
        Streams from there if you need to.

        kind regards,

        Jos

        ps. please don't send me source code nor technical questions through PM or
        my email; I don't read them there. You write here in the forums and I'll try to
        answer your questions here.

        Comment

        Working...