Jump to content
TNG Community

REUNION and TNG


klooster

Recommended Posts

Michel KIRSCH
2 hours ago, Appelmus said:

with more than 7000 entries

:-(

My little Mod will "automatize" the copy/paste action and allow to edit the note... Better than nothing...

The fact is that TNG, for the Custom Events only, do the job, because notes are well displayed instead the reference. But the  edition of such a note is not possible...

Now well...

Michel

Link to comment
Share on other sites

This Darrin's answer:

----------------------

The problem is that TNG doesn't recognize this notation: 

1 MIL @N22@ 

Instead it's looking for this: 

1 MIL 
2 NOTE @N22@ 

Anything that's on the same line as the tag goes into the "fact" or "detail" area. For example: 

1 OCCU Fireman 

That's why your @N22@ ended up where it did. I'll make a note to try and address this at some point in the future. 

Darrin 

Link to comment
Share on other sites

  • 2 weeks later...
Michel KIRSCH
On 1/14/2021 at 7:02 AM, klooster said:

1 MIL @N22@ 

Instead it's looking for this: 

1 MIL 
2 NOTE @N22@ 

It is easy to write a script that modify your gedcom before import...

Michel

Link to comment
Share on other sites

*deleted*

Update: Sorry,  my example won't work because I naively thought '22' was a constant, which, as Roger points out below, it would not be.

 

 

Link to comment
Share on other sites

1 hour ago, tngrlkrz said:

If you are familiar with Notepad++,  you could do it without a script or macro.  In the gedcom,  with Find/Replace, with boxes ticked Extended (\n, \r...) , Match case:

image.png

There should be no space between 'MIL' and '\n'.  Do a test with a copy, and 'Ctl Z' will always 'undo' any changes.

 

 

 

For this to work though with minimal effort, it needs wildcard searches for both the MIL part and the Nxx part since these two parts will be different in different parts of the file.

I see that dialog does allow for regular expression searches - does it also allow for regular express results replacement? This setup

image.png

works in BBEdit on my Mac Pro to change the lines as needed. It grabs the string after the 1 (so OBT or MIL or _MIL for example) and the digits of the note's number (the digits in @Nxx@ and replaces them into the desired format - eg

1 MIL @N22@)

becomes

1 MIL
2 NOTE @N22@

Roger

 

Roger

Link to comment
Share on other sites

Yea, Roger, I over simplified, forgetting that the @Nnn@ could vary the value of 'nn'.  Yes, Notepad++ does permit regular expression replacement as well, as you can see by the tick box, though I have not had need to use it much, so haven't checked that option.

Q. why does your expression look for variations  and not only look for 'MIL'?  I thought that was a constant.  Or is it because any record with the trailing 'N' enclosed by '@'s would be found regardless of the first string?

 

Link to comment
Share on other sites

19 minutes ago, tngrlkrz said:

Q. why does your expression look for variations  and not only look for 'MIL'?  I thought that was a constant.  Or is it because any record with the trailing 'N' enclosed by '@'s would be found regardless of the first string?

 

Because at least in Reunion, you can have up to 100 different notes fields, each with its own GEDCOM tag, so I have about 15 different ones in my family file. So looking for any string after the 1, before the @Nxx, captures whatever is the GEDCOM tag used for a note. It captures that in variable 1. It captures the xx from @Nxx@ in variable 2. Then writes them out in the new format of 

1 Variable1
2 NOTE @Nvariable2@

Roger

Link to comment
Share on other sites

Hi Kiwi,

Thanks for you explanation, but how do you accomplish in the Reunion GedCom export file the change into:

1 Variable1
2 NOTE @Nvariable2@

Do you have a script to change all the @Nxx@ variables in the Reunion GedCom export ??

PS: I use Visual Code Studio as my editor for all my PHP, GedCom, ect files.

Link to comment
Share on other sites

Cees,

I note from your website that you are a Mac user and recommend BBedit.  why can't you use Kiwi's dialogue to alter gedcoms?  Or is it you wish an automatic script/macro approach?  I can't help, since I am Windows user of Notepad++ and it's macros not available on Mac.

Link to comment
Share on other sites

5 hours ago, klooster said:

1 Variable1
2 NOTE @Nvariable2@

Do you have a script to change all the @Nxx@ variables in the Reunion GedCom export ??

 

If you don't already have it, download BBEdit - it has a free version that will do what you need.

Open your GEDCOM file using BBEdit, and then press Command F to invoke the Find/Find & Replace dialogue box

Here's the Find string to copy and paste

1 ([_A-Za-z]+) @N([0-9]+)@

Here's the Replace string to copy and paste

1 \1\r2 NOTE @N\2@

Make the entries as shown in each box, and make sure to check the Grep box

Press Find - it will find the first occurrence that matches that Find string.

Click Replace and watch it change 1 line into 2 lines.

Do that a few times to convince yourself it knows what it's doing, and then click the Replace All button.

In the blink of an eye the entire file will be changed.

Roger

Link to comment
Share on other sites

Thanks Roger, yes I have BbEdit / Mac

Your Find and replace works like a charm !!

 

BUT when I import the edited BbEdit file into TNG all the notes are not imported, see print screen, so its even worse then befSchermafbeelding 2021-01-25 om 13.17.42.pngore

Link to comment
Share on other sites

7 hours ago, klooster said:

Your Find and replace works like a charm !!

 

Cees - you might need one more "run" after this has done - I've just now noticed it turns

1 NOTE @N2165@

into

1 NOTE
2 NOTE @N2165@

which causes the appearance of a blank note in TNG when imported.

So after running the first Find and Replace, you'll need to do this one

image.png

to turn the "true" NOTE lines back to

1 NOTE @N2165@

Roger

Link to comment
Share on other sites

Hi Roger, thanks for you suggestion, but I know that i have to click the 3rd icon  with the green dot on it to see the notes.. But it is empty! No single note is imported

 

I did the second run as you suggested, no succes. Notes are with a green dot, but when you click, empty, see printscreen.

I also attach the Gedcom Test file after the two suggested runs. And the original Reunion export GedCom file before the two bbEdit runs

Schermafbeelding 2021-01-25 om 16.21.26.png

TEST2-bbedit-2-run.ged

Reunion-Kloosterman-NO-BbEdit runs.ged

Link to comment
Share on other sites

I have performed the changes on the Reunion GEDCOM file, and imported it into my test site. There are 2,133 Notes show up when I go to TNG Admin ------> Notes.

When I find the same Adriaan Kloosterman as you show above, I see this - the overlay is what I got when I clicked on the grey icon with the green dot for Residence.

image.png

I'm assuming that some events (eg Research) didn't import because they weren't set up in my Custom Events. But those that did import and have the green dot on the icon have notes showing when I click that icon. All 5 icons that have the green dot (there are 3 you see, and 2 more above for Birth and Death) have similar to what I show above - a note showing up in the overlay screen when clicked.

Here he is on my testing site

[Website Example URL Removed as Website is Defunct]

Roger

Edited by theKiwi
[Website Example URL Removed as Website is Defunct]
Link to comment
Share on other sites

Hi Roger,

Thank you for trying it out. Yes I see that the notes are importing.

So I did the two runs again, see attached gedcom file, Reunion-Kloosterman-N2x-BbEdit runs

Imported all current data into TNG, NO NOTES, see 3 attached print screens.

So what is going wrong ?????????????

PS:

  • emptied the cache
  • Reinstalled all the important TNg gedcom import php 13.02 files again.

 

Then I imported the Reunion-Kloosterman-NO-BbEdit runs again. Now the notes are imported and visible on my local host test site, but wit the original problem where this help question originally started. In admin person only the @Nxx@ and no text visble see last printscreen.Schermafbeelding 2021-01-26 om 07.58.16.pngSchermafbeelding 2021-01-26 om 07.48.45.pngSchermafbeelding 2021-01-26 om 07.58.16.png

Schermafbeelding 2021-01-26 om 07.42.48.pngSchermafbeelding 2021-01-26 om 07.42.23.png

Reunion-Kloosterman-N2x-BbEdit runs.ged

Reunion-Kloosterman-NO-BbEdit runs.ged

Schermafbeelding 2021-01-26 om 07.48.45.png

Link to comment
Share on other sites

Well basically I'm stumped.

But a couple of things:

Why is TNG showing you the grey icon with a green dot if that note is empty? If there is no note it should show just the grey icon.

I notice that all the empty events are listed at the end of the page. In TNG Admin ------> Setup ------> General Settings ------> Miscellaneous, what do you have chosen for "Show Notes"?

image.png

Probably "In Notes section"? Change that to "Underneath events, except general notes" and see if that makes any difference.

If you're doing all this on your localhost, then try going to TNG Admin ------> Setup ------> General Settings ------> Table Creation tab, and click the button to Create the Tables. This will wipe out everything (including your User setup).** Now import the GEDCOM file again - is it any different - particularly the issue of the green dot showing when the note is in fact empty?

**If you go to TNG Admin ------> Utilities and backup all the tables first, you can restore the Users table after you've done the Create Tables.

Roger

Link to comment
Share on other sites

Hi Roger, did as you suggested:

1.] In TNG Admin ------> Setup ------> General Settings ------> Miscellaneous, UNDERNEATH EVENTS, EXCEPT GENERAL NOTES

Imported the 2 x BbEdit Gedcom run, no notes.

2.] New tables, Imported the Imported the 2 x BbEdit Gedcom run, no notes.

 

See printscreens. There is aGreen Dot, but the note is empty ?????

 

I SURRENDER,

 

Schermafbeelding 2021-01-26 om 15.15.13.png

Schermafbeelding 2021-01-26 om 15.16.44.png

Schermafbeelding 2021-01-26 om 15.16.56.png

Schermafbeelding 2021-01-26 om 15.17.05.png

Link to comment
Share on other sites

Here's an oddity...

image.png

versus

image.png

See the difference in number of notes?

Are all the Custom Events set to Accept after you cleared the tables and started over?

What's odd is that the small empty circle indicates TNG thinks there's a Note, but there's nothing in it - I guess that lines up with the green dot showing, but there's no note.

I suggest you write to Darrin again, and reference this thread and see if he has any thoughts on this.

Roger

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...