Rank: Advanced Member Groups: Registered, Advanced Member Joined: 13/01/2012(UTC) Posts: 2,713 Location: Italy Was thanked: 1378 time(s) in 902 post(s)
|
Hi all, Here there is a plugin to share data between SMath and: Plugin UI languages: - requirements: SMath Studio 0.97.5346 or later, .Net Framework 2.0 (Windows) / Latest Mono distributive (Linux);
- installation: download the plugin from the gallery;
- documentation: DataExchange_docs.7z (389kb) downloaded 555 time(s).;
- sources: SVN repository.
- languages: if you want to have a new UI language look into the documentation's Language folder.
>>> PLEASE REPORT IN THIS TOPIC ANY ISSUE <<< Attached below, OLD documentation for SMath Studio prior to 0.97.5346 (0.96.5146 <= SS < 0.97.5346)Edited by user 01 February 2017 12:19:38(UTC)
| Reason: docs updated File Attachment(s): Davide Carpi attached the following image(s): |
If you like my plugins consider to support SMath Studio buying a plan; to offer me a coffee: paypal.me/dcprojects |
4 users thanked Davide Carpi for this useful post.
|
on 12/12/2012(UTC), on 17/01/2013(UTC), on 25/01/2013(UTC), on 08/05/2013(UTC)
|
|
Rank: Advanced Member Groups: Registered
Joined: 30/03/2011(UTC) Posts: 393
Was thanked: 133 time(s) in 114 post(s)
|
Thanks! I can't open the generated ods file with msexcel, msword or by importing it into gdrive. FYI the third outputdirexctory is valid for vista as well. I wonder if you have more plans for these kind of interactions between smath and spreadsheet softwares
|
|
|
|
Rank: Advanced Member Groups: Registered, Advanced Member Joined: 13/01/2012(UTC) Posts: 2,713 Location: Italy Was thanked: 1378 time(s) in 902 post(s)
|
Originally Posted by: kilele Thanks! I can't open the generated ods file with msexcel, msword or by importing it into gdrive. FYI the third outputdirexctory is valid for vista as well. I wonder if you have more plans for these kind of interactions between smath and spreadsheet softwares Hi kilele I've fixed the issue (I think); it depends on the starting template... ODS produced by LibreOffice 3.6.4 can't be opened directly by MS office without recovery (at least for me), now I've found another template (from OpenOffice) and seem that work fine. I've fixed also some issues with decimal separator [edit] and I've changed the function names (according with the built-in importData function) An import function would be nice, but seems not an easy task regards, w3b5urf3r P.S. if you have previously downloaded the "CSV export.dll" plugin don't forget to delete it from the plugin folder.Edited by user 13 December 2012 04:33:10(UTC)
| Reason: Not specified |
If you like my plugins consider to support SMath Studio buying a plan; to offer me a coffee: paypal.me/dcprojects |
|
|
|
Rank: Advanced Member Groups: Registered
Joined: 30/03/2011(UTC) Posts: 393
Was thanked: 133 time(s) in 114 post(s)
|
Tested in xp: the .sm sample expects to find a subdirectory called "outputDirectory" (this worked right on my other pc with vista) the .ods is still not opening, actually libreoffice calc says is a corrupt file. I don't know what you mean by ods template, you may try to convert the csv file to other formats and see the xml format ? for example: convert csv to xlsx, and then xlsx to ods; or convert csv to ods from within gdrive(google) or skydrive(microsoft) As for the import function, I don't know if you could use a mit licensed component which deals with openxml and allows to create/process excel(calc) sheet without having installed those programs, it is called SpreadsheetLight
|
|
|
|
Rank: Advanced Member Groups: Registered
Joined: 30/03/2011(UTC) Posts: 393
Was thanked: 133 time(s) in 114 post(s)
|
tested on xp: the .sm sample expects a subdirectory called "outputDirectory" this worked right on vista though the ods is still not opening, actually libreoffice calc says it is a corrupt file. I don't know what you mean by ods template, you may try to convert the csv to xlsx, and then to ods from within excel and see the structure of the xml file ? or convert the csv to ods from webservices like gdrive(google) or skydrive(microsoft) As for the import function, I don't know if you could make use of a mit licensed component which deals with openxml to create/process spreadsheets without requiring excel or calc, it is called spreadsheetlightEdited by user 13 December 2012 05:33:17(UTC)
| Reason: Not specified
|
|
|
|
Rank: Advanced Member Groups: Registered
Joined: 15/04/2012(UTC) Posts: 2,036 Was thanked: 1168 time(s) in 747 post(s)
|
Hi w3b5urf3r,
thanks a lot for your newest contribution to SMath functionality. exportData.CSV works fine for me, ods is unreadable by Excel. I understand, the given pathnames are just examples. You could use any path, including current directory "."
Might be worth to mention that it is not trivial to paste filenames with spaces into function placeholders. 1. paste the clipboard content to the canvas (automatically becomes a text cell if it has spaces) 2. Bracket the text with "" 3. Copy Text including "" 4. Paste into exportData or wherever you need a string with spaces.
Of course, this would be obsolete, if SMath would automatically add string data type markup if the clipboard text is not a valid SMath expression and deliberately is pasted to a math region. Perhaps I should post a feature request.
Best regards, Martin |
|
|
|
|
Rank: Advanced Member Groups: Registered, Advanced Member Joined: 13/01/2012(UTC) Posts: 2,713 Location: Italy Was thanked: 1378 time(s) in 902 post(s)
|
PLUGIN UPDATEDOriginally Posted by: kilele tested on xp: the .sm sample expects a subdirectory called "outputDirectory" this worked right on vista though the ods is still not opening, actually libreoffice calc says it is a corrupt file. I don't know what you mean by ods template, you may try to convert the csv to xlsx, and then to ods from within excel and see the structure of the xml file ? or convert the csv to ods from webservices like gdrive(google) or skydrive(microsoft) As for the import function, I don't know if you could make use of a mit licensed component which deals with openxml to create/process spreadsheets without requiring excel or calc, it is called spreadsheetlight I've fixed the issues (all related to unassigned path/filename variables, wrong paths and error handling). EDIT: plugin updated again with ODS better handling of text variables. any ODF file it's a zip archive (with a custom extension *.od*) that contain many files (xml,png,...). As first approach I've create an empty ods file from LibreOffice, I've unzipped the ods and I've used the sources as template. Updating the template using a OpenOffice file seem that the output could be opened both from MS excel and Google Docs [Gdocs -> create -> spreadsheet -> file -> open -> upload] The spreadsheetlight plugin it's not compatible (.NET Framework version required is .NET Framework 3.5 instead of 2.0) Originally Posted by: mkraska Hi w3b5urf3r,
thanks a lot for your newest contribution to SMath functionality. exportData.CSV works fine for me, ods is unreadable by Excel. I understand, the given pathnames are just examples. You could use any path, including current directory "."
Might be worth to mention that it is not trivial to paste filenames with spaces into function placeholders. 1. paste the clipboard content to the canvas (automatically becomes a text cell if it has spaces) 2. Bracket the text with "" 3. Copy Text including "" 4. Paste into exportData or wherever you need a string with spaces.
Of course, this would be obsolete, if SMath would automatically add string data type markup if the clipboard text is not a valid SMath expression and deliberately is pasted to a math region. Perhaps I should post a feature request.
Best regards, Martin ODS fixed (I hope) You're right, you can use any existing path where you have permissions to read and write files (BTW inserting or not a backslash at the end of the filepath doesn't cause issues). I know, we can't paste nothing (text with/without spaces or numbers) inside a text variable (a variable enclosed by "" ); your workaround is certainly not trivial but solves me many issues best regards, w3b5urf3r Edited by user 13 December 2012 16:11:30(UTC)
| Reason: Not specified Davide Carpi attached the following image(s): |
If you like my plugins consider to support SMath Studio buying a plan; to offer me a coffee: paypal.me/dcprojects |
|
|
|
Rank: Advanced Member Groups: Registered
Joined: 30/03/2011(UTC) Posts: 393
Was thanked: 133 time(s) in 114 post(s)
|
Test on xp: -the sample does not report errors but now it outputs csv and ods at the same directory as the smath sheet. -the ods file can't be opened with excel_2007_SP1 but it seems that is required at least 2007_SP2 -the output files does not correspond to the matrix on the sample, see screenshots. Edited by user 13 December 2012 18:19:24(UTC)
| Reason: Not specified kilele attached the following image(s):
|
|
|
|
Rank: Advanced Member Groups: Registered
Joined: 30/03/2011(UTC) Posts: 393
Was thanked: 133 time(s) in 114 post(s)
|
Suggestions: -support just .xlsx and we're done! -I don't think .net above 2.0 version is a problem, as far as I know Andrey targeted .Net2.0 to support old versions of windowsMobile and there are not smath versions for that platform since 0.90, however I don't know how this would affect to linux/mono
|
|
|
|
Rank: Advanced Member Groups: Registered, Advanced Member Joined: 13/01/2012(UTC) Posts: 2,713 Location: Italy Was thanked: 1378 time(s) in 902 post(s)
|
Originally Posted by: kilele Test on xp: -the sample does not report errors but now it outputs csv and ods at the same directory as the smath sheet. -the ods file can't be opened with excel_2007_SP1 but it seems that is required at least 2007_SP2 -the output files does not correspond to the matrix on the sample, see screenshots. Hi kilele, thank you for your examination The outputDirectory value it's customizable, in the new DataExport.sm the first definition only it's enabled (output sent in the sheet folder). I consider the 2nd issue a SP1 lack (otherwise the SP2 did not contain any changes about ODF); consider that you can open the ODS with a LibreOffice/OpenOffice for free (even with a portable app) and resave the file as a *.xls or a *.xlsx file. Consider that a csv file works fine when you share numbers and text; the example contains also nested matrices for testing purposes but I would not recommend to share SMath symbolical data using a CSV file. Besides to load correctly a CSV in MS office you need to import it (On the Data tab, in the Get External Data group, click on "From text" > choose the file to load, set delimiters and others options...); LibreOffice start the import procedure when you open the file, so there are not issues... EDIT obviously I can extend the CSV export features to export symbolical data as a string. Originally Posted by: kilele Suggestions: -support just .xlsx and we're done! -I don't think .net above 2.0 version is a problem, as far as I know Andrey targeted .Net2.0 to support old versions of windowsMobile and there are not smath versions for that platform since 0.90, however I don't know how this would affect to linux/mono I prefer the Open Document Standard (Because it's readable from anyone for free, and because I don't have MS office in my home PC XD ) I've already tried to implement a .NET framwork 4.0 plugin in SMath ( math.net numerics plugin ) without success... Edited by user 13 December 2012 18:54:16(UTC)
| Reason: Not specified |
If you like my plugins consider to support SMath Studio buying a plan; to offer me a coffee: paypal.me/dcprojects |
|
|
|
Rank: Advanced Member Groups: Registered
Joined: 30/03/2011(UTC) Posts: 393
Was thanked: 133 time(s) in 114 post(s)
|
I vote for all of your points Cheers!
|
|
|
|
Rank: Advanced Member Groups: Registered, Advanced Member Joined: 13/01/2012(UTC) Posts: 2,713 Location: Italy Was thanked: 1378 time(s) in 902 post(s)
|
PLUGIN UPDATEDTHE PROJECT NAME IS CHANGED SO PLEASE DELETE ANY OLD PLUGIN ('DataExport.dll' or 'CSV export.dll', if any)- added new functions importData.ODS(3) and importData.ODS(4) irol: - added new functions exportData.CSV(2) and exportData.ODS(2)best regards, w3b5urf3r Edited by user 17 December 2012 20:31:37(UTC)
| Reason: Not specified |
If you like my plugins consider to support SMath Studio buying a plan; to offer me a coffee: paypal.me/dcprojects |
|
|
|
Rank: Advanced Member Groups: Registered
Joined: 30/03/2011(UTC) Posts: 393
Was thanked: 133 time(s) in 114 post(s)
|
Incrediblebleble..Che ti amo You are giving SMath a good bath on steroids Edit: I have to withdraw my unconditional regard to your person, since the export sample worked as in my test on xp the other day, see screenshots above. Edited by user 17 December 2012 23:41:46(UTC)
| Reason: Not specified
|
|
|
|
Rank: Advanced Member Groups: Registered, Advanced Member Joined: 13/01/2012(UTC) Posts: 2,713 Location: Italy Was thanked: 1378 time(s) in 902 post(s)
|
Ah, yes... I've forgot to fix a couple of issues in the ODS/CSV exporting with units of measurement (now processed as symbolic data) and nested quotes; the issue revealed itself by opening the exported files with google docs, now seem that work fine... fixed & updated REMEMBER TO DELETE ANY OLD PLUGIN ('DataExport.dll' or 'CSV export.dll', if any)As for the MS Office 2007 SP1 import of ODS files, my idea still remain to convert the file with a third party application (LibreOffice/OpenOffice/webservice); alternatively, here there is a free ODF Add-in for Microsoft Office or the official "2007 Microsoft Office Suite Service Pack 3 (SP3)" (or we can hope for a future evolution of the xls plugin...) best regards, w3b5urf3r Edited by user 18 December 2012 05:02:08(UTC)
| Reason: Not specified Davide Carpi attached the following image(s): |
If you like my plugins consider to support SMath Studio buying a plan; to offer me a coffee: paypal.me/dcprojects |
1 user thanked Davide Carpi for this useful post.
|
|
|
Rank: Administration Groups: Registered, Advanced Member Joined: 23/06/2009(UTC) Posts: 1,740 Was thanked: 318 time(s) in 268 post(s)
|
Hello w3b5urf3r, All my respect for this plugin as well , Just tried a bit to see the ODS I/O functions (LibreOffice 3.5.7). I used a bit larger numerical data table. This is one of the most desirable feature expected from the import/export data function AFAIC. Just see the picture, please. It seems quite Ok. By the way, as we all know, it is not desirable to represent the entire large matrix in SMath. It will cause troubles by occupying large amount of space. The first picture is some data made in Calc. The second one is an import to SMath. The third one is made by exporting the matrix. I have no complaints about it. It seems it works just fine, although I was just curious why the scientific format changed while importing and exporting. Actually, I think this is not a big issue. Regards, Radovan File Attachment(s): omorr attached the following image(s): |
When Sisyphus climbed to the top of a hill, they said: "Wrong boulder!" |
|
|
|
Rank: Advanced Member Groups: Registered, Advanced Member Joined: 13/01/2012(UTC) Posts: 2,713 Location: Italy Was thanked: 1378 time(s) in 902 post(s)
|
Originally Posted by: omorr Hello w3b5urf3r, All my respect for this plugin as well , Just tried a bit to see the ODS I/O functions (LibreOffice 3.5.7). I used a bit larger numerical data table. This is one of the most desirable feature expected from the import/export data function AFAIC. Just see the picture, please. It seems quite Ok. By the way, as we all know, it is not desirable to represent the entire large matrix in SMath. It will cause troubles by occupying large amount of space. The first picture is some data made in Calc. The second one is an import to SMath. The third one is made by exporting the matrix. I have no complaints about it. It seems it works just fine, although I was just curious why the scientific format changed while importing and exporting. Actually, I think this is not a big issue. Regards, Radovan Hi omorr, I did not thought to format the cells for the exponentials... it not require a great effort, I could add this feature tonight best regards, w3b5urf3r |
If you like my plugins consider to support SMath Studio buying a plan; to offer me a coffee: paypal.me/dcprojects |
1 user thanked Davide Carpi for this useful post.
|
|
|
Rank: Advanced Member Groups: Registered, Advanced Member Joined: 13/01/2012(UTC) Posts: 2,713 Location: Italy Was thanked: 1378 time(s) in 902 post(s)
|
Originally Posted by: w3b5urf3r_reloaded Hi omorr, I did not thought to format the cells for the exponentials... it not require a great effort, I could add this feature tonight best regards, w3b5urf3r As announced, feature added Fixed: issues exporting data containing invisible brackets. PLUGIN UPDATEDbest regards, w3b5urf3r |
If you like my plugins consider to support SMath Studio buying a plan; to offer me a coffee: paypal.me/dcprojects |
1 user thanked Davide Carpi for this useful post.
|
|
|
Rank: Advanced Member Groups: Registered
Joined: 30/03/2011(UTC) Posts: 393
Was thanked: 133 time(s) in 114 post(s)
|
w3b5urf3r_reloaded wrote: ..(or we can hope for a future evolution of the xls plugin...)
Thanks for the plugin update. Just to clarify your comment, I don't get to understand it. The new format of MS-Excel is xlsx (not xls) and they call it openxml, actually there is a free download for developers called "openxml sdk". I assume that openoffice and alike may open simple .xlsx (like files with csv) even if only a limited support of excel features are supported. Edit: ok I got what you meant, no problem at least for me with Excel2007-SP1 (can't read ods) since I have installed LibreOffice, in general most people working professionally with Excel may have updated to a recent version with ods support, besides that Excel version has nearly 5 years. Maybe I was thinking of the recent comment by Ioan about the plugin parsing a csv import by means of openxml. Edited by user 19 December 2012 03:58:12(UTC)
| Reason: Not specified
|
|
|
|
Rank: Advanced Member Groups: Registered
Joined: 30/03/2011(UTC) Posts: 393
Was thanked: 133 time(s) in 114 post(s)
|
|
|
|
|
Rank: Advanced Member Groups: Registered, Advanced Member Joined: 13/01/2012(UTC) Posts: 2,713 Location: Italy Was thanked: 1378 time(s) in 902 post(s)
|
Originally Posted by: kilele Thanks for the plugin update. Just to clarify your comment, I don't get to understand it. The new format of MS-Excel is xlsx (not xls) and they call it openxml, actually there is a free download for developers called "openxml sdk". I assume that openoffice and alike may open simple .xlsx (like files with csv) even if only a limited support of excel features are supported.
Edit:
ok I got what you meant, no problem at least for me with Excel2007-SP1 (can't read ods) since I have installed LibreOffice, in general most people working professionally with Excel may have updated to a recent version with ods support, besides that Excel version has nearly 5 years.
Maybe I was thinking of the recent comment by Ioan about the plugin parsing a csv import by means of openxml. Hi kilele, For 'xls plugin' I meant the 'excelcollab plugin' made by Andrey or the second one on the Russian side of the forum ( ?). Because the "openxml sdk" it's based on .NET 3.5 framework, I think that a homemade good plugin it's not easy to make because should be able to read all 4 xls* standards (xls, xlsx ECMA-376, xlsx ISO/IEC 29500 Transitional and the 'new' xlsx ISO/IEC 29500 Strict); so probably (but I'm not sure, because I don't know the differences between the 4 standards) the use of an external plugin as the one you proposed, might be a solution Excel Data Reader seems very good, work under Windows with .Net Framework 2, Windows Mobile with Compact Framework, Linux, OS X, BSD with Mono 2+; unfortunately the plugin can only read files... I think this can be better http://closedxml.codeplex.com/ but works with .NET framework 4.0... Edited by user 29 December 2012 01:54:56(UTC)
| Reason: Not specified |
If you like my plugins consider to support SMath Studio buying a plan; to offer me a coffee: paypal.me/dcprojects |
|
|
|
Forum Jump
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.