
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎11-19-2021 09:13 AM
Hi,
We just recently moved to Lansweeper and now we are doing the firsts deployment packages. We wanted to upgrade Firefox and noticed there is so many different versions: three different languages version and two more with ESR. At the moment we don't want to limit which languages the users use but it should be the latest version. Now when we search for Firefox we got 12 different items, so there are a plenty of old versions too.
We have created a deployment which basically check if HKEY_LOCAL_MACHINE\SOFTWARE\Mozilla\Mozilla Firefox\CurrentValue has a value en-US (or de, or us-GB, ESR en-US, ESR de) and then continues to correct installation. Question is, can we (how) to create wildcard for different version value, like * en-US? Already tried *, %, && but no luck. The deployment works nicely when there is a new condition with exact value, like: 63.0.3 (x64 de)
Of course when everything is the latest version we can easily use the whole value and we can do it manually for the first time, but this is not the only case. We have several similar situation before our systems are up to date...
Any help would be appreciate!
We just recently moved to Lansweeper and now we are doing the firsts deployment packages. We wanted to upgrade Firefox and noticed there is so many different versions: three different languages version and two more with ESR. At the moment we don't want to limit which languages the users use but it should be the latest version. Now when we search for Firefox we got 12 different items, so there are a plenty of old versions too.
We have created a deployment which basically check if HKEY_LOCAL_MACHINE\SOFTWARE\Mozilla\Mozilla Firefox\CurrentValue has a value en-US (or de, or us-GB, ESR en-US, ESR de) and then continues to correct installation. Question is, can we (how) to create wildcard for different version value, like * en-US? Already tried *, %, && but no luck. The deployment works nicely when there is a new condition with exact value, like: 63.0.3 (x64 de)
Of course when everything is the latest version we can easily use the whole value and we can do it manually for the first time, but this is not the only case. We have several similar situation before our systems are up to date...
Any help would be appreciate!
Solved! Go to Solution.
Labels:
- Labels:
-
General Discussion
1 ACCEPTED SOLUTION

Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎11-19-2021 04:08 PM
Naksu wrote:
Hi,
We just recently moved to Lansweeper and now we are doing the firsts deployment packages. We wanted to upgrade Firefox and noticed there is so many different versions: three different languages version and two more with ESR. At the moment we don't want to limit which languages the users use but it should be the latest version. Now when we search for Firefox we got 12 different items, so there are a plenty of old versions too.
We have created a deployment which basically check if HKEY_LOCAL_MACHINE\SOFTWARE\Mozilla\Mozilla Firefox\CurrentValue has a value en-US (or de, or us-GB, ESR en-US, ESR de) and then continues to correct installation. Question is, can we (how) to create wildcard for different version value, like * en-US? Already tried *, %, && but no luck. The deployment works nicely when there is a new condition with exact value, like: 63.0.3 (x64 de)
Of course when everything is the latest version we can easily use the whole value and we can do it manually for the first time, but this is not the only case. We have several similar situation before our systems are up to date...
Any help would be appreciate!
I have a thought. The script below will take the CurrentVersion registry key value, split it, and create a new value called Language which is just a combination of the install type and language, example, x64 en-US. If you modify your conditions, you should be able to tell it to look for the newly created Language value as a basis for knowing what version it needs to install without the need for any kind of wildcard. The script also includes a piece that deletes the value if it already exists just in case something happens and the language is modified.
$location = 'HKLM:\SOFTWARE\Mozilla\Mozilla Firefox\'
$languageExists = $false
$languageExists = (Get-ItemProperty $location).PSObject.Properties.Name -contains "Language"
IF ($languageExists -eq $true) {
Remove-ItemProperty -Path $location -Name 'Language'
}
$language = Get-ItemProperty $location | select-object 'CurrentVersion' -ExpandProperty 'CurrentVersion'
$language = $language.Split("{()}",3)[1]
New-ItemProperty -Path $location -Name 'Language' -Value $language -PropertyType 'String'
5 REPLIES 5

Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎11-22-2021 12:17 PM
Thank you Paolo and RKCar!
I think I managed to make it work now. Only 13 steps on deployment.
I think I managed to make it work now. Only 13 steps on deployment.

Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎11-22-2021 08:43 AM
Thank you for your replies.
I'm not familiar with VBS scripts so that probably won't work out. How can I use this Powershell script as a condition? I run it on my computer and got the nice results telling which language I have, but I don't have no idea how to implement that to Lansweeper.
Thank you for the reply!
I'm not familiar with VBS scripts so that probably won't work out. How can I use this Powershell script as a condition? I run it on my computer and got the nice results telling which language I have, but I don't have no idea how to implement that to Lansweeper.
Thank you for the reply!

Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎11-22-2021 09:29 AM
Naksu wrote:
Thank you for your replies.
I'm not familiar with VBS scripts so that probably won't work out. How can I use this Powershell script as a condition? I run it on my computer and got the nice results telling which language I have, but I don't have no idea how to implement that to Lansweeper.
Thank you for the reply!
Hi Naksu,
you should use the PowerShell script as the first step, maybe setting the condition that the base Firefox registry does exist.
You can then use the newly created registry 'Language' in a condition to run the appropriate upgrade deployment in the following steps.
Bye.
Paolo.

Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎11-19-2021 04:08 PM
Naksu wrote:
Hi,
We just recently moved to Lansweeper and now we are doing the firsts deployment packages. We wanted to upgrade Firefox and noticed there is so many different versions: three different languages version and two more with ESR. At the moment we don't want to limit which languages the users use but it should be the latest version. Now when we search for Firefox we got 12 different items, so there are a plenty of old versions too.
We have created a deployment which basically check if HKEY_LOCAL_MACHINE\SOFTWARE\Mozilla\Mozilla Firefox\CurrentValue has a value en-US (or de, or us-GB, ESR en-US, ESR de) and then continues to correct installation. Question is, can we (how) to create wildcard for different version value, like * en-US? Already tried *, %, && but no luck. The deployment works nicely when there is a new condition with exact value, like: 63.0.3 (x64 de)
Of course when everything is the latest version we can easily use the whole value and we can do it manually for the first time, but this is not the only case. We have several similar situation before our systems are up to date...
Any help would be appreciate!
I have a thought. The script below will take the CurrentVersion registry key value, split it, and create a new value called Language which is just a combination of the install type and language, example, x64 en-US. If you modify your conditions, you should be able to tell it to look for the newly created Language value as a basis for knowing what version it needs to install without the need for any kind of wildcard. The script also includes a piece that deletes the value if it already exists just in case something happens and the language is modified.
$location = 'HKLM:\SOFTWARE\Mozilla\Mozilla Firefox\'
$languageExists = $false
$languageExists = (Get-ItemProperty $location).PSObject.Properties.Name -contains "Language"
IF ($languageExists -eq $true) {
Remove-ItemProperty -Path $location -Name 'Language'
}
$language = Get-ItemProperty $location | select-object 'CurrentVersion' -ExpandProperty 'CurrentVersion'
$language = $language.Split("{()}",3)[1]
New-ItemProperty -Path $location -Name 'Language' -Value $language -PropertyType 'String'

Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎11-19-2021 03:58 PM
Hi Naksu,
the feature to search registries with wildchars has already been requested, but not yet implemented.
What about writing a VBS script that search and read the registry key and possibly starts the corresponding installation accordingly to the value found (or creates the conditions to select and start the right installation)?
Bye.
Paolo
the feature to search registries with wildchars has already been requested, but not yet implemented.
What about writing a VBS script that search and read the registry key and possibly starts the corresponding installation accordingly to the value found (or creates the conditions to select and start the right installation)?
Bye.
Paolo
