" writing  data from  applet  to desktop "

dear friends,
plz help me on how to " write data from applet to desktop ".

http://java.sun.com/developer/technicalArticles/Security/Signed/

Similar Messages

  • Can one Sync select apps data from say a desktop G5 to a MBP?

    I was wondering if iSync has the ability to sync certain apps data between a traveling MBP laptop and my everyday home desktop G5?
    For example, I want to just sync very specific things like:
    -my Captain FTP data so I can keep FTP data current on my laptop as it is my desktop where I mess with it most
    -1Password data so my updated 1Password access data from my daily desktop can get sync'd over to a MBP
    -Entourage User Identity "database"
    these are just examples and I am not even sure iSync is designed to do this type of sync and, can you even select what it syncs?
    if not, any other ideas other than just manual slow carry-over via target Disk Mode.

    No, iSync is only for syncing Contacts and Calendars between Address Book / iCal and non-Apple mobile phones.
    Google "ChronoSync" for something that may do what you want.

  • How do you transfer data from an older desktop to a new one?

    How do you transfer data from and older desktop to a new one?  Appreciate any guidance you can provide.

    How to use Migration Assistant:
    http://support.apple.com/kb/HT4413?viewlocale=en_US
    http://support.apple.com/kb/TS1963
    Troubleshooting Firewire target disk mode:
    http://support.apple.com/kb/HT1661
    Migrating from PPC Macs to Intel Macs:
    https://discussions.apple.com/docs/DOC-2295
    http://support.apple.com/kb/HT4796

  • Need help in writing data from JSP to excel

    Hi ,
    I need help in writing the data from JSP to excel.I somehow able to retrieve the data into excel but unable to get the required format.
    For eg: The amount should be displayed in 0.00 format .when i am exporting it to excel it is displaying as 0 :( .
    I am using the following code in JSP.
    "out.print(amt + '\t');"
    Would like to know if there is any otherway where in i can get my requirement.
    Thanks
    Tom

    Hi,
    Try using format part of the JSTL tag libs.
    Syntax :
    <%@ taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt" %>
    <fmt:formatNumber value="40" pattern="$#,##0.00"/>
    I need help in writing the data from JSP to excel.I
    somehow able to retrieve the data into excelHow do u convert the jsp to excel?
    One way to convert the jsp page to excel, is to render it as an excel appl instead of html. Set the content type of the response to application/ms-excel.
    response.setContentType("application/ms-excel")Hope this Helps....

  • Writing data from Java to Excel

    Hi,
    I am trying to writhe data from Java to an Excel Sheet by using JACOB.
    This is my code :
    import java.util.*;
    import java.io.*;
    //import cost.util.*;
    import com.jacob.com.*;
    import com.jacob.activeX.*;
    class XLStock
         public static void main(String argv[])
              XLStock xls = new XLStock();
              xls.main2(argv);
         public void main2(String argv[])
              System.setSecurityManager(null);
              System.runFinalizersOnExit(true);
              Vector v = new Vector();
              XLSPutItem pi;
              String sheetfile = null;
              ActiveXComponent xl;
              Object xlo=null;
              Object workbooks;
              Object workbook;
              Object sheets;
              Variant vOptn = new Variant();
              vOptn.noParam();
              try
                   xl = new ActiveXComponent("Excel.Application");
                   xlo = xl.getObject();
                   Dispatch.put(xlo, "Visible", new Variant(true));
                   xl.setProperty("Visible", new Variant(true));
                   workbooks = xl.getProperty("Workbooks").toDispatch();
                   Variant vTemp = new Variant(argv[0]);
                   workbook = Dispatch.invoke(workbooks, "Open", Dispatch.Method,
                        new Variant[] {vTemp, vOptn, vOptn, vOptn, vOptn, vOptn, vOptn, vOptn, vOptn, vOptn, vOptn, vOptn, vOptn},
                        new int[1]).toDispatch();
                   sheets = Dispatch.get(workbook,"Sheets").toDispatch();
                   pi = new XLSPutItem();
                   if (pi.Parse("1:A1;ciao;6"))
                        v.addElement(pi);
                   for (int i=0; i<v.size(); i++)
                        pi = (XLSPutItem)v.elementAt(i);
                        pi.sheet = Dispatch.invoke(sheets, "Item", Dispatch.Get, new Object[] {new Variant(pi.sheetNumber)}, new int[1]).toDispatch();
                        pi.cell = Dispatch.invoke(pi.sheet, "Range", Dispatch.Get, new Object[] {pi.cellName}, new int[1]).toDispatch();
              catch (Exception e)
                   e.printStackTrace();
              pi = (XLSPutItem)v.firstElement();
              Dispatch.put(pi.cell, "Value", "ciao");
    What happen is that my code always fail at this line :
    xl = new ActiveXComponent("Excel.Application");
    whit this error :
    C:\VJWorks\JNI\jxls>java jxls.XLStock
    com.jacob.com.ComFailException: Can't co-create object
    at com.jacob.com.Dispatch.createInstance(Native Method)
    at com.jacob.com.Dispatch.<init>(Dispatch.java)
    at com.jacob.activeX.ActiveXComponent.<init>(ActiveXComponent.java)
    at jxls.XLStock.main2(XLStock.java:53)
    at jxls.XLStock.main(XLStock.java:28)
    Exception in thread "main" java.util.NoSuchElementException
    at java.util.Vector.firstElement(Vector.java:450)
    at jxls.XLStock.main2(XLStock.java:79)
    at jxls.XLStock.main(XLStock.java:28)
    I task that something is wrong in my system configuration.
    I work on a Win2000 platform and Office 97.
    Someone knows the reason of this error and can suggest what to make.
    Thanks in advance.
    Antonio M.

    Antonio, maybe you can post this back to the Jacob list. As an alternative to Jacob, what about Apache POI or writing the data as comma-delimited and opening the file using Runtime?
    Hope that may help.
    Good luck.

  • Download data from WDY to desktop

    hi,
    I am trying to dwn a itab data from the WDY application through a button using the below code:
    DATA lo_nd_cn_table TYPE REF TO if_wd_context_node.
      DATA lo_el_cn_table TYPE REF TO if_wd_context_element.
      DATA text           TYPE string.
      DATA xtext          TYPE xstring.
      DATA ls_cn_table    TYPE wd_this->element_node_1.
      DATA it_table       TYPE wd_this->elements_node_1.
      DATA wa_table       TYPE wd_this->element_node_1.
      navigate from <CONTEXT> to <CN_TABLE> via lead selection
      lo_nd_cn_table = wd_context->get_child_node( name = wd_this->wdctx_node_1 ).
      lo_nd_cn_table->get_static_attributes_table( IMPORTING table = it_table ).
      LOOP AT it_table INTO wa_table.
        CONCATENATE text
        wa_table-matnr
        wa_table-date
        cl_abap_char_utilities=>newline INTO text SEPARATED BY
        cl_abap_char_utilities=>horizontal_tab.
      ENDLOOP.
      CALL FUNCTION 'SCMS_STRING_TO_XSTRING'
        EXPORTING
          text   = text
        IMPORTING
          buffer = xtext.
      CALL METHOD cl_wd_runtime_services=>attach_file_to_response
        EXPORTING
          i_filename  = 'C:\Desktop\Vipin\FS\WDYNEW.txt'
          i_content   = xtext
          i_mime_type = 'TXT'
          i_in_new_window = abap_true
          i_inplace       = abap_true.
    but thru this code,I only see the data in a web page through a popup,its not saved on my system.
    if I am trying to use it for excel format i.e xls format,nothing is displayed,the popup comes & disappers immediately,the pop up with data only appers for TXT format.
    pls tell me how to solve this.I want to save the data

    Hi
    See I have 3 view,1st to upload data than 2nd for data display with button for download which take to 3rd view for confirmation for YES/No,if NO than back to view 2nd,if YES than it will download the data.
    So I have make the blank run of the application,with no data,than it shows me the pop up for download,but if there is data in view 2,it not shows the pop up & finishes the download action immediately,after allowing the IE pop up at the top,where it is suppose to display a full big pop up to specify the location & take confirmation for save.
    I hope now req clear.
    I am just wondering,why its showing the pop up to save when there is no data in 2nd view.
    redgs

  • Reading/Writing Data from a SQL Database

    Hi,
    I have a data structure called 'Quote' which contains a number of different variables and controls ranging from text boxes, check boxes and radio buttons, i need to be able to read and write this from a database.
    First I think a description of my overall project is needed:
    Project Description
    I have been given a brief that basically says: i have to create a programmed solution in VB to solve a problem. This problem can be anything we like, and I personally have chosen to create a program that manages quotes for building Log Cabins (this is very contrived and far from anything someone would do in the real world).
    My solution will allow a generic user to create a quote (using a form with controls such as text boxes, check boxes, radio buttons) , and then save this to file. These users may then wish to load/edit this quote at a later date, from another form.
    Whilst completing this project, i'll only have up to about 5 records (quotes) within the system, so i dont need the ability to store hundreds of records. And each record will be relatively short, with only about 10-15 data items within the data structure.
    Also the Admin (or business owner in this case) need to be able to view all saved quotes in a presentable format, and edit them if needs be, from within this same program.
    This solution does not need to be absolutely perfect and 100% efficiently coded, or have all the bells and whistles a real-world program would have. This is for an A level computing project by the way.
    So basically, i need to be able to read from the database (to populate a Data Grid (i imagine this is best way?)) and so Admin can access any quote and edit it (editing is not vital, but viewing/printing is. Maybe i should stop at just viewing any quote?). Also i need generic users to be able to fill in the Edit Quote form and then save this data into the database.
    And is a data structure really required for me to use a database?
    I've never used databases in VB before (but have used them elsewhere, mainly Access) and so am completely new to this. Any help will be much appreciated.
    Thanks

    this is just a dataset i created using the dataset designer.
    OK, so i have the dataset called "MyDataSet".
    I also have the following variables:
    Code Snippet
    Dim FloorSpace As Int32
    Dim NoOfBedrooms As Int32
    Dim NoOfBathrooms As Int32
    Dim EnSuites As Int32
    Dim LuxKitchen As Boolean
    Dim LuxCabin As Boolean
    Dim Flooring As Boolean
    Dim VoiceLighting As Boolean
    Dim SolarPanels As Boolean
    Dim IntegralSound As Boolean
    Dim WindowFrames As String
    Each of which relates directly to a column in the dataset (data type matches too).
    What i need to do now, is to save these variables as an additional record in MyDataSet. And then save MyDataSet to file, so it can be loaded again next time the program is run and more additional records added. (all files are local by the way).
    how would i go about this?

  • Writing Data from a Table to Excel

    Hi Experts
    I have a requirement to load data from an Oracle Table to an excel File. I was able to use OdiSqlUnload to achieve this, but the problem is I am not getting Header Information in my Excel. Please advise if there is any other method through which I can achieve this.
    Thanks

    Hi,
    Create a datastore in the file tecnology and make it delimited by ";".
    After that create an interface from table to it.
    In the IKM, you can chose to generate the header
    OR
    Use 2 OdiSqlUnload where the first just create the file and the header (a select column name from dual where column names are constants ) and the 2 append the real data
    Make any sense?

  • Writing data from a table to Excel file

    Hello friends,
    I am using Forms 5.0 on Windows NT. I need to write data from table A to Excel sheet from trigger 'when-botton-pressed'. Could you help me Any help will be appriciated.
    Thanks
    Charg
    null

    HERE IS THE CODE.
    YOU CAN RUN IT USING THE DEPT TABLE.
    PROCEDURE export_transaction_to_excel IS
    application ole2.obj_type;
    workbooks ole2.obj_type;
    workbook ole2.obj_type;
    worksheets ole2.obj_type;
    worksheet ole2.obj_type;
    cell ole2.obj_type;
    fdes varchar2(250);
    rowcounter number:=1;
    local_cursor_record number:=:system.cursor_record;
    old_cursor_style varchar2(100);
    errors_occured boolean:=false;
    ole_error exception;
    pragma exception_init(ole_error, -305500);
    my_alert_id alert;
    alert_respnse number;
    procedure place_value_in_cell(rownum_in in number,colnum_in in number,value_in in varchar2) is
    args ole2.list_type;
    begin
    args:=ole2.create_arglist;
    ole2.add_arg(args,rownum_in);
    ole2.add_arg(args,colnum_in);
    --cell:=ole2.invoke_obj(worksheet,'Cells',args);
    cell:=ole2.get_obj_property(worksheet,'Cells',args);
    ole2.destroy_arglist(args);
    ole2.set_property(cell,'Value',value_in);
    ole2.release_obj(cell);
    end place_value_in_cell;
    procedure savespreadsheet is
    args ole2.list_type;
    vDatestamp varchar2(20);
    begin
    fdes:='C:\TESTFORM.XLS';
    vDatestamp:=to_char(sysdate,'mmddyyyyy')&#0124; &#0124;'-'&#0124; &#0124;to_char(sysdate,'hh24miss');
    args:=ole2.create_arglist;
    ole2.add_arg(args,fdes);
    ole2.invoke(worksheet,'SaveAs',args);
    ole2.destroy_arglist(args);
    ole2.invoke(application,'Quit');
    end savespreadsheet;
    procedure open_excel_workbook is
    begin
    application:=ole2.create_obj('Excel.Application');
    workbooks:=ole2.get_obj_property(application,'Workbooks');
    workbook:=ole2.invoke_obj(workbooks,'Add');
    worksheets:=ole2.get_obj_property(application,'Worksheets');
    worksheet:=ole2.invoke_obj(worksheets,'Add');
    end open_excel_workbook;
    procedure write_column_header is
    begin
    place_value_in_cell(rowcounter,1,'Depart No');
    place_value_in_cell(rowcounter,2,'Depart Name');
    place_value_in_cell(rowcounter,3,'Loc');
    rowcounter:=rowcounter+1;
    end write_column_header;
    procedure export_the_data is
    original_receipt number;
    original_date date;
    original_transmital_number number;
    begin
    go_block('dept');
    first_record;
    loop
    place_value_in_cell(rowcounter,1,to_char(:deptno));
    place_value_in_cell(rowcounter,2,:dname);
    place_value_in_cell(rowcounter,3,:loc);
    exit when :system.last_record='TRUE';
    next_record;
    rowcounter:=rowcounter+1;
    end loop;
    end export_the_data;
    BEGIN
    begin
    old_cursor_style:=get_application_property(cursor_style);
    set_application_property(cursor_style,'BUSY');
    open_excel_workbook;
    write_column_header;
    export_the_data;
    exception
    when form_trigger_failure then
    raise;
    when ole_error then
    message('error sending data to excel');
    message(' ');
    errors_occured:=true;
    end;
    savespreadsheet;
    ole2.release_obj(worksheet);
    ole2.release_obj(worksheets);
    ole2.release_obj(workbook);
    ole2.release_obj(workbooks);
    ole2.release_obj(application);
    if not errors_occured then
    go_record(local_cursor_record);
    end if;
    set_application_property(cursor_style,old_cursor_style);
    END export_transaction_to_excel;

  • Writing data from array to file

    May i know how to write string from a array into a file.
    I have use string tokenizer to extract every line from a file using readline and use stringtokenizer to spilt the line using tab delimiter for processing.
    But if i want to write data from array to file with tab as a delimiter and how to go to the next line. How do i do that. Below is the task and i have state a simple example on a array i have and the file output that i want.
    Pls advice.. Thanks
    eg of a array
    array[0] = Data
    array[1] = One
    array[2] = Data
    array[3] = Two
    array[4] = Final
    array[5] = Data
    From the above array, i want to write to a file so that it will appear something as below
    Eg textfile.txt
    Data One
    Data Two
    Final Data
    PLs attached a simple code as a example as i am only begining to start useing the IO feature in java. Thanks

    Really thanks for your help,
    but u are mentioning that i have already know the number of countters in advance , that is to say the 2 * counters.
    But is there a way to solve this problem which i mean if i dun know the number of predefined counters. Maybe i should say, there is more than 2 counters and in another situation, the counters will only be defined during runtime. Actually the solution u give will work nicely with 2 counters. but wat if the counter is more than 4, i wll have to concatenate the string a lot of time. so is there any solution around this problem. That why i am wandering if tere is any solution to write to the file when the counters can be only determined in runtime
    Pls advice on the above with a code samples if possible.

  • Writing data from PLC to XLS file

    I am trying to write data from a PLC to an XLS file, i can write data when its generated, but wheni read from a DataSocket i cant seem to write it to the XLS file...
    i have attached what i've done please let me know what you think...
    any corrections and or suggestions are welcome..
    thanks,
    -U
    Attachments:
    WritingToXLS.zip ‏59 KB

    Hi,
    I wasn't able to see the diagram of your VI. What I suggest you do is to simplify the problem and make a VI which does not involve the OPC Server, for example. Simplify it to a point where the problem can still be reproduced. And then share the VI with us. We'll be in a better position to hel you then.
    Regards,
    Khalid

  • Writing data from labview to excel

    Hi, currently I'm trying to get an array of data from labview into a specific excel file everytime.
    The attachment i have is a program creating a new worksheet everytime it runs. I couldn't figure out how to make it work. Anyone can help me? 
    Attachments:
    Excel Copy Example.vi ‏19 KB

    So what is the specific problem? What is it doing that is incorrect? If the problem is that it is creating a new file every time its because the first subVI is opening a spreadsheet template file. Or at least I think it is since all of the subvis are missing...
    Mike...
    Certified Professional Instructor
    Certified LabVIEW Architect
    LabVIEW Champion
    "... after all, He's not a tame lion..."
    Be thinking ahead and mark your dance card for NI Week 2015 now: TS 6139 - Object Oriented First Steps

  • Writing data from a CSV file in to table

    Hi All,
    I have a CSV (Comma Separated Values) file and i want to write its data in to the table.
    How can i get data from a CSV file.

    As Karthick suggested, you can use External Tables or Sql Loader functionality
    You can check this link for example on Sql Loader http://surachartopun.com/2007/10/example-sql-loader-some-data-into.html

  • Sending different types of data from applet to servlet

    Hi,
    I am writing an applet that uploads a file to a servlet. I can send the file to the servlet just fine.
    Applet Side
    1. open a URLConnection
    2. open a DataOutputStream
    3. write the file to the DataOutputStream
    Servlet Side:
    1. open a ServletInputStream from the HttpServletRequest
    2. write the bytes to a file
    This is all fine.
    However, I need to upload the filename (a String) with the file. How do I do this? I can't send the filename over as a String from the applet using the same DataOutputStream. right? This would corrupt the file that i am sending as the servlet wouldn't know that the difference between the filename and the actual contents of the file.
    Is there some property I can set in the urlconnection that gets passed to the request variable? i.e. URLConnection.setProperty ("filename", foo.txt) and then on the servlet side do this: String filename = eq.getProperty ("filename")
    Thank you for the help

    If all the additional data you want to send to server are textual or numaric data about the file (which is in the body of the request)
    Use those information as additional http headers.
    And read those header information from the servlet request object at the server side
    ex:-
    URL u = new URL("your url");
    HttpURLConnection c = (HttpURLConnection)u.openConnection();
    c.addRequestProperty("x-application-file-name","name of the file");
    c.addRequestProperty("x-application-file-size","size of the file");
    //then open the stream and write the data to the request body
    //             At server side         //
    String name = request.getHeader("x-application-file-name");
    long size= Long.parseLong(request.getHeader("x-application-file-size"));

  • Sending data from applet to jsp

    hi all....
    i m very new in java so please and please spend ur few movement for this topic.
    i want to run a jsp page from within an applet and evantually want to send data to jsp.
    the data is an array of string object or may be a properties object,
    say String[] strarry={stringdata},or Properties props={setofkeysandvalues}
    the url of the jsp is http://8084/UASProject/Registrationform.jsp
    i have copied a code snippet from a topic posted in this forum.
    now please where should i formate in the code below to achieve this?
        try{
            URL appletURL = getCodeBase();
            String strHost = appletURL.getHost();
            String strPort = String.valueOf(appletURL.getPort());
            String strProtocol = appletURL.getProtocol();
            int portNumber = Integer.parseInt(strPort);
            String strwp ="/UASProject/Registrationform.jsp";
            //TCP port;
            URL jspURL = new URL(strProtocol,strHost,portNumber,strwp);
            URLConnection jspCon = jspURL.openConnection();
            jspCon.setUseCaches(false);
            jspCon.setDoOutput(true);
            jspCon.setDoInput(true);
            //jspCon.set
            ByteArrayOutputStream byteStream = new ByteArrayOutputStream(512);
            PrintWriter out = new PrintWriter(byteStream,true);
           // String postData= "?xmlText=" + URLEncoder.encode(genXml(),"UTF-8");
            //out.print(postData);
            out.flush();
            String strLength = String.valueOf(byteStream);
            jspCon.setRequestProperty("Content-Length",strLength);
            jspCon.setRequestProperty("Content-Type","application/x-www-form-urlencoded");
            byteStream.writeTo(jspCon.getOutputStream());
            URL tempURL = new URL(String.valueOf(jspURL));
            getAppletContext().showDocument(tempURL);
        }catch(Exception e)   {}please explain the line String postData= "?xmlText=" URLEncoder.encode(genXml(),"UTF-8");+ why it is written for??

    angilna_loves_java wrote:
    hi all....
    i m very new in java so please and please spend ur few movement for this topic.Huh?
    i want to run a jsp page from within an applet and evantually want to send data to jsp.Oh good lord, why?!
    the data is an array of string object or may be a properties object,
    say String[] strarry={stringdata},or Properties props={setofkeysandvalues}
    the url of the jsp is http://8084/UASProject/Registrationform.jsp
    i have copied a code snippet from a topic posted in this forum.
    now please where should i formate in the code below to achieve this?I recommend you get a better grasp on Java and JSP before you go any further. I'm not clear on what problem you're having or what error your getting either.
    >
    try{
    URL appletURL = getCodeBase();
    String strHost = appletURL.getHost();
    String strPort = String.valueOf(appletURL.getPort());
    String strProtocol = appletURL.getProtocol();
    int portNumber = Integer.parseInt(strPort);
    String strwp ="/UASProject/Registrationform.jsp";
    //TCP port;
    URL jspURL = new URL(strProtocol,strHost,portNumber,strwp);
    URLConnection jspCon = jspURL.openConnection();
    jspCon.setUseCaches(false);
    jspCon.setDoOutput(true);
    jspCon.setDoInput(true);
    //jspCon.set
    ByteArrayOutputStream byteStream = new ByteArrayOutputStream(512);
    PrintWriter out = new PrintWriter(byteStream,true);
    // String postData= "?xmlText=" + URLEncoder.encode(genXml(),"UTF-8");
    //out.print(postData);
    out.flush();
    String strLength = String.valueOf(byteStream);
    jspCon.setRequestProperty("Content-Length",strLength);
    jspCon.setRequestProperty("Content-Type","application/x-www-form-urlencoded");
    byteStream.writeTo(jspCon.getOutputStream());
    URL tempURL = new URL(String.valueOf(jspURL));
    getAppletContext().showDocument(tempURL);
    }catch(Exception e)   {}please explain the line String postData= "?xmlText=" URLEncoder.encode(genXml(),"UTF-8");+ why it is written for??Please read the API docs if you don't know what a particular method in Java does.

Maybe you are looking for