Regarding Converting file from UTF-8 encoding to ANSI

Hi Experts!
I have a problem that my given file is in encoding UTF-8 and i have to convert it into ANSI first so that i can use my bdc session to upload the file.
Kindly if you can help me out with that.If there is any fm available to do that.
thanks in advance
jawad

hi Jawad,
place the matter u want to convert in the c program given in the following link it will solve your problem
http://www.codeguru.com/forum/archive/index.php/t-288665.html
Reward if useful

Similar Messages

  • [svn:fx-trunk] 7661: Change from charset=iso-8859-1" to charset=utf-8" and save file with utf-8 encoding.

    Revision: 7661
    Author:   [email protected]
    Date:     2009-06-08 17:50:12 -0700 (Mon, 08 Jun 2009)
    Log Message:
    Change from charset=iso-8859-1" to charset=utf-8" and save file with utf-8 encoding.
    QA Notes:
    Doc Notes:
    Bugs: SDK-21636
    Reviewers: Corey
    Ticket Links:
        http://bugs.adobe.com/jira/browse/iso-8859
        http://bugs.adobe.com/jira/browse/utf-8
        http://bugs.adobe.com/jira/browse/utf-8
        http://bugs.adobe.com/jira/browse/SDK-21636
    Modified Paths:
        flex/sdk/trunk/templates/swfobject/index.template.html

    same problem here with wl8.1
    have you sold it and if yes, how?
    thanks

  • Any idea why my saved documents are unable to be read? "convert file from" box pops up, applications are listed to use but if any are chosen, the file then opens but is in symbols

    When attempting to open saved documents for viewing a box pops up "convert file from" with applications that can be chosen from to use. When any of the options are chosen the document then opens but is in symbols and is unreadable. This is happening with all saved documents.  Can you offer any help with this?

    Hi,
    If you don't find any clue, you can send your file to me (guillaume.rouyreATgcosiDOTcom, replace cap) so I can give a try.
    Hope this helps,
    Guillaume Rouyre, MBA, MCP, MCTS |

  • Converting file from a mac to pc?

    How do I convert files from a Mac to a PC

    Are you talking about Data files such as Microsoft Office etc? Picture files such as Jpegs?
    Depending on what you are talking about, you may not even need to convert them. Please provide specific details.
    Axel F.

  • "Convert file from:" error box

    Every time I click on a PDF file to download, the downloads window comes up and shows the download progress, and when the download finishes, a box appears that says "Convert File". In the box it says: Convert file from: then it lists various file types i.e., Text only, MS-DOS Text, Rich Text Format, HTML Document, Single File Web Page, Unicode Text and many more. It is trying to open a PDF file in Microsoft Word. I can't figure out how to change this. Help please?!

    That does not sound like Safari behavior. Are you using Safari to download, or another browser such as FireFox?
    Edit: Actually, I re-read what you wrote and saw that you said it was trying to open using MS Word. So I think the "convert file" message is coming from Word.
    Therefore, I think you have .pdf files currently set to open using MS Word. So after Safari completes the download, it is handing it off to MS Word to open, and MS Words is running and asking how to convert it to one of the formats Word supports.
    If the above sounds reasonable based on a lot of assumptions I made, you can try the following. First show any PDF file you already have in a Finder window. Right (Control) click on it, and select +Get Into+. In the Info window, look for +Open with+. In that section, if it currently set to open using Word, select either Preview (default setting) or +Adobe Reader+. Then, click the button below that setting that says +Change All+. This should change the setting so that all PDF files open with whatever app you selected that is not Word.

  • Does Adobe have a Home Use Program agreement with the U.S. Air Force so I can convert files from home?

    Does Adobe have a Home Use Program agreement with the U.S. Air Force so I can convert files from home?

    This may be helpful: Spanish PDF to Word in English

  • Convert files from Canon C300

    Hi,
    I want to convert files from Canon C300, but i can only import one by one file. Is it possible ti import all in the same time?
    The Canon C300 files are encapsulated, i just have access to MXF file when i open folder by folder.
    I'm in iMac, Yosemite.
    Thanks,
    Lise

    Thank you for the reply.  I have struggled with this problem for about 6 weeks.  Got bum information from both Canon and Adobe.  Grew discouraged.
    As a “test” after reading the discussion, I downloaded the trial version of Elements 10.  It contained RC 6.6, which would not do the S100.  I “updated”
    to 6.7 which finally did the job.  I’m really curious as to why the download of Elements 10 doesn’t “ship” with the latest RC?  I guess just to maintain
    confusion for as long as possible.
    Thanks again.  Only your reply enabled a final solution.
    Graden Harger
    Houston

  • Elements 9 w/ RAW converter 6.5 will not convert files from Canon S100.

    Elements 9 with upgraded RAW converter 6.5 will not download (or convert) files from my Canon S100.

    Thank you for the reply.  I have struggled with this problem for about 6 weeks.  Got bum information from both Canon and Adobe.  Grew discouraged.
    As a “test” after reading the discussion, I downloaded the trial version of Elements 10.  It contained RC 6.6, which would not do the S100.  I “updated”
    to 6.7 which finally did the job.  I’m really curious as to why the download of Elements 10 doesn’t “ship” with the latest RC?  I guess just to maintain
    confusion for as long as possible.
    Thanks again.  Only your reply enabled a final solution.
    Graden Harger
    Houston

  • CONVERSION FROM ANSI ENCODED FILE TO UTF-8 ENCODED FILE

    Hi All,
    I have some issues in conversion of ANSI encoded file to utf encoded file. let me tell you in detail
    I have installed the Language Support for Thai Language on My Operating System.
    now, when I open my notepad and add thai character on the file and save it as ansi encoding. it saves it perfectly and also I able to see it on opening the file again.
    This file need to be read by my application , store in database and should display thai character on jsp after fetching the data from database. Currently it is showing junk character on jsp reason being that my database (UTF8 compliant database) has junk data . it has junk data because my application is not able to read it correctly from the file.
    If I save the file with encoding as UTF 8 it works fine. but my business requirement is such that the file is system generated and by default it is encoded in ANSI format. so I need to do the conversion of encoding from ANSI to UTF8 . so Any of you can guide me on the same how to do this conversion ?
    Regards
    Gaurav Nigam

    Guessing the encoding of a text file by examining its contents is tricky at best, and should only be done as a last resort. If the file is auto-generated, I would first try reading it using the system default encoding. That's what you're doing whenever you read a file with a FileReader. If that doesn't work, try using an InputStreamReader and specifying a Thai encoding like TIS-620 or cp838 (I don't really know anything about Thai encodings; I just picked those out of a quick Google search). Once you've read the file correctly, you can write the text to a new file using an OutputStreamWriter and specifying UTF-8 as the encoding. It shouldn't really be necessary to transcode files like this, but without knowing a lot more about your situation, that's all I can suggest.
    As for native2ascii, it isn't for encoding conversions. All it does is replace each non-ASCII character with its six-character Unicode escape, so "voilá" becomes "voil\u00e1". In other words, it avoids the problem of character encodings by converting the file's contents to a form that can be stored as ASCII. It's mainly used for converting property or resource files to a form that can be read by the Properties and ResourceBundle classes.

  • Convert String from UTF-8 to IsoLatin1

    Hi everyone !
    I'm trying to convert a String from utf-8 to IsoLatin1, but i got somt problems.... I'm using
    actually this code, but it won't work...
    I'm getting a utf-8 html String with some data and i will write it down in latin1 to a text file
    String newString = new String(oldString.getBytes("UTF-8"), "ISO-8859-1");If i'm now writing this newString to a TextFile it contains cryptic signs like
    & # 1 3 ; or & # 1 3 7 ; or & # 1 2 8 ;(i separated this chars)
    can anyone tell me where is my fault and how can i solve this problem ?
    Thanks a lot
    Edited by: Sephiknight on Feb 23, 2008 2:41 AM

    Yes its XML, i got a web editor where i can add input (utf-8) and i want to write it down in my class to a xml file (isoLatin1).
    My code looks likte this
         public static void setEditFragment(String content, String xPath) throws Exception {
             DocumentBuilderFactory factory = DocumentBuilderFactory.newInstance();
             DocumentBuilder builder  = factory.newDocumentBuilder();
             Document document = builder.parse("3001300.xml");
             XPath xpath = XPathFactory.newInstance().newXPath();
             Node node = (Node)xpath.evaluate(xPath, document, XPathConstants.NODE);
            Charset charset = Charset.forName("ISO-8859-1");
            CharsetEncoder encoder = charset.newEncoder();    
            ByteBuffer buf = encoder.encode(CharBuffer.wrap(content));
            node.setTextContent(buf.toString()); 
               // Use a XSLT transformer for writing the new XML file
            Transformer transformer = TransformerFactory.newInstance().newTransformer();
             DOMSource        source = new DOMSource( document );
             FileOutputStream os     = new FileOutputStream("tmp.xml");
             StreamResult     result = new StreamResult( os );
             transformer.transform( source, result ); 
         }The example from http://www.exampledepot.com/egs/java.nio.charset/ConvertChar.html looks great, but if I add my own input string i get a exception that looks like this
    java.nio.charset.UnmappableCharacterException: Input length = 1
         at java.nio.charset.CoderResult.throwException(Unknown Source)
         at java.nio.charset.CharsetEncoder.encode(Unknown Source)
         at HagerAbs.setEditFragment(HagerAbs.java:91)
         at HagerAbs.main(HagerAbs.java:108)When i write my input to the xml file it doesnt look like xml at all, it looks more like
    <synthese>& # 13;
    & # 13;
    & lt;br/& gt;& # 13;
    & lt;img class="thumb" src="http: ......{code}
    (i seperated the char so you can see)
    and this is not what i expected... how can i write it down correctly ?
    Edited by: Sephiknight on Feb 23, 2008 3:26 AM                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       

  • Encoding from UTF-8 encoded String to Microsoft Project default encode

    Hi Expert ...
    I have a problem with encoding a String from UTF-8 String in order to write a MPX (Microsoft Project) file. I used UTF-8 on my Database encoding, and I want to write a MPX file using MPXJ library, but the result is (?) character. I think it's because I didn't encode yet to Shift JIS (a Microsoft Product default encoding). And after that I try to encode the String with Shift_JIS encoding, but the same result is appeared. I try to looking another way, but there is no result.
    I hope some expert would help me to solve this problem.
    Thank you,
    Alfian B.

    Totally wrong. A String doesn't have an encoding.
    Now if you had an array of bytes, which were encoded using one charset, and you wanted to convert that to an array of bytes encoded using a second charset, you would use code like this:byte[] bytes = // the bytes encoded in UTF-8, let's say
    String s = new String(bytes, "UTF-8"); // make that into a String
    byte[] newbytes = s.getBytes("windows-31j"); // encode the String into windows-31j

  • Can't save file in UTF-8 encoding

    Hi,
    I've read everything I can find on this subject, from these forums to Google to newsgroups. Still no success.
    I am simply trying to save a file in UTF-8 format.
    This code depicts the methods I'm using:
    File file = new File("myFile");
    FileOutputStream fos = new FileOutputStream(file);
    OutputStreamWriter osw = new OutputStreamWriter(fos, "UTF-8");
    System.out.println("Encoding is " + osw.getEncoding());
    osw.write(myStringBuffer.toString());
    When this code is run, this is printed:
    Encoding is UTF8
    However, when I check the output file itself, it is ANSI 1252. I've tried compiling and running in both 1.4.2 and 1.5.0. Same results.
    Thanks for your help...

    I have checked it with two separate tools.
    1. I have opened up the file in TextPad and viewed the file properties. TextPad reports this: "code set: ANSI"
    2. I have a command-line utility that is bundled with a 3rd party application (commercial search engine). The command-line utility reports the character set and the language of a text file. The command-line utility reports this: "CHARSET: 1252"
    Is there something else to try?

  • How can I convert files from pages 08 files without pages 09?

    I am extremely dissatisfied with the latest iWork (13?) applications. My 2008 MacbookPro crashed on me, so I purchased a new 15" MacbookPro last month. Due to a known issue that prohibits my new Mac from being restored from my Time Capsule backup (thanks, Apple...), we finally got it worked out so that all my files were restored, but I had to reinstall my applications as I could find them. I had iWork 09 on my old machine, but it was from a family pack years ago, for which I do not have the discs. So, now I don't have Pages 09 to convert all my older files (I had no legitimate reason to convert my graduate work from 08 because it all worked in '08 and '09) so that I can open all my .pages files in Pages. Why would Apple make Pages that cannot open .pages files?! This is quite frustrating, and I'm hoping someone has an answer for how to convert .pages files from iWork '08 so that I can open them in the latest Pages without having to purchase iWork '09 (AGAIN!). Apple is really ramping up its leaving people behind...

    Those are your choices.
    Buy iWork '09 which is a good solution or somehow reinstall Pages '08 so you can export to Word .doc/x files.
    We warned long and hard that not updating to Pages '09 would eventually lead to Pages '08 being left behind, although Apple was particularly ruthless the way it finally did it.
    Also that anything using Apple's proprietary formats is going to end up with the same fate.
    Peter

  • How can I move back the rman convert file from file system to ASM?

    I have no idea on pluging-in the data files which were unloaded as follows:
    SQL> alter tablespace P_CDDH_DSPGD_V1_2011 read only;
    SQL> alter tablespace P_IDX_CDDH_DSPGD_V1_2011 read only;
    SQL> exec dbms_tts.transport_set_check('P_CDDH_DSPGD_V1_2011,P_IDX_CDDH_DSPGD_V1_2011',true);
    SQL> select * from transport_set_violations;
    UNIX> expdp tossadm@pmscdhf1 dumpfile=ttsfy1.dmp directory=trans_dir transport_tablespaces = P_CDDH_DSPGD_V1_2011,P_IDX_CDDH_DSPGD_V1_2011
    RMAN> convert tablespace P_CDDH_DSPGD_V1_2011, P_IDX_CDDH_DSPGD_V1_2011 format = '/appl/oem/backup/temp/%I_%s_%t_extbspace.dbf';
    Starting conversion at source at 03-OCT-13
    using target database control file instead of recovery catalog
    allocated channel: ORA_DISK_1
    channel ORA_DISK_1: SID=116 instance=pmscdhf11 device type=DISK
    channel ORA_DISK_1: starting datafile conversion
    input datafile file number=00079 name=+PMSCDHF1/p_cddh_dspgd_v1_2011_01.dbf
    converted datafile=/appl/oem/backup/temp/3536350174_2820_827849001_extbspace.dbf
    channel ORA_DISK_1: datafile conversion complete, elapsed time: 00:02:15
    channel ORA_DISK_1: starting datafile conversion
    input datafile file number=00080 name=+PMSCDHF1/p_idx_cddh_dspgd_v1_2011_02.dbf
    converted datafile=/appl/oem/backup/temp/3536350174_2821_827849136_extbspace.dbf
    channel ORA_DISK_1: datafile conversion complete, elapsed time: 00:01:45
    Finished conversion at source at 03-OCT-13
    Starting Control File Autobackup at 03-OCT-13
    piece handle=/dbms/oracle/r1110/db_01/dbs/c-3536350174-20131003-02 comment=NONE
    Finished Control File Autobackup at 03-OCT-13
    SQL> drop tablespace P_CDDH_DSPGD_V1_2011 including contents;
    SQL> drop tablespace P_IDX_CDDH_DSPGD_V1_2011 including contents;
    Afterward, how can I relocate the backup files "/appl/oem/backup/temp/3536350174_2820_827849001_extbspace.dbf", "/appl/oem/backup/temp/3536350174_2821_827849136_extbspace.dbf" back to the ASM group +PMSCDHF1 ???

    The 11.1 documentation only says  "Enables you to copy files between ASM disk groups on local instances to and from remote instances" and "You can also use this command to copy files from ASM disk groups to the operating system."
    http://docs.oracle.com/cd/B28359_01/server.111/b31107/asm_util.htm#CHDJEIEA
    The 11.2 documentation says "Copy files from a disk group to the operating system  Copy files from a disk group to a disk group Copy files from the operating system to a disk group"
    http://docs.oracle.com/cd/E11882_01/server.112/e18951/asm_util003.htm#CHDJEIEA
    I've never tried 11.1
    Hemant K Chitale

  • Export SQL View to Flat File with UTF-8 Encoding

    I've setup a package in SSIS to export a SQL view to a flat file and it's working fine.  I now need to make that flat file UTF-8 encoded.  The package executes but still shows the files as ANSI encoded.
    My package consists of a Source (SQL View) -> Derived Column (casts the fields to DT_WSTR) -> Destination Flat File (Set to output UTF-8 file).
    I don't get any errors to help me troubleshoot further.  I'm running SQL Server 2005 SP2.

    Unless there is a Byte-Order-Marker (BOM - hex file prefix: EF BB BF) at the beginning of the file, and unless your data contains non-ASCII characters, I'm unsure there is a technical difference in the files, Paul.
    That is, even if the file is "encoded" UTF-8, if your data is only ASCII values (decimal values 0-127, hex 00-7F), UTF-8 doesn't really serve a purpose over ANSI encoding.  Now if you're looking for UTF-8 with specifically the BOM included, and your data is all standard ASCII, the Flat File Connection Manager can't do that, it seems.
    What the flat file connection manager is doing correctly though, is encoding values that are over decimal 127/hex 7F in UTF-8 when the encoding of the connection manager is set to 65001 (UTF-8).
    Example:
    Input data built with a script component as a source (code at the bottom of this post) and with only one WSTR output column hooked to a flat file destination component:
    a string containing only decimal value 225 (german Eszett character - ß)
    Encoding set to ANSI 1252 looks like:
    E1 0D 0A (which is the ANSI encoding of the decimal character value 225 (E1) and a CR-LF (0D 0A)
    Encoding set to UTF-8 65001 looks like:
    C3 A1 0D 0A  (which is the UTF-8 encoding of the decimal character value 225 (C3 A1) and a CR-LF (0D 0A)
    Note that for values over decimal 127, UTF-8 takes at least two bytes and up to four for the remaining values available.
    So, I'm comfortable now, after sitting down and going through this, that the flat file connection manager is working correctly, unless you need a BOM.
    1
    Imports System  
    2
    Imports System.Data  
    3
    Imports System.Math  
    4
    Imports Microsoft.SqlServer.Dts.Pipeline.Wrapper  
    5
    Imports Microsoft.SqlServer.Dts.Runtime.Wrapper  
    6
    7
    Public Class ScriptMain  
    8
        Inherits UserComponent  
    9
    10
        Public Overrides Sub CreateNewOutputRows()  
    11
            Output0Buffer.AddRow()  
    12
            Output0Buffer.col1 = ChrW(225)  
    13
        End Sub 
    14
    15
    End Class 
    Phil

Maybe you are looking for

  • Calling a batch file from PL/SQL

    Is there a way to call a windows batch file from within a stored program in Oracle? I need to check for error records in a table and if exists, I would like to call a batch file that invokes mail server and sends an error notification to a designated

  • Adobe acrobat xI pro download issue

    When double clicking this file, I get the error message "The version of this file is not compatible with the version of of Windows that you are running. Determine the version of Windows, 32 bit or 64 bit, and contact the software supplier for the cor

  • In SAP-BW what is ROOT Analysis?

    what are the steps to be followd in root analysis? thanx. siva

  • Recover files like u01 u02 and so on

    I don't know if this is the right forum but this is what i got: dbs - folder oradata - folder pfile - folder u02 - folder u03 - folder u04 - folder u05 - folder u06 - folder u07 - folder u08 - folder listener.ora - file oraenv2 - file rman recovery.d

  • New version crashes my comp!

    Itunes NEW VERSION gives me bluescreens and crashed my computer now.. WHY?