Can I Import Measurements From An Excel File?

Can I Import Measurements From An Excel File?

Can I Import Measurements From An Excel File? If yes how? Rather than creating them on SeamlyMe

2 Likes

No, not at the moment. This will involve creating a comma delimited file with headings in a certain format that can read by SeamlyME.

It is in the Github issues and is still pending.

What I do is I create an Excel document with the codes and information that I wish to put into the file, including the codes, then I open SeamlyME and place both files next to each other on the screen. Then I open all of the Known codes in the order that they appear on my Excel list, click on OK when done. As you place a checkmark at the codes, it adds the code to the list so that they’re in the order of the Excel list.

Then I go & enter all of the base & increment values, just going down the list in SeamlyME.

It doesn’t take long.

1 Like

It’s a pretty simple task to import a csv… I’ve already played around with an csv import routine. Problem is validating the csv. First you have to make sure there’s the correct number of columns… and then ā€œassumeā€ the data in that column is correct. In other words any Excel template has to match the SeamlyMe format. Then if adding a ā€œknownā€ measurement, it has to be checked against the known database for correct name, full name, diag num, etc. There’s a whole bunch of other features an import shoiuld include, but it’s beyond the scope of this topic.

2 Likes

Thank you, @Douglas, once again, you’re amazing.

Just putting it out there… Wouldn’t it be easier to just have 3 columns… Code, base value & increment? Unknown codes can be added later by hand.

I feel that the Unknowns shouldn’t feature since they’re not part of the actual program, but we could have the @code as the code with the values and the names can be added later by the person using it.

1 Like

What do you mean by saying ā€œthe codesā€?

Can you show an example screenshot of one of those your files etc please?

2 Likes

Sorry, they’re not really ā€˜codes’, they’re just reference numbers to measurement areas:

image

The Known have numbers like the one highlighted in the list - G04 - This is what I mean by ā€œCodesā€. The items that are not in the Known may be added as Custom, in which case they get @ in front of their name.

The Known measurement areas are linked to images that show the area to be measured.

1 Like

@optimusprime93

In which case there is no number ā€œcodeā€ reference to a measurement diagram - thus the ā€œnaā€ for not applicable.

2 Likes

I can think of quite a few ways to tackle the validation problem (based on doing this sort of thing A LOT in many different applications) but…like Douglas said…beyond the scope of the original question.

1 Like

Ok we talked about can we import measurements as excel file now maybe we can talk about how to import measurements as csv file.

Quesiton 1) Maybe can we create a csv template which can be recognized by Seamly2D by exporting the measurements of the manually created pattern as .csv file on Seamly2D?

It is just theory. Is it possible?

Question 2) For multi sizes?

I’m trying to make the process of creating a pattern and grading a lot faster and efficient.

1 Like

No need? You can already import the measurments into SeamlyMe:

This works because the measuerments are already validated. A csv file could be anything and we have to validate the data against the measurement schema and known measurements.

AgainL No need.

2 Likes

The problem that I have with this is that it only imports the measurement areas actually used in the pattern and not the ones that haven’t been used. Although it is very handy.

Perhaps an Import from SeamlyME will work better since it will have all of the measurement areas and will also already be validated.

The only problem with both of these methods is that it doesn’t import values.

And then…

Most people with any bookkeeping experience know how to handle CSV files and understand the importance of using valid codes and numbers, organising the columns into a specific order for importing into software and manually checking that everything is in order before importing a CSV into program. So I still don’t see why we can’t have a very simple Export to CSV to create a template and a very simple Import from CSV bring into SeamlyME. However, I know that you’re currently very busy with something else that’s very exciting, so I wait patiently :star_struck:

1 Like

Understood… but there’s good reason why we ā€œidiot proofā€ software. Plus with SeamlyMe is goes beyond just checking if known names and values are correct… measurements often have to be in the correct order due to formulas… such as:

Aa… that’s called ā€œOpenā€.

True.

Well we already have an Export to CSV in SeamlyMe… and there’s no such thing as a CSV template.

As I said before it’s easy to import a CSV, but without any validating there’s going to be issues with producing corrupted measurement files or worse SeamlyMe crashing.

2 Likes

Yes. That was what I said.

Ok I will stick to SeamlyMe for the measurements.

Thank you very much.

1 Like

I’ve discovered some issues with export / import of csv measurements.

  1. The current Export to CSV, exports the measurements translated. No Bueno. The apps work with the measurement names internally in English. Only what you see in the GUI is translated. Problem is the CSV export is simply dumping the translated table widget, and not in English as stored in a measurement file.

  2. We can’t import translated known measurements or they would need to be treated as custom measurements. And there’s no sensible way to translate csv measurement names EXACTLY back to English. A translated csv header row also presents a problem as the column names can not be used to validate and map the data.

Basicaslly put… to use ā€œknownā€ csv measurments a user is going to have to export to csv in English, and work with measurement names outside of Seamly - such as in Excel - in English OR just work with custom measurments.

2 Likes

What if only the Image Reference is exported along with the value columns?

1 Like

Brilliant! But not for that reason.

What we can do is still export the names & fullnames translated… along with the image number and values. Then for importing I can make it disregard the names, and use the (unique) image numbers as a key to load the English names which will then get translated to whatever the current GUI language is. Currently it does the opposite when you load a measurement file… it uses the name as a key to find the image number. If an imported image number is not a valid number or is ā€œnaā€ then it’s a custom measurement where we don’t care if it’s translated. In either of those 2 cases I would make sure the name is prepended with the @ so SeamlyMe treats it as custom measurement where the names can be edited.

2 Likes

FYI

I’m adding CSV Import to SeamlyMe. :slight_smile:

First I cleaned up the CSV Export by refactoring & removing an uneccessary 3rd party lib RT used to model the CSV. Yay! More bloated code gone.

I also added a creation line to the header and added the Description field which was missing from the current Export:

Now to finish the Import part…

4 Likes

:star_struck: :heart_eyes: :hugs: My hero! What can I say?

:blush:

I got rid of the checkbox to make the Table header optional… we need the headers to validate the column when importing. I’m also considering getting rid of the Codec dropdown as UTF-8 is the default for QTextStream, and I don’t think we really need a dozen+ options. If Excel or other spreadsheets didn’t export UTF-8 it would be a different story.

3 Likes

Yes, I think UIF-8 is most universal and it really doesn’t matter to the user, as long as user and the software can read it. :grin:

1 Like