I'm trying to use TCSVDocument,
I have:
Uses Math,sysutils,Classes,CSVReadWrite;
That seems to be fine,
But I get an error 1D.pas(18,17) Error: Identifier not found "TCSVDocument"
On a line:
Var
CSVData : TCSVDocument;
Do I need another unit or am I doing something wrong?
James
On 2022-02-07 13:20, James Richters via fpc-pascal wrote:
I'm trying to use TCSVDocument,
I have:
Uses Math,sysutils,Classes,CSVReadWrite;
That seems to be fine,
But I get an error 1D.pas(18,17) Error: Identifier not found
"TCSVDocument"
On a line:
Var
CSVData : TCSVDocument;
Do I n
Yes, that's it, thank you. I see it there on:
https://www.freepascal.org/daily/doc/fcl/csvdocument/tcsvdocument.html
Source position: csvdocument.pp line 59
For some reason I thought CSVReadWrite was the unit.
James
___
fpc-pascal maillist - fpc-pa
I have CSVDocument working, but something odd is happening.
Everything is coming out as I expect, Except for the first cell.. it has some
garbage at the beginning of it that I don't understand.
I'm on a Windows 10 64bit PC running the Win32 FPC Trunk installed today with
fpcdeluxe.
Here's my co
Hello,
Sounds like you have a BOM marker in the file.
Set
CSVDocument.DetectBOM := True;
Michael.
On Mon, 7 Feb 2022, James Richters via fpc-pascal wrote:
I have CSVDocument working, but something odd is happening.
Everything is coming out as I expect, Except for the first cell.. it has
I tried this:
CSVData:=TCSVDocument.Create;
CSVData.DetectBOM := True;
CSVData.LoadFromFile(ParamStr(1));
Writeln('Read In: ',CSVData.RowCount,' Rows and
',CSVData.MaxColCount,' Columns');
Writeln('Press Enter to Process')
On Mon, 7 Feb 2022, James Richters wrote:
I tried this:
CSVData:=TCSVDocument.Create;
CSVData.DetectBOM := True;
CSVData.LoadFromFile(ParamStr(1));
Writeln('Read In: ',CSVData.RowCount,' Rows and
',CSVData.MaxColCount,' Columns');
>Strange, I have it here ? Maybe it was introduced later...
Maybe I need to use another unit?
>Notepad++ detects the BOM Marker but obviously does not show it.
I even tried going to View and Show Symbol and Show All Characters in Notepadd
++ so I see all the CRs and LFs etc.. but nothing is show
On Mon, 7 Feb 2022, James Richters via fpc-pascal wrote:
Strange, I have it here ? Maybe it was introduced later...
Maybe I need to use another unit?
No. :-(
It exists on TCSVParser only, not on TCSVDocument.
That's a pity, because TCSVDocument should to pass it on to the TCSVParser.
I
>I have fixed this in trunk.
I updated to the current trunk and indeed your fix has solved the issue... for
excel files, however if I try it with a text file.. something that I type in
from scratch with a text editor, it crashes with:
Running "i:\programming\gcode\1d cut\1d.exe x:\text.CSV"
Inp
Thanks for the link and the work around idea.
I really don't know what settings I had for the CSV file, I just clicked
Save-As and changed it to CSV... I didn't even know there was an ASCII option.
The newer versions of Excel make you jump though hoops just to see where on
your hard drive you
On Mon, Feb 7, 2022 at 9:54 PM James Richters via fpc-pascal
wrote:
> The part of my program that checks for the BOM is bigger than the actual CSV
> read and write. Please let me know if the crash issue with no BOM gets fixed
> so I can delete all this stuff that checks for it.
That part can
12 matches
Mail list logo