XML for spreadsheets
Moderator: Rathinagiri
XML for spreadsheets
Hello All,
I want to export my data in XML format, so that it can be opened with any modern spreadsheet. Is there any easy way to do this? Or I shall write all the XML codes ...
Is there any utility which can export DBF to XML? Or Grid to XML
Thanks in advance
(After 15 minutes: IMHO, it is not very complex to write code for DBF2XML, I shall do it )
I want to export my data in XML format, so that it can be opened with any modern spreadsheet. Is there any easy way to do this? Or I shall write all the XML codes ...
Is there any utility which can export DBF to XML? Or Grid to XML
Thanks in advance
(After 15 minutes: IMHO, it is not very complex to write code for DBF2XML, I shall do it )
With best regards,
Sudip
Sudip
- Rathinagiri
- Posts: 5471
- Joined: Tue Jul 29, 2008 6:30 pm
- DBs Used: MariaDB, SQLite, SQLCipher and MySQL
- Location: Sivakasi, India
- Contact:
Re: XML for spreadsheets
Thanks a lot Sudip.IMHO, it is not very complex to write code for DBF2XML, I shall do it
East or West HMG is the Best.
South or North HMG is worth.
...the possibilities are endless.
South or North HMG is worth.
...the possibilities are endless.
Re: XML for spreadsheets
Hello Sudip,
Please take a look for the following URL:
http://tech.groups.yahoo.com/group/harb ... bf2xml.zip
Description:
Freeware DBF to XML Wizard v.1.01 by Harbour & HMG build 103
Hope that helps.
Please take a look for the following URL:
http://tech.groups.yahoo.com/group/harb ... bf2xml.zip
Description:
Freeware DBF to XML Wizard v.1.01 by Harbour & HMG build 103
Hope that helps.
Kind Regards,
Grigory Filatov
"Everything should be made as simple as possible, but no simpler." Albert Einstein
Grigory Filatov
"Everything should be made as simple as possible, but no simpler." Albert Einstein
Re: XML for spreadsheets
Hello All,
I was busy in my work (and you can feel how a programmer feels when an easy code doesn't work )
I can export the header of dbf successfully but found problem with exporting data
Here is the sourcecode. I used .xml file format from http://en.wikipedia.org/wiki/Microsoft_ ... ML_formats (I got the url from Rathi, a few days ago)
Grigory, Thank you. I downloaded your app, but it can't detect my old VFP .dbf file (showing message - file is corrupted). It works for my harbour/xharbour generated .dbf files. Output is fine and generic. Can we get the output in the way that a spreadsheet program can understand and display data?
As, I started my small app before seeing your post, I gave the same name of your app (dbf2xml). Sorry, I shall change it later.
My request to all to please check my source the code and send your suggestion. May be the bug is for my careless mistakes.
Thanks in advance
I was busy in my work (and you can feel how a programmer feels when an easy code doesn't work )
I can export the header of dbf successfully but found problem with exporting data
Here is the sourcecode. I used .xml file format from http://en.wikipedia.org/wiki/Microsoft_ ... ML_formats (I got the url from Rathi, a few days ago)
Grigory, Thank you. I downloaded your app, but it can't detect my old VFP .dbf file (showing message - file is corrupted). It works for my harbour/xharbour generated .dbf files. Output is fine and generic. Can we get the output in the way that a spreadsheet program can understand and display data?
As, I started my small app before seeing your post, I gave the same name of your app (dbf2xml). Sorry, I shall change it later.
My request to all to please check my source the code and send your suggestion. May be the bug is for my careless mistakes.
Thanks in advance
With best regards,
Sudip
Sudip
- Rathinagiri
- Posts: 5471
- Joined: Tue Jul 29, 2008 6:30 pm
- DBs Used: MariaDB, SQLite, SQLCipher and MySQL
- Location: Sivakasi, India
- Contact:
Re: XML for spreadsheets
Thanks Sudip. I will check.
East or West HMG is the Best.
South or North HMG is worth.
...the possibilities are endless.
South or North HMG is worth.
...the possibilities are endless.
Re: XML for spreadsheets
Hello All,
I just solved the problem. The bug was due to data conversion - date type, "&" character in text field etc.
Please check. Warning: Conversion of large dbf files may give problem with Open Calc. I found from Task Manager that Open Office is consuming most of my RAM and about 98% of CPU usage for large dbf files. I guess, .xml files are not supposed to be used in this way, or there may be a bug in my code
I just solved the problem. The bug was due to data conversion - date type, "&" character in text field etc.
Please check. Warning: Conversion of large dbf files may give problem with Open Calc. I found from Task Manager that Open Office is consuming most of my RAM and about 98% of CPU usage for large dbf files. I guess, .xml files are not supposed to be used in this way, or there may be a bug in my code
With best regards,
Sudip
Sudip
- Rathinagiri
- Posts: 5471
- Joined: Tue Jul 29, 2008 6:30 pm
- DBs Used: MariaDB, SQLite, SQLCipher and MySQL
- Location: Sivakasi, India
- Contact:
Re: XML for spreadsheets
Hi Sudip,
I think this can also help:
I think this can also help:
East or West HMG is the Best.
South or North HMG is worth.
...the possibilities are endless.
South or North HMG is worth.
...the possibilities are endless.
Re: XML for spreadsheets
Hello Rathi,
Thanks a lot.
I changed following line and it works (for small dbf files)
But, same problem with medium to large .dbf files.
Thanks a lot.
I changed following line and it works (for small dbf files)
Code: Select all
case astruct[i,2] == "C" .or. astruct[i,2] == "M"
fwrite(nhandle,'<Cell><Data ss:Index="'+ltrim(str(i))+'" ss:Type="String">'+strtran(alltrim(&fname), "&", "&")+'</Data></Cell> '+chr(10))
case astruct[i,2] == "L"
With best regards,
Sudip
Sudip
- Roberto Lopez
- HMG Founder
- Posts: 4004
- Joined: Wed Jul 30, 2008 6:43 pm
Re: XML for spreadsheets
Thanks Grigory.gfilatov wrote:Hello Sudip,
Please take a look for the following URL:
http://tech.groups.yahoo.com/group/harb ... bf2xml.zip
Description:
Freeware DBF to XML Wizard v.1.01 by Harbour & HMG build 103
Hope that helps.
A very useful utility indeed.
Regards/Saludos,
Roberto
(Veritas Filia Temporis)
Roberto
(Veritas Filia Temporis)
Re: XML for spreadsheets
Hello All,
Should I use libxhb.a for working with xml?
Thanks in advance
Should I use libxhb.a for working with xml?
Thanks in advance
With best regards,
Sudip
Sudip