Convert File to binary or IWDResource

Hi,
I would like to bind the context of my webdynpro application to a .txt file.
The problem is that I can't convert from type File to type binary or IWDResource.
I have seen a lot of posts on it but no one works.
Could any one give me some help please ?
Thanks

Of course I can.
I create the file like this:
try {
               mailData = File.createTempFile("mailData", ".txt");
               mailData.deleteOnExit();
          } catch (IOException e3) {
               // TODO Auto-generated catch block
               logme("IOException : " + e3.getMessage());
I am developping a Web Dynpro DC as a callabe object. I would like to map this callable object to another one that is in charge to send a mail within the txt file attached. This is my business scenario. I know that I can send a mail directly through the web dynpro application but ti is not part of the business rules.
I cannot bind the txt file to the context, unless it is binary or IWDResource...
Thanks for your reply...

Similar Messages

  • Dos2unix doesn't convert some RDF files to BINARY...

    Hi,
    I have a peculiar issue with a couple of RDF's.
    My scripts copies all the files to a temp directory; move them to the relevant tops/paths and then do a "dos2unix" on the RDF and RTF files.
    Majority of the reports work fine when this is done.
    But this doesn't work fine for 2 RDFs.
    1) I have customized AR Customer Invoice program (RAXINV_SEL.rdf).
    Once i run the installation scripts, it copies everything and does a dos2unix on RDF and RTF files. I can see the custom RDF (XX_RAXINV_SEL.rdf) in $CUSTOM_TOP/reports/US directory.
    It doesn't even throw any error when i run the below command in the Custom_Top.
    [chundurk-DEV]/u01/oracle/EBSDEV/apps/apps_st/appl/xxabc/12.0.0/reports/US > dos2unix XX_RAXINV_SEL.rdf
    dos2unix: converting file XX_RAXINV_SEL.rdf to UNIX format ...
    [chundurk-DEV]/u01/oracle/EBSDEV/apps/apps_st/appl/xxabc/12.0.0/reports/US >
    But when i run the report, It thows the below error:
    REP-1070: Error while opening or saving a document.
    REP-0110: Unable to open file '/u01/oracle/EBSDEV/apps/apps_st/appl/xxbwp/12.0.0/reports/US/XX_RAXINV_SEL.rdf'.
    When i drag the RDF to $CUSTOM_TOP/reports/US in BINARY Mode using FTP, the report works perfectly fine.
    2) This is happening the same way for one of my custom reports too.
    We've developed about 50-60 reports and all of them work fine, except these 2 reports.
    Please suggest. Thanks in advance for your help.
    Regards,
    Kesava

    Gareth,
    Lets ignore the functionality of migration tool for now; its happening the same when i do it directly using SSH Secure Shell Unix & FTP tool.
    The steps i generally follow to migrate the reports are provided below:
    1. Logged in to SSH Secure Shell Unix & FTP tool.
    2. Created a temporary folder say 'reports' in /home/user directory.
    3. Drag all the report files to /home/user/reports directory in default mode i.e., ASCII (Migration tool ClearQuest also does the same).
    4. Then provide permissions on these files:
    chmod 755 *.*
    5. Run the shell Script:
    090xxbwp_inv_mov_apps.sh apps apps ghoord01:1521:EBSDEV.
    Shell script just has the commands shown below:
    1. cp -f 090XXBWP_INV_MOV.rdf $XXBWP_TOP/reports/US/XXBWP_INV_MOV.rdf
    cp -f 090XXBWP_INV_MOV.rtf XXBWP_INV_MOV.rtf
    2. FNDLOAD $1/$2 O Y UPLOAD $FND_TOP/patch/115/import/afcpprog.lct 090XXBWP_INV_MOV_CP.ldt - CUSTOM_MODE=FORCE
    FNDLOAD $1/$2 0 Y UPLOAD $XDO_TOP/patch/115/import/xdotmpl.lct 090XXBWP_INV_MOV_XML.ldt - CUSTOM_MODE=FORCE
    3. dos2unix $XXBWP_TOP/reports/US/XXBWP_INV_MOV.rdf
    dos2unix XXBWP_INV_MOV.rtf
    4. chmod 755 $XXBWP_TOP/reports/US/XXBWP_INV_MOV.rdf
    chmod 755 XXBWP_INV_MOV.rtf
    5. XDOLoader command to attach the RTF File to XML Template Skeleton.
    Once this is done; It works perfectly fine for all the reports (RDF's), except two of them.
    For the two reports that doesn't work; it thows the below error when the report is ran in APPS:
    REP-0110: Unable to open file 'XXBWP_INV_MOV.rdf'.
    REP-1070: Error while opening or saving a document.
    REP-0110: Unable to open file '/u01/oracle/EBSDEV/apps/apps_st/appl/xxbwp/12.0.0/reports/US/XXBWP_INV_MOV.rdf'.
    Workaround currently in Use:
    Transfer the RDF file manually in BINARY MODE to $XXBWP_TOP/reports/US directory and the issue is resolved.
    Request you to let me know if you can provide me with any permanant solution for this.
    Thanks,
    Kesava

  • How to convert PDF file into binary using APIs of Adobe Workflow server?

    I m using the Adobe Workflow Server 6.2. I want to write a web services to convert PDF file into binary and embed this binary data with XML.
    I want to use the APIs (or libraries) of Adobe Workflow server but dont know abt the APIs or Libraries that can convert the PDF file into binary format.
    I will be very thankful to u,if u can help me as i m n this prblm frm the last one week.I tried alot but could nt find the solution.
    waiting for a better response.

    check objectlibrary.pdf
    Dim o As New EPSDK.BinaryData
    o.LoadFromFile(sfilename)
    write o.Value to xml

  • Fm or method for converting  doc,pdf or text  files to binary format

    Hello,
    Are you aware of any function module or method which takes input as a file of type doc, pdf or text files and convert it to binary format? Kindly let me know.
    This is what i tried and was unsuccessful.
    i tried using gui_upload method and pass " asc" as file type while importing file of type .doc but it returns me string filled with strange characters.
    I did try converting this string to xstring using  cl_proxy_service=>cstring2xstring but i realized my 1st step of uploading file itself was wrong.
    Please let me know what can be done if you are aware of how to convert file of various types to binary.
    thanks
    Pooja

    hi All,
    thanks alot for the information and help provided by all of you.
    I did figure out a way where the word document or pdf  can be pretty much loaded with gui_upload. the file type used in the method would be "BIN" the following thing has to be done. declare data type as given below and file would be the complete path along with document name which has to be uploaded
    DATA: BEGIN OF res_line,
                raw(255) TYPE x,
             END   OF res_line.
      DATA: res_tab LIKE res_line OCCURS 0 WITH HEADER LINE.
    data :  wf_var_stringx TYPE xstring .
      CALL FUNCTION 'GUI_UPLOAD'
          EXPORTING
            filename                =  file
            filetype                = 'BIN'
            read_by_line            = 'X'
         has_field_separator     = ' '
         header_length           = 0
         header_line           = 'X'
          IMPORTING
            filelength              = l_filelength
          TABLES
            data_tab                = res_tab
          EXCEPTIONS
           OTHERS                  = 1.
    LOOP AT res_tab .
        CONCATENATE wf_var_stringx res_tab-raw INTO wf_var_stringx IN BYTE MODE.
      ENDLOOP.
    this will upload the file and will file the string x with its content.
    hope this helps to some of you.
    Thanks
    Pooja

  • Converting float to binary

    Hi,
    I was wondering if anyone knew of a way to convert a float value (as ascii) to a binary value?
    I need a program that will take in a number of floating values from a file, convert the values to binary and then write out these values in another file, 4 bytes at a time.
    I know that you can convert decimals to binary with an easy function but i've searched for float to binary and came up with nothing.
    any help would be really appreciated,
    cheers!

    One of the Java's problems is that you can easily get lost in the sea of Javadocs...
    java.io.DataOutputStream
    writeFloat(float v)
    Converts the float argument to an int using the floatToIntBits method in class Float, and then writes that int value to the underlying output stream as a 4-byte quantity, high byte first.
    java.io.DataInputStream
    readFloat
    public float readFloat()
    throws IOException
    Reads four input bytes and returns a float value. It does this by first constructing an int value in exactly the manner of the readInt method, then converting this int value to a float in exactly the manner of the method Float.intBitsToFloat. This method is suitable for reading bytes written by the writeFloat method of interface DataOutput.

  • How to convert image to binary format

    Hi all,
      We have developed an Employee search  mobile web application in .net which is hosted on an exposed IP server, we need to show the employee data along with the image of the employee on mobile.
    When we run this application through our desktop we are able to see the image of the employee since we are doing this through <b>intranet</b> , but when we try to access the same from any mobile device we are able to see only the data but no image, since we are doing this through <b>internet(exposed server).</b>
    Please suggest some way to get this image,
    is there any<b> function module in ABAP</b> which can <b>convert image to binary format</b>
    so that we <b>export binary data</b> to .net application

    Hei evryone!
    CAn anyone pls help me on how to solve this error:
    java.security.AccessControlException: access denied (java.security.SecurityPermission insertProvider.SunJCE)
         at java.security.AccessControlContext.checkPermission(Unknown Source)
         at java.security.AccessController.checkPermission(Unknown Source)
         at java.lang.SecurityManager.checkPermission(Unknown Source)
         at java.lang.SecurityManager.checkSecurityAccess(Unknown Source)
         at sun.plugin.security.ActivatorSecurityManager.checkSecurityAccess(Unknown Source)
         at java.security.Security.check(Unknown Source)
         at java.security.Security.insertProviderAt(Unknown Source)
         at java.security.Security.addProvider(Unknown Source)
         at CryptoTest.processFile(SwingApplet.java:68)
         at CryptoTest.<init>(SwingApplet.java:65)
         at SwingApplet.init(SwingApplet.java:39)
         at sun.applet.AppletPanel.run(Unknown Source)
         at java.lang.Thread.run(Unknown Source)
    Is it allright for a swing code to access local resources? like in my case i want my swing app to decrypt and encrypt an image file but when i tried to access the method for decrypting and encrypting i got this error message on my console. Do i have to make my code signed before i could write/read a file on my hard drive?
    Any help / suggestions would be much appreciated.Thanks!

  • Convert Excel to Binary

    Dear All,
    Has anyone experience convert excel to binary ?
    For example, I have an excel file in my PC then I would like to set it as attachment in mail using CL_DOCUMENT_BCS. Attachment in this class only have two version, as text or as hexadecimal.
    In order to create hexadecimal content I need a binary format, i will use function SCMS_BINARY_TO_XSTRING.
    The problem is, how to convert excel to binary format.
    Thanks in advance.
    Rgds,
    Deny

    code snippet .
    data: xml_tab1 type solix_tab .
    call function 'GUI_UPLOAD'
        exporting
          filename            = filename
          filetype            = 'BIN'
          has_field_separator = ' '
          header_length       = 0
        importing
          filelength          = size
        tables
          data_tab            = xml_tab1
        exceptions
          others              = 1.
    call method document->add_attachment
                exporting
                  i_attachment_type    = 'XLS'
                  i_attachment_subject = atta_sub
                  i_att_content_hex    = xml_tab1.

  • Convert tdms to binary

    How to convert large size ( > 500 MB) TDMS files to .binary or ascii..
    i found so many examples to do this using labview.. but my requirement is if there is no labview installed on my system then how can i convert and analyze the data from TDMS files..

    Make an executable and an installer out of the one that suits you! Then you can use it without LabVIEW, unless I'm missing something obvious!
    Also run a defrag on your file it helps.
    Beginner? Try LabVIEW Basics
    Sharing bits of code? Try Snippets or LAVA Code Capture Tool
    Have you tried Quick Drop?, Visit QD Community.

  • Using adobe on trial to convert word documents to pdf files...where are my converted files?

    where is my files that i converted ?? please advise.

    Hi nan7080,
    You can find your converted files by logging in to your account at cloud.acrobat.com using your Adobe ID and password.
    Please let us know if you have additional questions.
    Best,
    Sara

  • How can I access files from a flash drive that were previously saved using a Windows computer? When I attempt to open the file on MacBook Pro, it is asking to "convert file to"; I also have Microsoft Word installed on the Mac as well.

    How can I access files from a flash drive that were previously saved using a Windows computer? When I attempt to open the file on MacBook Pro, it is asking to "convert file to"; none of the options I choose work. I also have Microsoft Office (with Word) installed on the Mac as well.

    Format the external drive as FAT32 or ExFAT. Both computers will then be able to read and write to it.

  • Convert files

    how to convert file.class to file.java....if i have not the .java file

    Trying to reverse engineer someone else's work? or trying to recover your own code ;)
    Search for "java decompiler" on google or some other similar search tool.

  • I am trying to convert a file from pdf. I can't see it after I hit convert to word and view converted files. How do I know if I have a subscription? Adobe is on my mac dashboard.

    How do I tell if I have already paid for a membership? When I try to convert a pdf file to word, it looks like it is processing the task, but then I can't find the converted file when it says view converted file. Huh? Adobe is on my mac dashboard, I have had an account but can't see the results . . . thanks.

    Hi subscription question,
    I've checked your account; it looks like you tried to place two separate orders this morning, but it doesn't appear that either went through. However, it does sound as though you've been able to convert a file successfully. What happens when you log in to your account at https://cloud.acrobat.com/files? Do you see your converted file there? All converted files are automatically stored in your online account, even when you convert from within Reader.
    Best,
    Sara

  • Itunes is copying/converting 500gb of music from .wma to .m4a files that are on an external drive onto my laptop which doesnt have enough room. how do i reroute these newly converted files somewhere with enough space for them?

    itunes is copying/converting 500gb of music from .wma to .m4a files that are on an external drive onto my laptop which doesnt have enough room. how do i reroute these newly converted files somewhere with enough space for them?
    new to itunes, used windows media player before that and always ripped music directly to an external hardrive and accessed it through the player. now that i downloaded itunes it is taking from the external hardrive and copying a second file for each song onto my lap top hard drive which does not have the capacity for all my music. as itunes converts music files i want them saved back onto my external drive or another location i have space for rather than the lap top. how do i change the setting to move the itunes media folder to another location. assuming that hitting copy and past and dropping it in a random location will cause a few errors.

    When I have done this, all I did was network the two machines and copy the contents of the iTunes folder to the other machine, and that's it.
    My understanding (which may not be 100% correct) is that the one file that is absolutely necessary is iTunes Library, and that the XML file is actually a copy auto-generated from the iTunes Library, appearing in a different format only for non-iTunes apps that take advantage of the iTunes Library data.
    As far as I know, if you simply have the Library (database) file and all your original music files, iTunes on that computer should operate as it did on your old computer. I believe that the Album Artwork, Genius Data, and XML files can be regenerated from the Library file. Not sure about the Extras file.

  • I am trying to load new Cd's onto my iTunes in my Mac. But it comes up with cannot convert file? Please can someone help with something that should be so simple.

    I am trying to upload new CD's onto my iTunes account on my Mac but it coming up with cannot convert file.
    "You don't have access for your iTunes media folder or a folder within it. What do I need to do?

    Read the part about changing permissions on the iTunes folder in: https://discussions.apple.com/message/11583914

  • How do I know if a file is binary or not?

    Hi All,
    I am writing a simple program to scan the pattern of some ASCII files at some directory.
    However, I want to filter out all of the binary file. I wonder if there is any way to test if the file is binary or not.
    (note: can't use the file extension 'cause they could have the extension of the txt but still are binary file)
    Thank You.

    In general, you can't reliably.
    ASCII? My native language contains non-ASCII characters (8th bit set). I thank you not to consider my language "binary". There are buggy programs out there that do, and refuse to work correctly with my text files.
    There are character set encodings that have "escape characters" for multi-byte values. E.g. UTF-8 encodes non-ASCII characters as multi-byte entities that look like "binary data" when viewed byte-by-byte.
    The presence of NUL bytes might be a hint. Unless someone writes e.g. straight Unicode into a file; lots of NULs for ASCII text there.
    If you insist on writing xenophobic software, look for 8th bit set and characters less than space (excluding tab). And damn the furriners, they should all use English anyway.

Maybe you are looking for

  • Macbook Pro to Samsung LCD TV

    I'm trying to hook up a MacBook Pro to a Samsung LCD TV (Model: LE40A656A1FXXU) but when I connected it up the message on the screen was something along the lines of 'mode not supported'. Can someone tell me what I need to do? Currently I'm using the

  • Wrong language selection

    Hi, I have a hp laserjet MFP M476nw and I choosed wrong language, when I started to install the printer, and of all languages it was chineese and thats not so easy to understand . Can somebody help me, please? Maybe someway to restart...

  • How to enable Fast Previews while rendering?

    Hi,      Is there a way to enable Fast Previews option (Adaptive resolution) when the user tries to change custom effect parameters? I want the rendering to be fast. Thanks, Dheeraj.

  • Dynamic Checkbox Display, Insert, Update

    I have a form in which there are 70 checkboxes with different selections in it, currenlty each check box value is submitted to a different field in a database table. What I dould like is to retrieve those selections from a database table instead of h

  • Term cmd library/caches/rm -rfv * removed most docs folders

    Hi, I used advice on forum to clear cache, (posted by warwick teale} after loging back in most of my documents folders are deleted. Are they really gone or am I not finished the process. Not blaming him just posted the info for a reference to the pro