* Quick Link Creator
- Jane
- Site Admin
- Posts: 8442
- Joined: 01 Nov 2002 15:00
- Family Historian: V7
- Location: Somerset, England
- Contact:
Quick Link Creator
I have written a small plugin which creates a "link" file on your desktop for a selected person.
Please see later post for the most recent version.
Please see later post for the most recent version.
Last edited by Jane on 12 Aug 2017 10:36, edited 1 time in total.
Jane
My Family History : My Photography "Knowledge is knowing that a tomato is a fruit. Wisdom is not putting it in a fruit salad."
My Family History : My Photography "Knowledge is knowing that a tomato is a fruit. Wisdom is not putting it in a fruit salad."
- tatewise
- Megastar
- Posts: 27088
- Joined: 25 May 2010 11:00
- Family Historian: V7
- Location: Torbay, Devon, UK
- Contact:
Re: Quick Link Creator
That is neat Jane.
But I think it needs to inform the user the batch file has been saved to Desktop and needs to be run to start FH next time.
Otherwise, not only does it appear that nothing has happened, but also the user does not know what to do.
I am fascinated how you discovered that FH has an INI file to perform that trick.
What else can that INI file do?
Why doesn't FH use it to let users choose which Individual has Focus on restart?
I've added this Plugin to how_to:remember_current_records_being_updated|> Remember Current Records being Updated.
However, I think the Plugin name could be better as it does not really convey what it is for ~ creates quick link to what?
Maybe something like Open Individual in Next Session would be better?
But I think it needs to inform the user the batch file has been saved to Desktop and needs to be run to start FH next time.
Otherwise, not only does it appear that nothing has happened, but also the user does not know what to do.
I am fascinated how you discovered that FH has an INI file to perform that trick.
What else can that INI file do?
Why doesn't FH use it to let users choose which Individual has Focus on restart?
I've added this Plugin to how_to:remember_current_records_being_updated|> Remember Current Records being Updated.
However, I think the Plugin name could be better as it does not really convey what it is for ~ creates quick link to what?
Maybe something like Open Individual in Next Session would be better?
Mike Tate ~ researching the Tate and Scott family history ~ tatewise ancestry
- davidm_uk
- Megastar
- Posts: 740
- Joined: 20 Mar 2004 12:33
- Family Historian: V7
- Location: St Albans, Hertfordshire, UK
Re: Quick Link Creator
Yes, very neat
Is there an alternative for "Window=FocusWin" to open just the individual properties window (floating)? I never use the focus window. I'm quite happy to copy and modify the desktop cmd file rather than start complicating the plugin.
I'm sure that others will ask for all sorts of variations. As Mike says, knowing "What else can that INI file do?" would be very interesting.
Is there an alternative for "Window=FocusWin" to open just the individual properties window (floating)? I never use the focus window. I'm quite happy to copy and modify the desktop cmd file rather than start complicating the plugin.
I'm sure that others will ask for all sorts of variations. As Mike says, knowing "What else can that INI file do?" would be very interesting.
David Miller - researching Miller, Hare, Walker, Bright (mostly Herts, Beds, Dorset and London)
- Jane
- Site Admin
- Posts: 8442
- Joined: 01 Nov 2002 15:00
- Family Historian: V7
- Location: Somerset, England
- Contact:
Re: Quick Link Creator
Funnily enough I am not using it as a remember for next time, which is why it names the files with the persons details. I use it to drop the file into Evernote, so I can jump to the right person from my research notes.
The INI only does the couple of things at the moment so start on a person and select Focus (FocusWin) or Record Window (RecordWin).
I knew about it as is was done as a "paid for" change for a Project I did for My History creating automated charts using Family Historian which is driven by a web site.
I have added a message once the file is created. Do you think it's worth offering to save with the Name as now, as well as a "fixed" file name so if you did just want to always save to the same filename you could. I have not changed the name yet, I might wait until the functionality has settled.
The INI only does the couple of things at the moment so start on a person and select Focus (FocusWin) or Record Window (RecordWin).
I knew about it as is was done as a "paid for" change for a Project I did for My History creating automated charts using Family Historian which is driven by a web site.
I have added a message once the file is created. Do you think it's worth offering to save with the Name as now, as well as a "fixed" file name so if you did just want to always save to the same filename you could. I have not changed the name yet, I might wait until the functionality has settled.
Last edited by Jane on 11 Aug 2017 17:41, edited 1 time in total.
Jane
My Family History : My Photography "Knowledge is knowing that a tomato is a fruit. Wisdom is not putting it in a fruit salad."
My Family History : My Photography "Knowledge is knowing that a tomato is a fruit. Wisdom is not putting it in a fruit salad."
- davidm_uk
- Megastar
- Posts: 740
- Joined: 20 Mar 2004 12:33
- Family Historian: V7
- Location: St Albans, Hertfordshire, UK
Re: Quick Link Creator
That was quick, works a treat.The INI only does the couple of things at the moment so start on a person and select Focus (FocusWin) or Record Window (RecordWin).
Thanks Jane
David Miller - researching Miller, Hare, Walker, Bright (mostly Herts, Beds, Dorset and London)
- tatewise
- Megastar
- Posts: 27088
- Joined: 25 May 2010 11:00
- Family Historian: V7
- Location: Torbay, Devon, UK
- Contact:
Re: Quick Link Creator
Sounds like it needs a simple GUI to offer user some options :-
A button would create the Desktop command file.
- Choose Individual if currently selected record is wrong one
- Use a Fixed Filename or Person & Project Filename
- Startup in Focus Window or in Records Window
A button would create the Desktop command file.
Mike Tate ~ researching the Tate and Scott family history ~ tatewise ancestry
- BillH
- Megastar
- Posts: 2184
- Joined: 31 May 2010 03:40
- Family Historian: V7
- Location: Washington State, USA
Re: Quick Link Creator
Jane, yes that would be a nice addition. I would use it to start where I left off each time and wouldn't really need the persons name in the file name.Jane wrote:Do you think it's worth offering to save with the Name as now, as well as a "fixed" file name so if you did just want to always save to the same filename you could.
Thanks
- tatewise
- Megastar
- Posts: 27088
- Joined: 25 May 2010 11:00
- Family Historian: V7
- Location: Torbay, Devon, UK
- Contact:
Re: Quick Link Creator
Assuming the desire to open FH in the Focus Window or the Records Window is reflected in the Tools > Preferences > Startup > Display the Records Window option, then the Registry Key HKEY_CURRENT_USER\Software\Calico Pie\Family Historian\2.0\Preferences\Rec Win Startup value of True or False could automatically choose the INI file Window mode.
Mike Tate ~ researching the Tate and Scott family history ~ tatewise ancestry
- Jane
- Site Admin
- Posts: 8442
- Joined: 01 Nov 2002 15:00
- Family Historian: V7
- Location: Somerset, England
- Contact:
Re: Quick Link Creator
Actually if you don't specify the window, I think it uses the default anyway.
I will have a play, but probably won't be tonight.
I will have a play, but probably won't be tonight.
Jane
My Family History : My Photography "Knowledge is knowing that a tomato is a fruit. Wisdom is not putting it in a fruit salad."
My Family History : My Photography "Knowledge is knowing that a tomato is a fruit. Wisdom is not putting it in a fruit salad."
- tatewise
- Megastar
- Posts: 27088
- Joined: 25 May 2010 11:00
- Family Historian: V7
- Location: Torbay, Devon, UK
- Contact:
Re: Quick Link Creator
You are correct Jane, but then it IGNORES the Record= option!
Mike Tate ~ researching the Tate and Scott family history ~ tatewise ancestry
- Valkrider
- Megastar
- Posts: 1534
- Joined: 04 Jun 2012 19:03
- Family Historian: V7
- Location: Lincolnshire
- Contact:
Re: Quick Link Creator
I just thought that I would give this plugin a try in PlayOnMac.
It creates a Mac desktop shortcut but as it is a .cmd file the Mac doesn't know what to do with it.
Just FYI not criticising.
It creates a Mac desktop shortcut but as it is a .cmd file the Mac doesn't know what to do with it.
Just FYI not criticising.
- tatewise
- Megastar
- Posts: 27088
- Joined: 25 May 2010 11:00
- Family Historian: V7
- Location: Torbay, Devon, UK
- Contact:
Re: Quick Link Creator
Colin, is there an equivalent batch command file language for Mac that could be used instead?
All it is actually doing is copying some text to a plain text fhini.ini file and then running FH with some command line options.
All it is actually doing is copying some text to a plain text fhini.ini file and then running FH with some command line options.
Mike Tate ~ researching the Tate and Scott family history ~ tatewise ancestry
- Valkrider
- Megastar
- Posts: 1534
- Joined: 04 Jun 2012 19:03
- Family Historian: V7
- Location: Lincolnshire
- Contact:
Re: Quick Link Creator
Mike
It will be a bit more complicated than that as the Mac has no concept of drive letters which are included in the paths in the cmd file.
What it may be possible to do is to create a startup application in PlayOnMac, I will have a look into that.
It will be a bit more complicated than that as the Mac has no concept of drive letters which are included in the paths in the cmd file.
What it may be possible to do is to create a startup application in PlayOnMac, I will have a look into that.
- tatewise
- Megastar
- Posts: 27088
- Joined: 25 May 2010 11:00
- Family Historian: V7
- Location: Torbay, Devon, UK
- Contact:
Re: Quick Link Creator
Colin, is there somewhere in the PlayOnMac PC environment that the batch CMD file can be saved instead of the Mac Desktop, because within that PC environment drive letters are understood otherwise the Plugins and Batch scripts employed with Ancestral Sources Data Entry and Backup and Restore FH Settings would never run at all.
Mike Tate ~ researching the Tate and Scott family history ~ tatewise ancestry
- Jane
- Site Admin
- Posts: 8442
- Joined: 01 Nov 2002 15:00
- Family Historian: V7
- Location: Somerset, England
- Contact:
Re: Quick Link Creator
@Valkrider - I suspect it might be possible to create a mac template file fairly easily if you can tell me what needs to be in there.
I have added a popup selection screen which shows the currently selected record with a button to change it.
It defaults to the "Launch Family Historian" option, but you can change it to named files, it also defaults to the current start up workspace using Mikes read of the registry.
It puts the focus on the Create button so running and pressing enter twice will update the Launch script on the desktop.
I have not changed the name yet. So now it's mostly function complete, what should it be called?
I have added a popup selection screen which shows the currently selected record with a button to change it.
It defaults to the "Launch Family Historian" option, but you can change it to named files, it also defaults to the current start up workspace using Mikes read of the registry.
It puts the focus on the Create button so running and pressing enter twice will update the Launch script on the desktop.
I have not changed the name yet. So now it's mostly function complete, what should it be called?
Last edited by Jane on 11 Aug 2017 17:42, edited 1 time in total.
Jane
My Family History : My Photography "Knowledge is knowing that a tomato is a fruit. Wisdom is not putting it in a fruit salad."
My Family History : My Photography "Knowledge is knowing that a tomato is a fruit. Wisdom is not putting it in a fruit salad."
- tatewise
- Megastar
- Posts: 27088
- Joined: 25 May 2010 11:00
- Family Historian: V7
- Location: Torbay, Devon, UK
- Contact:
Re: Quick Link Creator
To differentiate between running in genuine Windows or in PlayOnMac or Crossover use the following Plugin script:
Is_Windows = true -- Windows v PlayOnMac/Crossover/Wine
if fhGetPluginDataFileName("LOCAL_MACHINE"):lower():match(":\\users\\public\\") then Is_Windows = false end
Then test if Is_Windows then <use CMD template> else <use Mac template> end
That is the technique I use in my Plugins to determine the Windows versus Mac environment.
It relies on Mac using the C:\Users\Public\Application Data\... path instead of C:\ProgramData\... path.
See glossary:family_historian_program_data_folder|> Family Historian Program Data Folder.
Is_Windows = true -- Windows v PlayOnMac/Crossover/Wine
if fhGetPluginDataFileName("LOCAL_MACHINE"):lower():match(":\\users\\public\\") then Is_Windows = false end
Then test if Is_Windows then <use CMD template> else <use Mac template> end
That is the technique I use in my Plugins to determine the Windows versus Mac environment.
It relies on Mac using the C:\Users\Public\Application Data\... path instead of C:\ProgramData\... path.
See glossary:family_historian_program_data_folder|> Family Historian Program Data Folder.
Mike Tate ~ researching the Tate and Scott family history ~ tatewise ancestry
- Jane
- Site Admin
- Posts: 8442
- Joined: 01 Nov 2002 15:00
- Family Historian: V7
- Location: Somerset, England
- Contact:
Re: Quick Link Creator
Just noticed a bug as the screen does not refresh correctly when you select a different record, new version below
Jane
My Family History : My Photography "Knowledge is knowing that a tomato is a fruit. Wisdom is not putting it in a fruit salad."
My Family History : My Photography "Knowledge is knowing that a tomato is a fruit. Wisdom is not putting it in a fruit salad."
- Valkrider
- Megastar
- Posts: 1534
- Joined: 04 Jun 2012 19:03
- Family Historian: V7
- Location: Lincolnshire
- Contact:
Re: Quick Link Creator
Jane
Looking at PlayOnMac it is possible to create another shortcut on the POM desktop to another programme.
As a result if for the Mac version the ini file and cmd file can be written to the FH or Calico Pie folder instead then it looks like it might be possible to create the shortcut to an individual.
Looking at PlayOnMac it is possible to create another shortcut on the POM desktop to another programme.
As a result if for the Mac version the ini file and cmd file can be written to the FH or Calico Pie folder instead then it looks like it might be possible to create the shortcut to an individual.
- Jane
- Site Admin
- Posts: 8442
- Joined: 01 Nov 2002 15:00
- Family Historian: V7
- Location: Somerset, England
- Contact:
Re: Quick Link Creator
Colin, do you think you would have use for the plugin, if so where would you like the file put.
Jane
My Family History : My Photography "Knowledge is knowing that a tomato is a fruit. Wisdom is not putting it in a fruit salad."
My Family History : My Photography "Knowledge is knowing that a tomato is a fruit. Wisdom is not putting it in a fruit salad."
- Valkrider
- Megastar
- Posts: 1534
- Joined: 04 Jun 2012 19:03
- Family Historian: V7
- Location: Lincolnshire
- Contact:
Re: Quick Link Creator
Jane
Yes I would use it as I have about 20 different projects in FH. As a result what about storing them in the Export folder of the project.
What it would mean for me is getting back to an individual who is not necessarily the root person, this is particularly relevant for me where I have a Surname study with one project per country and the root person is not really relevant.
Yes I would use it as I have about 20 different projects in FH. As a result what about storing them in the Export folder of the project.
What it would mean for me is getting back to an individual who is not necessarily the root person, this is particularly relevant for me where I have a Surname study with one project per country and the root person is not really relevant.
- zoomdoggies
- Gold
- Posts: 26
- Joined: 25 Apr 2014 21:27
- Family Historian: V6.2
- Location: Seattle, Washington, USA
Re: Quick Link Creator
Thanks for sharing, Jane. This will be a handy way to pick up where I left off.
The plug-in, as written, whined about not being able to find my Family Historian executable – don't know why not, since it was installed in the default place – but I hardcoded the path and it works like a champ.
– Teri
The plug-in, as written, whined about not being able to find my Family Historian executable – don't know why not, since it was installed in the default place – but I hardcoded the path and it works like a champ.
– Teri
- Jane
- Site Admin
- Posts: 8442
- Joined: 01 Nov 2002 15:00
- Family Historian: V7
- Location: Somerset, England
- Contact:
Re: Quick Link Creator
I have added some code to try and support putting the file in the Project Public folder for Mac and also added a fall back check for Family Historian if the registry key read fails.
Jane
My Family History : My Photography "Knowledge is knowing that a tomato is a fruit. Wisdom is not putting it in a fruit salad."
My Family History : My Photography "Knowledge is knowing that a tomato is a fruit. Wisdom is not putting it in a fruit salad."
- Valkrider
- Megastar
- Posts: 1534
- Joined: 04 Jun 2012 19:03
- Family Historian: V7
- Location: Lincolnshire
- Contact:
Re: Quick Link Creator
Jane
Thanks for this but still not working for the PlayOnMac version I am afraid.
Could the ini file also be written to the same folder as the cmd folder rather than the temp folder? I don't think that the ini file is being created as I can find no trace of it on my HDD.
Thanks for this but still not working for the PlayOnMac version I am afraid.
Could the ini file also be written to the same folder as the cmd folder rather than the temp folder? I don't think that the ini file is being created as I can find no trace of it on my HDD.
- tatewise
- Megastar
- Posts: 27088
- Joined: 25 May 2010 11:00
- Family Historian: V7
- Location: Torbay, Devon, UK
- Contact:
Re: Quick Link Creator
Teri, can you give more details about how the Plugin 'whined' and what path details are involved.
I wonder if FH needs to be reinstalled to correct the Windows Registry entry?
What version of Windows are you running? (Vista, 7, 8.1, 10, and is it 32-bit or 64-bit)
Jane, isn't it odd that that the Registry Key Read would not work?
Note that the default path on 32-bit PC will be C:\\Program Files\\Family Historian\\program\\fh.exe
You could also try Registry Key:-
HKLM\SOFTWARE\Calico Pie\Family Historian\2.0\Program Files Dir and append fh.exe
which must be accessible from FH as that is where it saves some Preferences.
I wonder if FH needs to be reinstalled to correct the Windows Registry entry?
What version of Windows are you running? (Vista, 7, 8.1, 10, and is it 32-bit or 64-bit)
Jane, isn't it odd that that the Registry Key Read would not work?
Note that the default path on 32-bit PC will be C:\\Program Files\\Family Historian\\program\\fh.exe
You could also try Registry Key:-
HKLM\SOFTWARE\Calico Pie\Family Historian\2.0\Program Files Dir and append fh.exe
which must be accessible from FH as that is where it saves some Preferences.
Mike Tate ~ researching the Tate and Scott family history ~ tatewise ancestry
- Jane
- Site Admin
- Posts: 8442
- Joined: 01 Nov 2002 15:00
- Family Historian: V7
- Location: Somerset, England
- Contact:
Re: Quick Link Creator
Colin, if you edit the batch file to use another folder does it then write the file, or is >> not supported in the emulator?
Jane
My Family History : My Photography "Knowledge is knowing that a tomato is a fruit. Wisdom is not putting it in a fruit salad."
My Family History : My Photography "Knowledge is knowing that a tomato is a fruit. Wisdom is not putting it in a fruit salad."