I sometimes run into issues with Mapped printers in Citrix. I found this Article on Citrix Support site (CTX 104375) updated recently as of April 14th 2016.
Default Printer not Mapped Properly within ICA Session
Symptoms or Error
The default printer is not mapped properly within the ICA session. The default printer cannot be property set or changed.
Note: Citrix Technical Support has seen instances in which NO printer can be set as default. Either there has been an absence of the registry key within the user profile or the user did not have sufficient permissions to alter their registry values. RDP printers showed the same behavior. Users were referred to Microsoft for further analysis.
Verify that the string case for the default printer under the following registry key:
Verify that it is the same case for the Network Printer under:
The printer name under the HKEY_CURRENT_USER\Printers\Connections registry key does not match the case of the printer name under HKEY_CURRENT_USER\Software\Microsoft\Windows NT\CurrentVersion\Windows:Device registry key.The printer name under the HKEY_CURRENT_USER\Printers\Connections registry key does not match the case of the printer name under HKEY_CURRENT_USER\Software\Microsoft\Windows NT\CurrentVersion\Windows:Device registry key.
When determining a user default printer, a function compares an array of all network printers to the client default printer. This function is case sensitive. If the printer name for the default printer is not exactly the same in both arrays, no default printer is found.
Refer to the following to observe more closely:
- EnumPrinters() is called with Info Level 2 as to gather all the printer names. Each name is stored in variable called varEnumPrinters. This function obtains the network printer names from the registry key HKEY_CURRENT_USER\Printers\Connections and store them all in the array varEnumPrinters.
- The default printer is determined for a user by querying the registry key HKEY_CURRENT_USER\Software\Microsoft\Windows NT\CurrentVersion\Windows : Device using GetProfileString() function. From this key a string formatted as follows is derived:
PRINTERNAME, winspool, PORT.
- Consider that the PRINTERNAME is stored in a variable called varGetProfileString.
- The list of printers from varEnumPrinters is construed to look for a match between varEnumPrinters and varGetProfileString.
- If a match exists, that printer is flagged as the default printer and the Presentation Server is informed.
- If it does not match, the Presentation Server does not have a default printer, so it must decide what the default printer will be for that client connection. Usually, the Presentation Server sets the first printer that was enumerated as default printer.
Preceding Step 3 is a vital point. When you do the comparison between varEnumPrinters and varGetProfileString, the function strstr() is used. Because this function is case sensitive, the comparison fails when the case of the strings does not match.