- adds soVisibleOnly to SaveOptions
- with soVisibleOnly saves only visible columns
- without (default) it works as before
Mailing lists / lazarus / 2012-10
Patch for Grids.pas - Adds soVisibleOnly to SaveOptions
4 messages · 2 people ·
- AAlexsander Rosa 3
- JJesus Reyes 1
Reply by email Subscribe to this list Your subscription
Read-only archive. Use j and k to move between messages.
- adds soVisibleOnly to SaveOptions - with soVisibleOnly saves only visible columns
-> without (default) it works as before
I think using some SaveOptions options only for XML and some only for CSV might cause confusion.
The problem with SaveOptions is that it's supposed to apply only to Save/LoadFromFile (I wish to have named SaveToCSVFile as ExportToCSVFile instead) visibility on CustomColumns should be preserved on saving/loading to/from a XML file (that by the way is missing), but it's ok to export only visble columns to ?CSV file. So what about adding yet another parameter to CSV functions?,
Even, if more features continue to be added to CSV support, it may be better to move the whole CSV support out of grids unit and create a component or something.
What you think.
Jesus Reyes A.
In that case, I would prefer to add another parameter to *SaveToCSVFile*: boolean "VisibleColumnsOnly" with default false.
The procedure *LoadFromCSVFile* requires no change, as the CSV does not have visibility information.
2012/10/16 Jesus Reyes
Show quoted text 25 lines
New approach.
2012/10/16 Alexsander Rosa
Show quoted text 6 lines
Atenciosamente,
Alexsander da Rosa
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.lazarus.freepascal.org/pipermail/lazarus/attachments/20121016/7a6c525f/attachment-0001.html> -------------- next part --------------
A non-text attachment was scrubbed...
Name: grids.patch
Type: application/octet-stream
Size: 3128 bytes
Desc: not available
URL: <http://lists.lazarus.freepascal.org/pipermail/lazarus/attachments/20121016/7a6c525f/attachment-0001.obj>
