Archive for March 2014
Get App-V 5.0 Command Line Hook Switch with PowerShell
The App-V 5.0 Command Line Hook Switch can be used to allow local applications to run inside an App-V Virtual Environment. This way packaged applications, such as a sequenced browser plug-in, can interact with locally installed applications, such as Internet Explorer.
Assembling the Command Line Hook Switch can be tricky because it requires you to retrieve the package GUID and version GUID and concatenate them with an underscore in between. The full format looks like this: /appvve:<PACKAGEGUID_VERSIONGUID>.
To do this quickly, you can copy and run this single line of Powershell code:
Copy the last line of the output and add it as a parameter to your application shortcut.
For more information about the App-V Command Line Hook Switch see the following article: How to launch processes inside the App-V 5.0 virtualized environment (KB2848278)
Assembling the Command Line Hook Switch can be tricky because it requires you to retrieve the package GUID and version GUID and concatenate them with an underscore in between. The full format looks like this: /appvve:<PACKAGEGUID_VERSIONGUID>.
To do this quickly, you can copy and run this single line of Powershell code:
$AppName = Read-Host "Enter package name"; If($AppVClientPackage = Get-AppVClientPackage $AppName) { Write-Host ("App-V Command Line Hook Switch:`n/appvve:" + $AppVClientPackage.PackageId + "_" + $AppVClientPackage.VersionId) } Else { Write-Host "Package not found." }
Result
![]() |
Powershell Script to assemble the App-V Command Line Hook Switch |
Copy the last line of the output and add it as a parameter to your application shortcut.
For more information about the App-V Command Line Hook Switch see the following article: How to launch processes inside the App-V 5.0 virtualized environment (KB2848278)
New Tab Page in Internet Explorer displays Black Background
Symptoms
- The page for a new tab ("Frequent") displays a black background.
- On a server you might experience group policy settings related to internet security zones not being applied correctly.
- Zone icons might be displayed with a lock icon in front (prior to Internet Explorer 11).
![]() |
Internet Explorer New Tab Black Background |
Cause
I discovered the cause on our Remote Desktop Server / Citrix XenApp 6.5 environment was that the (mandatory) profile was missing theme related registry settings. This profile was created by copying the default user profile or a new user without enabling a theme for this user first.Solution
The solution was to configure a Windows Aero / Basic theme for the template user before copying or converting it into a mandatory profile.![]() |
Internet Explorer New Tab Regular Background Color |
References
Other suggested solutions include:- Add the missing registry keys related to the Windows theme manually, through a logon script or Group Policy Preferences. [1]
- Change to and fro a different theme. [2]
- Reset Internet Explorer settings to defaults.
- Disable Internet Explorer Enhanced Security Configuration (IE ESC) before installing the Desktop Experience Feature of Remote Desktop Services.
Set Mailbox Type to Room, Equipment or Shared in Exchange based on Name with Powershell
Besides regular mailboxes Exchange has the option of flagging mailboxes as a Room or Equipment mailbox. These so called Resource mailboxes can be added to an appointment by which users can use Outlook as a reservation system for conference rooms and video projectors.
To convert regular mailboxes that are used in this manner in an existing environment to Resource mailboxes can be time-consuming. Therefore I wrote a PowerShell script that sets the flag based on the occurence of certain words in the name of the mailbox. This script asumes your shared/resource mailboxes are in their own organizational unit.
Shared mailboxes have the added benefit of not requiring a license in Office 365 as they are represented by a disabled user account. One of the conditions however is that their size remains below 10 gigabytes and it is not possible to use ActiveSync with such accounts.
On to the script. First enable remote PowerShell to your Exchange server for the script session.
$Session = New-PSSession -ConfigurationName Microsoft.Exchange -ConnectionUri http://<FQDN of Exchange Server>/PowerShell/ -Authentication Kerberos Import-PSSession $Session
Next declare this simple function to search the name for the occurence of a list of search terms.
function inArray([String]$searchTerm, [Array]$searchArray) { ForEach($term in $searchArray) { if ($searchTerm -match $term) { return $true } } return $false }
Define the search terms (substrings that are part of the mailbox name) that would define it as a Room or Equipment mailbox.
In this case the terms are in Dutch, but you can replace these with for example: "room", "office", "floor" and so on.
$roomSearchTerms = "ruimte", "kamer", "zaal", "kantoor", "lokaal", "cabine" $equipmentSearchTerms = "projector", "beamer", "laptop"
Define the OU wherein your shared mailboxes reside.
$organizationalUnit = "OU=Mail,OU=Groups,DC=domain,DC=local"
Finally the query and operations for each mailbox happen here.
$mailboxes = Get-Mailbox -OrganizationalUnit $organizationalUnit -ResultSize Unlimited ForEach ($mailbox in $mailboxes) { if (inArray ($mailbox.Name) $roomSearchTerms) { Set-Mailbox -Identity $mailbox.WindowsEmailAddress -Type Room } elseif (inArray ($mailbox.Name) $equipmentSearchTerms) { Set-Mailbox -Identity $mailbox.WindowsEmailAddress -Type Equipment } else { Set-Mailbox -Identity $mailbox.WindowsEmailAddress -Type Shared } }
The end result in the Address Book after running the script looks something like this:
![]() |
Outlook 2013 All Rooms |
Great succes! Modify and use at your own risk.
Download the script: setResourceMailboxes.ps1