Export timetables to CSV?

Started by panyadee, October 03, 2015, 06:59:49 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

panyadee

Hello.  I have just been introduced to FET, and it looks very robust.  I love the versatility of displaying the timetable--the fact that it can be grouped by years, teachers, rooms, etc.  I need my timetables to be in a quite specific format though.  Is there any way to export the info in these timetables to a CSV or Excel file, so I can easily assimilate them into my required format?

Thank in advance.

edit:  I've had a chance to browse some of the resources.  There appears to be an XML-to-XLS converter on the FET Tools/Links page.  But it crashed when I tried to run it on my teachers.xml.  I am using Win 7 64 bit, so maybe that is an issue?  I will try on my 32 bit system at work.

I also see that I can style my HTML output pages with custom CSS.  This is a step in the right direction.  But I would need to create one single HTML table which contained data from all of my student timetables.  I'm not sure if that's possible.  Exporting the timetable data to CSV/XLS would be simpler for my purposes.

Volker Dirr

#1
csv: already exist. See FET -> File -> Export
excel: Open Excel and then import a html file from the fet-result folder
or try one of the tools here in the forum. But i can't help you with them, because they are coded by other guys.

Quote from: panyadee on October 03, 2015, 06:59:49 PMBut I would need to create one single HTML table which contained data from all of my student timetables.
That is called "activities" timetable. See fet-result folder.

panyadee

Thank you very much for your reply.

>> csv: already exist. See FET -> File -> Export

Right.  But that option does not export the data I need.

>> excel: Open Excel and then import a html file from the fet-result folder

I did not know that Excel could handle HTML and XML files.  I was able to do this, and it looks like it will meet my needs.

For the future though, would it be possible for me to modify any FET file(s) such that the HTML files generated are already in my custom format?  I realize I'm crossing into developer zone, and I'm just wondering how difficult/involved that is.

Thanks again.

Volker Dirr

#3
There are millions of (incorrect) possible csv formats. I can't code every variant. The current one is a valid one.

Developing an xml: Developing from the scratch? I guess more then 1 year full time coding if you never coded an xml-file before (like me and most developers).
If you use a library for that? Depending on the library. From as difficult as coding from the scratch up to very easy. Qt doesn't have such an library yet. I will try to use it as soon as Qt have got such a library. But as far as i know Qt didn't plan to code such a library at the moment. (They coded a pdf library, but it isn't very fine. So using the pdf printer driver from a linux os is better.)

I am not sure what you mean with "would it be possible for me to modify any FET file(s) such that the HTML files generated are already in my custom format?". Please explain your custom format.

panyadee

#4
>> There are millions of (incorrect) possible csv formats. I can't code every variant. The current one is a valid one.

I think you're misunderstanding my tone--sorry for being unclear.

To clarify, I am very happy with this product and very excited to begin using it.  I am not at all complaining about what features it does or does not have.  The timetable solving will already save us many man-hours.  Since I am new to it though, I am merely ascertaining if it has *all* the features I need, or if I need to locate additional solutions for those.  I appreciate very much what you and others have done by creating and maintaining this amazing program. 

With regards to my current issue, your previous suggestion of importing my HTML file into Excel is a valid solution--thank you very much for that.

>> I am not sure what you mean with "would it be possible for me to modify any FET file(s) such that the HTML files generated are already in my custom format?". Please explain your custom format.

For example, would it be possible for timetables to be produced with the top row already shaded yellow?  Or would it be possible to have timetables produced with ad additional header row inserted at the top?  These are not the actual changes I need, because I don't want you to do it for me.  I'm just wondering about the feasibility of implementing these changes myself.  For example, perhaps there is a PHP file that creates these HTML pages?  If so, could I perhaps edit the PHP file to implement simple formatting changes?  Again, I'm not asking or demanding that *my* changes be implemented.  It's more of a question like:  Is FET open source enough so I can edit it to meet my needs.  I hope that clarifies.  edit:  I forgot about the custom CSS option!  Correct me if I'm wrong, but this would allow for the edits I wanted (e.g. shading rows, inserting addtional rows, etc). 

Thank you again for all of your information.

Volker Dirr

Quote from: panyadee on October 06, 2015, 06:31:33 AMFor example, would it be possible for timetables to be produced with the top row already shaded yellow?
yes

Quote from: panyadee on October 06, 2015, 06:31:33 AMOr would it be possible to have timetables produced with ad additional header row inserted at the top?
yes

Quote from: panyadee on October 06, 2015, 06:31:33 AMFor example, perhaps there is a PHP file that creates these HTML pages?
no. css file will help. html and css files are generated by c++, not php.

Quote from: panyadee on October 06, 2015, 06:31:33 AMIs FET open source enough so I can edit it to meet my needs.
it is released under AGPL. So i hope that is enough for your needs.

Quote from: panyadee on October 06, 2015, 06:31:33 AMedit:  I forgot about the custom CSS option!  Correct me if I'm wrong, but this would allow for the edits I wanted (e.g. shading rows, inserting addtional rows, etc).
I don't need to correct. You can do that by css.