Catalin
Posts: 7794
Joined: Wed Jun 13, 2018 7:49 am

Re: Extracting LibraryKey

Hello,

The trials are held into the following object, which is an array:
Screenshot_43.png
Screenshot_43.png (27.36 KiB) Viewed 9516 times

So, you can access it through the following:

Code: Select all

$proj = $advinst.loadproject(path)
$lic = $proj.Licensing
$lic.TrialsAndRegistrations
Finally, to retrieve the LibKey for that specific trial, use this:

Code: Select all

$lic.TrialsAndRegistrations[0].Registration.LibraryKey
Best regards,
Catalin
Catalin Gheorghe - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube
gopinathrbe
Posts: 60
Joined: Fri Sep 22, 2023 8:14 am

Re: Extracting LibraryKey

gopinathrbe wrote: Tue Jul 22, 2025 6:33 pm I want to get the LibraryKey from multiple trial configurations.

powershell
Copy
Edit
$advinst = New-Object -ComObject AdvancedInstaller
$proj = $advinst.LoadProject("your project path")
$licensing = $proj.Licensing
$libkey = $licensing.TrialsAndRegistrations.Registration.LibraryKey

However, it’s unclear how to access LibraryKey values if there are multiple trials defined.
Any update on this one?
Catalin
Posts: 7794
Joined: Wed Jun 13, 2018 7:49 am

Re: Extracting LibraryKey

Hello,

Please see my previous reply, as it addresses exactly that - how to navigate between multiple trials.

Best regards,
Catalin
Catalin Gheorghe - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube

Return to “Building Installers”