Save and retrive attachment

Dear Users,
I am working on Query management system in ESS wherein user is expected to attach some document for their queries and then HR will access the same attachment in respective view to solve the query.
I am using Content Server right now to save documents as KM is not implemented here.
Kindly guide me how to do it
Thanks in Advance
Lalit

Hi Kayaman Thanks you for replying me to my question
This is my source part and the way i'm writting the content to new GIF
image.
It does not create the new image it goes inside to the if and print
first string which i have include to test.
1)How to read and write a GIF can we do that using byte array
if (attachment.getContentType().equals("image/gif")) {
p2.println("inside image gif");
ByteArrayInputStream contentStream = (ByteArrayInputStream)attachment.getContent();
// use standard Java I/O methods to save in file
int bytesToRead = contentStream.available();
p2.println("bytesToRead"+bytesToRead);
byte[] buffer = new byte[bytesToRead];
p2.println("about to erad");
contentStream.read(buffer);
// write buffer to new file
p2.println("read everything");
FileOutputStream file = new FileOutputStream("C:/form.gif");
file.write(buffer);
p2.println("created");
file.close();
p2.println(" with type " + attachment.getContentType() + " written to form.GIF");
}else {
p2.println("attachment content has MIME type " +
attachment.getContentType() + ", Java type " +
attachment.getContent().getClass());
Thank you again
Nelu

Similar Messages

  • Save and File Attachment usage rights for adobe reader

    With Acrobat Pro is there any way to save a pdf that has both save usage rights and file attachment usage rights?
    It seems that if I save the pdf with save the form data usage rights then I can no longer use createDataObject or setDataObjectContents methods when viewing with adobe reader or acrobat.
    createDataObject and setDataObjectContents require 'File Attachment' usage rights, which from the behavior I am getting totally disjoint from the save usage rights.
    I have no trouble using submitForm method with save usage rights applied to the pdf.

    Thanks for the replies, I also want to verify that a pdf created with acrobat that uses createDataObject or setDataObjectContents will no longer function properly in acrobat after saving the pdf with the additional usage permissions.  Is there any documentation that points to what  functions are crippled by saving the pdf with the various choices of  extensions enabled?  It seems as if I save the pdf with any type of extended usage rights for reader, then the pdf functions as if it was opened by adobe reader even if I have it open in acrobat?

  • How to save and retrive XML DOM to/from SQLServer

    Hi, there,
    I am new to JAVA, and now I'm trying to save a large XML DOM to SQLServer, and retrive it as a XML DOM later. Would someone please let me know how can I do it?
    Thanks!
    ----YM

    You would be better looking at the XML DOM documentation for your database rather than asking here. If your DB doesn't provide XML facilities, then there are products and techniques that can be applied to map XML to SQL, and you can always serialize the java objects into a blob, but XML to SQL mapping isn't standardized, so the first call is the server's documentation.

  • How to save and retrive table column values added via view enhancement

    Hi,
    I want to enhance standard webdynpro component FITE_VC_REVIEW.
    I want to add new column to Fight Info Table and also to Hotel Info table.I can do UI changes via view enhancement .
    First Approach: I add new fields to Flight Info and Hotel Info structure.
    Create an additional Coolum in Flight Info and Hotel Info Table and Bind it to newly created field in structures.
    Question :
    What all changes I have to make to save and retrieve values from database table.
    Kindly guide with Steps
    Second Approach: I create a new table/structure for my requirement and bind table column to these fields.
    Question:
    What all changes I have to make to save and retrieve values from database table.
    Kindly guide with Steps
    And which approach will be good.
    Regards,
    Madhvika

    no ans yet

  • Problem choose method for save and retrive data

    Hi
    I want to conver sql database to berkeley db.my sql database has over that 40 tables and each table has diffrent fields (like varchar,int,...)and some tables have over that 30 fields .I want to use method that berkeleydbcorec pdf explain in chapter 3(Using C Structures with DB):
    what is the limitation for use first method for store information?
    I think only limitation is waste database.
    what are the advantages of use (marshalling the data)?
    if I use marshalling the data for store records does speed for fetch information reduce or not?
    is it good use marsharling or first method for store information?
    please help me.
    regards,
    saaed

    Hi,
    Since nobody else has posted anything I thought I would mention a couple of things:
    Most applications that need a database need a way to work with records and fields. Berkeley DB does not have a schema so it is up to the application to format the data. Some databases through their DML make it easy to the application to look at fields but they are doing work for you behind the scenes.
    Some dbms's if they support variable length fields store some information on the page to delimit fields. At run time there is some overhead in doing that as the dbmx needs to find the location on the page for the next field and so forth. So although the application may not have to write the code to obtain fields from records there still is the overhead in the database to do so.
    As you noted in Berkeley DB, you do the marshalling and unmarshalling of data. Since you know your data best, you can optimize it as you see fit.
    Perhaps you should try this on one table first and see what the performance is.
    I hope this helps.
    Ron

  • On ipad app, i add a signature and then save and email, but the attachments never comes through on the email. Help??

    So I add a signature on the ipad, save and then attach to an email and send. The attachment never comes through. I have tried multiple email addresses. Help? I also tried saving to my docs on adobe.com and then logging in on a computer to retrieve and print, but thats not showing up either.

    Thank you.  That is very useful information!
    We would like to investigate the problem further and fix it.  If it's OK with you, we would also like to collect more information so that we can reproduce the problem at our end.
    What is the iOS version?
    What is the version of your Adobe Reader?
    What is the mail app that you use to read and open email messages and attachments?
    Does the problem occur with any PDF documents (for both cases: with or without a signature)?  Or just a particular PDF document?
    Would you send the original PDF document (without a signature) that exhibits the problem as an email attachment to [email protected]?  Please include the link to this forum post (https://forums.adobe.com/thread/1520043) in your email message for reference.
    Thank you for your help!

  • How do I save and manipulate an attached document through gmail?

    How do I save and manipulate an attached document through gmail on my iPhone?

    I had a client that had hundreds of session variables
    scattered in hundreds of CF pages. There was very little CFLOCKing,
    and consequently the apps were quite unstable in a loaded
    environment.
    What I finally did was to copy the session scope variables to
    ses.request scope variables of the same name, then did a global
    replace of session. with ses.request. In OnRequestEnd.cfm, and
    immediately before all CFLOCATIONs, I copied ths ses.request scope
    back to session scope (locked, of course). There was no measurable
    performance hit, and the apps were rock solid.
    Perhaps you could copy your client variables to session
    scope; then back again in OnRequestEnd.cfm

  • Infopath 2010 Save and Send does not attach .xsn file

    Hello all, last year we had departments using the "Save and Send" to send their filler forms to a mail box, since that time we have upgraded from 2007 to 2010 InfoPath. Now when the Save and Send feature is used just the xml file is attached?
    Any help? thanks

    after a little discovery, my biggest problem is I have InfoPath 2010 and Outlook 2013.  On a machine with IP 2010 and Outlook 2010 I tested and found only "Restricted" forms allow the template to be sent using Save and Send. 
    This setting is in the Options/Security and trust. 
    As long as you have Options/Email attachments set to Form and template + Options/Security and trust set to restricted + matching versions of outlook and InfoPath it works fine.  This was nothing more than user error on my part

  • Problem with storing and retriving a different langauge font in mysql

    hi,
    i have problem with storing and retriving a different character set in
    mysql database ( for example storing kannada font text in database)
    it simply store what ever typed in JTextField in database in the
    formate ??????????? and it showing ???????? .
    please what can i do this problem.
    thanks
    daya

    MySQL does not know about what type of Font you use or store. that is applicatioon specific. All it knows is the character set that you are storing and the data type and data. THere are something you should know when working with database and Java:
    1. make sure you know what character set is used for the database table.
    2. make sure you know what character set is used by Java (default to UTF-8 ..
    sort off - there are few character that it cannot save). You can enforce the
    character set being sent to the database by the String's getBytes(String charsetName) method.
    3. make sure the application you use to view the table use the correct character set
    if it use a different character set, then any character that it does not recogized
    will be replaced with a quetion mark '?'....eventhough the data is correct.

  • Can I save and open an attachemnt at the same time?

    I want to be able to open an email with an attachement or attachments and click on the save button for the attachment(s), designate the location (folder) where they are to be saved - but also tell Mail to save the attachments then open them up on the desktop. Two operations in one. If you understand my request you understand what you have to do now - two separate steps. Save. Then find the saved files and open them.
    OR
    Open the attachment from the email which then downloads the file to your designated "all-purpose" location (not the ultimate location you'd want to save it). Then once you've seen it, you do the save thing with the original mail attachment and then have to go back and delete the file from the designated all-purpose download location.
    This latter problem of having to delete unedited downloads manually could be solved with an option in Mail preferences to automatically delete unedited downloads in the "all-purpose" location after that same attachment had been downloaded to another specific location on your hard drive. This option for deleting unedited downloads does not exist, however.
    But even if this step-saver option existed in the preferences, you still would not be able to tell your Mac to save a particular Mail email attachment to a particular folder AND open that attachment at the same time in one command.
    That's what I want.
    Maybe I want both. Save and open together plus the ability to automatically delete unedited attachment downloads in the "all-purpose" download file after the same attachment has been downloaded to another specific location on your hard drive.

    with IOS 6 yes you will be able to do that

  • Mail 3.6 (on MacOS 10.5.7) doesn't display 'Save' and 'Quick Look' buttons

    I have recently updated to MacOS 10.5.7 and discovered a strange glitch in viewing certain emails with attachments. For a small minority of emails with attachments, the 'paperclip' icon appears in the mail list, indicating the presence of an attachment, but neither the icon for the attachment nor the 'save' and 'quick look' buttons appear. Options to save the attachment or quick look the attachment under the File menu do work.
    Clearly the attachment is there but Apple Mail 3.6 doesn't know how to indicate it. This inconsistency in the interface's feedback about attachments has been very irritating.
    Remedies I have attempted thus far:
    • Rebuilding the mail box (no change)
    • Disabling all Mail extensions (bundles)
    • Examining the raw mail code (nothing obvious wrong, but I am not an expert).
    The problem is currently present for some Microsoft Word file attachments, but I have no clue if it is limited to just those attachments.
    I will note the latest email with this failure to display attachments was sent by a colleague using Apple Mail on an iPod Touch, so I can't believe it is a mangled attachment. It is not limited to a single sender, so again, no reason to believe mangled attachments.
    I would really appreciate any suggestions for how to fix this...

    I disabled the mail extensions by removing them from the ~/Library/Mail/Bundles/ directory. I didn't think the mail extensions could get patched into Mail.app by any other means, but if you care to clarify I would appreciate it.

  • I want to store an image in R3 table and retrive it

    Hi,
    i want to store an image in R3 table and retrive it from my function module.
    Can any one tell me what is the step by step procedure to do that.
    I am new to ABAP.
    Regards,
    H.V.Swathi

    Dear Swethi,
    You can move images to SAP using SE78. then u can use them where ever u you require them.
    SE78->GRAPHICS->BMAP here give ur image name and click on save
    Rgds,
    Kiran
    Edited by: Kiran on Jun 11, 2009 7:15 AM

  • Save and load jtree

    Hi,
    I have a jtree which I would like to save and then load and display in a JPanel. Just for info, the nodes of the tree are instances of a user object i have created. Now I have looked into two ways of doing this:
    1) Serialize the actual JTree object; write it to a file using objectoutputstream and then read it in using objectinputstream, OR
    2) Serialize the tree model again using objectoutputstream then read the model back and create a new JTree initialising with the model i read in.
    I made some progress using the second approach, but when I load the tree model back and create a new tree with that model it just displays as a blank root with blank children. (Although the tree structure is the same).
    What am i doing wrong?
    The code is:
    public void saveTheTree() {
            TreeModel tm = tree1.getModel();
            try {
                 ObjectOutputStream out = new ObjectOutputStream(new FileOutputStream("treeModel"));
                 out.writeObject(tm);//the actual tree object
                 out.flush();
                 out.close();
            catch(IOException e){}
      public void openTheTree() {
           ObjectInputStream in = null;
             try {
                 in = new ObjectInputStream(new FileInputStream("treeModel"));
                 TreeModel atm = (TreeModel) in.readObject();
                 JTree loaded = new JTree(atm);
                 abPanel3.removeAll();
                 abPanel3.revalidate();
                 abPanel3.add(loaded, BorderLayout.CENTER);
                 abPanel3.revalidate();
             catch(Exception e) {
                  e.printStackTrace();
      }abPanel3 is where the tree is displayed and tree1 is my tree.
    Any help would be much appreciated!

    well the leaves are defaultmutabletreenodes instantiated with a user object which attaches a link and level to each one. According to the java documentation, defaultmutabletreenode is serializable, but do i need to serialize each node of the tree as well?
    Has anyone managed to save and load a jtree before?
    Thanks.

  • Eprocurement Requisition upon "save and preview Approval"

    Hi,
    We have implemented eprocurement module 9.0 ver and found a strange problem.
    After creating a requisition,while we click the button -"Save and preview Approvals" it shows the approval path.
    If we happen to edit the requisition twice or thrice and again click the button-"Save and preview Approvals" its not showing the approval path.
    would like to know:
    1>if the changes to the requisition are saved ?
    2>Why is there no approval path on clicking button--"Save and preview Approvals" after we edit a requisition more than twice ?
    is it a delivered bug?
    Thanks.

    No problem Niesa. When you do get permission to post a screen image use the camera toolbar icon as indicated below. It is much quicker as the attachment method has to be moderated before we can see it.
    Incidently we found that the only way around this was to rearrange the content inside the d-d.
    Read the RoboColum(n) for a tips, tricks and musings on the Technical Communication Suite products.

  • Is there a simple way to save and open attachments?

    When I save an attachment in mail, I have to hit save, navigate to the place to save, say OK, then to open it, I have to open a finder window, navigate (again) to the place, and open it. Because we have a very deep directory structure on our corporate drive, it takes like 20 seconds to do this every time I want to save an attachment. Isn't there an easier way to do this?
    SUGGESTION TO APPLE: why not put a button on the Save dialog that says "Save and Open".

    Just click on the attachment to open it, then if it's worth saving, press Save As...
    In the save window, you will see a list of recent places and if your lucky, one shows up that is on the mark and you can select it directly.

Maybe you are looking for

  • Enhancement points option: Function modules or BADI

    Hi, I am on ECC 6.0 and I need to validate and set some requirement in customer sales area data when user input the document output message in Documents tab strip screen 7003 of sapmf02d  in transaction XD01 or XD02.   I found that there is function

  • Ipod touch 3rd Gen Still Making G4 Crash

    I thought we had corrected this issue but it has not been corrected. Have a G4 Mac 733 Mhz running 10.4.11 When Ipod Touch 3rd Gen is plugged into usb hub that is separately powered by its own brick the computer locks up. Everything just freezes up..

  • Can't print from macbook pro to hp deskjet 3054

    I have tried what hp says to do on there website to get my printer to print but it is not working. It worked once and I went to print again and nothing happened. So i have no idea what to do. Should I go out and buy a new printer. Please help.

  • Can't Get Menus to show on DVDSP 4.2

    I have loaded DVD Studio Pro 4.2.  It opens just fine but the menus will not show in the pallette.  They are in the folder in the usr/library/application support/dvdstudio pro. What am I missing.  Never had a problem before. Thank you.

  • How do i get SharePoint list as a data source in visual studio 2013

    In word add-in application,i have added the tree view as a custom pane.Now i wanted to load tree view from share point list.Could you please help to load sharepoint list from Visual Studio.