Lone Wolf Development Forums  

Go Back   Lone Wolf Development Forums > Realm Works Forums > Realm Works Discussion

Notices

Reply
 
Thread Tools Display Modes
bishop618
Member
 
Join Date: Nov 2016
Posts: 40

Old October 12th, 2017, 04:21 PM
So if that changes, all will be good?
bishop618 is offline   #121 Reply With Quote
Farling
Senior Member
 
Join Date: Mar 2013
Location: Greater London, UK
Posts: 2,623

Old October 12th, 2017, 04:57 PM
Quote:
Originally Posted by bishop618 View Post
So if that changes, all will be good?
Yes, although you could try v1.8 that I've just uploaded which means you won't have to change your Realm Works structure :-)

Farling

Author of the Realm Works Import tool, Realm Works Output tool and Realm Works to Foundry module

Donations gratefully received via Patreon, Ko-Fi or Paypal
Farling is offline   #122 Reply With Quote
DickNervous
Junior Member
 
Join Date: Oct 2017
Posts: 15

Old October 17th, 2017, 09:39 PM
I've been playing around with this tool, which is way freaking cool BTW, and have been having some small issues. Here is what is happening.

I have a slew of data in Excel for Traveller systems. It includes everything from specifications of the system to long descriptions of the history, patrons, adventure seeds, etc. The items that seem to be causing issues are:

1. Many system names (and in several description fields) there is text with ' in them. This is usually in a system name such as "A'eouya", but is also in text such as "The captain's chair". After reading through this topic I tried to put double quotes around the system name, which allowed a small sample import to run, but the system name showed up in RW as "A’eouya​". It also put the "’" in any spot a single quote was in the text.

Is there a way to avoid getting the ’ characters and get the ' instead? And do I need to go put " around every system name that has an ' in it?

2. Many descriptions are multiple paragraphs with line feeds in them. This caused the import to get misaligned and put things in the wrong fields, resulting in it attempting to populate the public_name field with an entry that was a few paragraphs long. I have tried to fix this by editing the CSV file in Notepad++ and it seems to help, but then the text shows up in RW as one big block of text which can be difficult to read.

How can I keep the paragraphs for the import?

3. If I have a text string in the CSV that represents a URL, what type of snippet should I import it into so that it shows up as an active link in the topic view? I tried text, but it just shows up as plain text until I edit something in the topic and save it, at which point it is recognized as a URL.

4. How can I import a simple picture from a URL? I know if I go in and select load from file and put a URL in, it will import the image. Can I do that with an import as well?

Thanks!!!!
DickNervous is offline   #123 Reply With Quote
Farling
Senior Member
 
Join Date: Mar 2013
Location: Greater London, UK
Posts: 2,623

Old October 18th, 2017, 01:04 AM
Quote:
Originally Posted by DickNervous View Post
1. Many system names (and in several description fields) there is text with ' in them. This is usually in a system name such as "A'eouya", but is also in text such as "The captain's chair". After reading through this topic I tried to put double quotes around the system name, which allowed a small sample import to run, but the system name showed up in RW as "A€™eouya​". It also put the "€™" in any spot a single quote was in the text.

Is there a way to avoid getting the €™ characters and get the ' instead? And do I need to go put " around every system name that has an ' in it?
I think CSV file formats might allow single quote to be used as an alternative to double quotes to mark the boundaries of a single field.

I will have to look to see why the single quote character is being imported as three separate characters. It might be encoding problems.

Could you have a look at the CSV table which is displayed in the bottom half of the window to see if that table still shows the single quote or is showing those three characters? This will help me know if it is the CSV reader or the XML writer which is causing the issue.

Do single quotes appear fine in other parts of text?

Quote:
Originally Posted by DickNervous View Post
2. Many descriptions are multiple paragraphs with line feeds in them. This caused the import to get misaligned and put things in the wrong fields, resulting in it attempting to populate the public_name field with an entry that was a few paragraphs long. I have tried to fix this by editing the CSV file in Notepad++ and it seems to help, but then the text shows up in RW as one big block of text which can be difficult to read.

How can I keep the paragraphs for the import?
I think that multi-line fields can be defined in the CSV file by putting double quotes at the start and end of each field. At the moment, the CSV Import tool puts everything into a single paragraph. I suppose the tool could be updated so that a blank line in the middle of some text marks indicates where a paragraph break is required? Would this handle the text in your case?

Quote:
Originally Posted by DickNervous View Post
3. If I have a text string in the CSV that represents a URL, what type of snippet should I import it into so that it shows up as an active link in the topic view? I tried text, but it just shows up as plain text until I edit something in the topic and save it, at which point it is recognized as a URL.
The conversion from plain text to URL is usually a manual thing that the program does. I could add this into the CSV import tool, possibly as an option in case other users don't want URLs converted (although I guess RW will convert them as soon as the text is edited anyway).

Quote:
Originally Posted by DickNervous View Post
4. How can I import a simple picture from a URL? I know if I go in and select load from file and put a URL in, it will import the image. Can I do that with an import as well?
At the moment it isn't possible to import images easily. I don't think there is a way to encode them in CSV format. The RWEXPORT file format allows images to be defined, but the difficulty is creating a simple way for my CSV import tool to detect an image reference inside the CSV file.

---

So, new feature requests appear to be:

1 - handle single quote properly

2 - detect paragraphs when importing large amounts of text.

3 - detect URLs when importing text.

4 - provide some mechanism to import images.

Farling

Author of the Realm Works Import tool, Realm Works Output tool and Realm Works to Foundry module

Donations gratefully received via Patreon, Ko-Fi or Paypal

Last edited by Farling; October 18th, 2017 at 01:10 AM.
Farling is offline   #124 Reply With Quote
Parody
Senior Member
 
Join Date: Jan 2013
Location: Rochester, MN
Posts: 1,514

Old October 18th, 2017, 06:42 AM
Problem 1 is Smart Quotes being misinterpreted; somewhere along the line they're getting converted to UTF-8 and then reinterpreted as "not Unicode".


Last edited by Parody; October 18th, 2017 at 06:57 AM.
Parody is offline   #125 Reply With Quote
DickNervous
Junior Member
 
Join Date: Oct 2017
Posts: 15

Old October 18th, 2017, 07:54 AM
Quote:
Originally Posted by Farling View Post
I think CSV file formats might allow single quote to be used as an alternative to double quotes to mark the boundaries of a single field.

I will have to look to see why the single quote character is being imported as three separate characters. It might be encoding problems.

Could you have a look at the CSV table which is displayed in the bottom half of the window to see if that table still shows the single quote or is showing those three characters? This will help me know if it is the CSV reader or the XML writer which is causing the issue.

Do single quotes appear fine in other parts of text?
the single quotes appear in the preview pane of the tool with or without using double quotes in the CSV file.


Quote:
Originally Posted by Farling View Post
I think that multi-line fields can be defined in the CSV file by putting double quotes at the start and end of each field. At the moment, the CSV Import tool puts everything into a single paragraph. I suppose the tool could be updated so that a blank line in the middle of some text marks indicates where a paragraph break is required? Would this handle the text in your case?
Right now the CSV file, when viewed in Notepad++, shows the paragraphs on different lines, with blank lines between them. I think this is what is messing up your tool. As soon as it encounters that in the preview pane you can see where fields are now off. However, that text is in a single cell in Excel. If I edit the file in Notepad++ and remove the lines, it works. But it is all one big paragraph. I can try to play with the formatting in Excel to see what happens. Perhaps I have an extra line feed or something in there that can be removed.

Quote:
Originally Posted by Farling View Post
The conversion from plain text to URL is usually a manual thing that the program does. I could add this into the CSV import tool, possibly as an option in case other users don't want URLs converted (although I guess RW will convert them as soon as the text is edited anyway).
If I am putting the links into the correct field, then I don't think there is much more you can do with the tool. It seems to be just the way RW handles it.

Quote:
Originally Posted by Farling View Post
At the moment it isn't possible to import images easily. I don't think there is a way to encode them in CSV format. The RWEXPORT file format allows images to be defined, but the difficulty is creating a simple way for my CSV import tool to detect an image reference inside the CSV file.
Currently if I try to assign the path of an image to an image field, the tool crashes. I have no idea how the Import/Export handles images so I can't even begin to guess what the story is there.

Quote:
Originally Posted by Farling View Post
---

So, new feature requests appear to be:

1 - handle single quote properly

2 - detect paragraphs when importing large amounts of text.

3 - detect URLs when importing text.

4 - provide some mechanism to import images.
That pretty much sums it up.
Thanks!
DickNervous is offline   #126 Reply With Quote
Acenoid
Senior Member
 
Join Date: Dec 2013
Posts: 798

Old October 18th, 2017, 12:38 PM
Wow goog luck have t check out the new versio nwhen it comes as well Quite an undertaking but this could ease up the import in RW I suppose... quite a bit

Join the (unofficial) Realm-Works IRC Chat: #realm-works on the Rizon Network (https://wiki.rizon.net/index.php?title=Servers)
-> Browser Client: https://kiwiirc.com/client/irc.rizon.net
Acenoid is offline   #127 Reply With Quote
gloranphile
Senior Member
 
Join Date: Mar 2013
Location: Denver, CO
Posts: 437

Old October 18th, 2017, 12:49 PM
So can I export what I need for my game and import using this tool?

Trying to do this with the built-in import/export breaks RW, and the devs haven't fixed it for me yet....

D100 for life!
gloranphile is offline   #128 Reply With Quote
DickNervous
Junior Member
 
Join Date: Oct 2017
Posts: 15

Old October 18th, 2017, 02:05 PM
Farling

I just went through and edited my CSV to remove the line feeds and it imported fine. The singe quotes all imported properly, no editing required from me on that part. So the single quotes issue doesn't seem to be an issue. Not sure what was going on yesterday with it.

The paragraph thing is still an issue. In the CSV file it makes each paragraph a new line, which is screwing up the import. I don't know if there is a way around that.

I changed the Picture snippets back to text and it imported the URLs. I just need to edit a page for them to become active, which while a bit of a pain, isn't all that bad. However, if there was a way top import the file path directly that would be awesome.

Thanks!
DickNervous is offline   #129 Reply With Quote
Farling
Senior Member
 
Join Date: Mar 2013
Location: Greater London, UK
Posts: 2,623

Old October 18th, 2017, 02:53 PM
Quote:
Originally Posted by DickNervous View Post
Farling

I just went through and edited my CSV to remove the line feeds and it imported fine. The singe quotes all imported properly, no editing required from me on that part. So the single quotes issue doesn't seem to be an issue. Not sure what was going on yesterday with it.

The paragraph thing is still an issue. In the CSV file it makes each paragraph a new line, which is screwing up the import. I don't know if there is a way around that.

I changed the Picture snippets back to text and it imported the URLs. I just need to edit a page for them to become active, which while a bit of a pain, isn't all that bad. However, if there was a way top import the file path directly that would be awesome.

Thanks!
Is it possible for you to PM me a link to the CSV file which is causing the bad single quote import problem, and/or the multiple paragraphs problem?

Another file with an image in a CSV file would be useful for testing.

Farling

Author of the Realm Works Import tool, Realm Works Output tool and Realm Works to Foundry module

Donations gratefully received via Patreon, Ko-Fi or Paypal
Farling is offline   #130 Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -8. The time now is 08:22 PM.


Powered by vBulletin® - Copyright ©2000 - 2024, vBulletin Solutions, Inc.
wolflair.com copyright 1998-2016 Lone Wolf Development, Inc. View our Privacy Policy here.