XLS/CSV

  • 31 Mar

    Csv to Xls conversion problems

    Q: Csv to Xls conversion problems. I have a small problem with the conversion of .csv to .xls files. My original file is separated by ; saved as .txt.

    • I also tried with a comma separated .csv and I get the same result.
    • I also tried to import full csv as text
    • I also tried adding a header
    • I still get the same result

    I have attached some screenshots, I have also attached the txt file to convert. My file contains data in French with accents, can this have an impact?

    A: It looks like a problem with the encoding of the txt file. We converted it to UTF8 first using a Pascal Script and afterwards the conversion worked just fine.

    1. Open the Pascal Script option:

    Limagito File Mover Pascal Script option

    2. Enable and add the following ‘On Destination’ Pascal Script. This will first change the Encoding of the Source txt file to UTF8. The conversion to XLS was ok afterwards.

    Var
      tmpFile: String;
    Begin
      psExitCode:= 0;
      // ... add your code here
      tmpFile := psFilePath + psFileName;
      If psChangeTxtEncoding(tmpFile, tmpFile, 0) Then
        psExitCode := 1;
    End.

    Limagito File Mover conversion problems

    More information about the “psChangeTxtEncoding function”:

    Use psChangeTxtEncoding to convert the encoding

    > Encoding possibilities:
    0: UTF8
    1: UTF7
    2: Unicode
    3: Default
    4: BigEndianUnicode
    5: ASCII
    6: ANSI
    7: ASCII TRIM
    8: ANSI TRIM

    i.e. psChangeTxtEncoding(psFilePath + psFileName, psFilePath + psFileName, 0);

    This script will change the encoding of the original source file before it is converted to .xls using XLS as Destination.

    Some extra screenshots of the XLS as Destination setup:

    Limagito File Mover conversion problems

    Limagito File Mover conversion problems

    #Filetransfer #csv #xls

    If you need any info about this ‘conversion problems’ issue, please let us know.

    Best regards,

    Limagito Team

  • 04 Apr

    Q&A 42: Remove quotation marks around the data in a csv file

    Q: Remove quotation marks around the data in a csv file. An Excel file is saved that has quotation marks around the data in the file. Which can be removed by opening Excel and re-saving as the CSV, but this is a manual step at this time. Would we be able to setup a Limagito rule to be able to do something similar for us?
    A: Yes this is possible using our XLS as Destination option. XLS as Destination also handles CSV files. Just be sure that the source files have .csv as extention so we know we need to handle them differently.

    Some screenshots to get you started:

    1.  Since we only want csv files, be sure the set the ‘Filename Include’ filter to *.csv in the ‘File Filter Setup’.

    Limagito File Mover filename inlcude filter

    2. We added XLS as Destination, XLS as Destination also handles CSV files. Just be sure that the source files have .csv as extention.

    Limagito File Mover XLS/CSV as Destination

    3. XLS.CSV as Destination setup. The Output File Format will be ‘Text, Delimiter separated values – with CRLF as End Of Line’.

    Limagito File Mover CSV Remove Quotation Marks

    Also ‘Text, Delimiter separated values – with LF as End Of Line’ which was added in version v2021.4.4.0

    This way you also can convert:

    • CSV with CRLF as Source to CSV with LF as end Of Line Destination
    • CSV with LF as Source to CSV with CRLF as end Of Line Destination

    Limagito File Mover CSV Remove Quotation Marks

    To remove the quotation marks you need to enable ‘Import full csv file as text’ option (Common Tab).

    Limagito File Mover import full csv file as text

    #FileTransfer

    If you need any help with this ‘Remove quotation marks’ request, please let us know.

    Happy Easter,

    Limagito Team

    By Limagito-Team Q&A XLS/CSV , , , ,
  • 12 Jul

    Q&A 20: I’d love the option to go the other way, csv to xls

    Q: It seems XLS as destination is meant to convert Xls as source file. I’d love the option to go the other way, csv to xls. Oh well, feature request.
    A: You are correct the original idea was to convert XLS files but on your request we added this feature request in version v2020.7.12.0

    We added some screenhosts to give you  an idea about the setup. The Source is a Windows folder:

    LimagitoX File Mover Windows Source Folder

    We added a file filter to only include *.txt and *.cvs files:

    LimagitoX File Mover File Filter

    As Destination we added our ‘Add XLS’ option:

    LimagitoX File Mover XLS as destination

    The Csv file that we are going to convert has a comma as delimiter. Our goal is to convert the Csv source file to a Xls file. We enabled ‘Change Extension’ and added .xls as ‘Extension’. File Format was set to ‘Xls, Excel 97-2000-XP-2003’.

    LimagitoX File Mover Csv To Xls optionResult:

    Limagito File Mover Csv to Xls log result

    If you need any help , please let us know.
    Regards,
    Limagito Team
    By Limagito-Team Q&A XLS/CSV ,
1 2 3 4 5
SEARCH