windows presentation foundation and directx

Recent Updates:

12/08/2009 Update: Apply Microsoft hostfix from KB955692 to bypass the need to add a user to the power users group. (WindowsServer2003-KB955692-x86-ENU.exe)

12/07/2009 Update: As usual, we fixed the issue with this specific WPF based application and forgot to add an update to this post. So to that we apologize. Onward to the specifics of what we found. DirectX in a multi user environment where applications were being shared by multiple users over platforms such as Citrix or Terminal Server client appeared to have user relevant issues. Since we had multiple users attempting to grab DirectX dll's and resources, and did not have the appropriate permissions, we would get some very odd activity when the video would attempt to paint via the ICA protocol. Note: this obviously did not occur with the standard admin access which threw us off initially.

By adding a user who was experiencing issues to the power users group locally on the server we were able to correct the video painting issue.


Issue: Windows Presentation Foundation application would not launch properly in its native form in Xenapp 5.

Details: Application loaded at runtime, a boot loader downloaded and transfered files from a file share on the nas to a users profile directory. Then at runtime the application would use the .net framework to compile via csc.exe (Visual C# command line compiler) and then run the application in the UI via the .net 3.5 framework sp2 medium.

What we found: as CSC.exe was compiling the code and rendering the form to the UI, the directX dlls (d3d9.dll, d3d8hk.dll, and d3d9caps.dll) would literally get confused as the form was rendered and painted to the clients screen over the ICA protocal.

imatest.exe : almost constantly looking for files in the wrong directory, and then ends up finding it in c:\programfiles\citrix\ima\mfappsal.dll. This type of activity is apparently normal, we know that in a non isolated/native application environment - you will see the following, although its almost annoying to how many cycles are spent looking for files.

9:34:52 AM IMATest.exe:9428 QUERY INFORMATION C:\Program Files\Citrix\HealthMon\Tests\Citrix\MfAppSal.dll NOT FOUND Attributes: Error

9:34:52 AM IMATest.exe:9428 QUERY INFORMATION C:\WINDOWS\system32\MfAppSal.dll NOT FOUND Attributes: Error

9:34:52 AM IMATest.exe:9428 QUERY INFORMATION C:\WINDOWS\system\MfAppSal.dll NOT FOUND Attributes: Error

9:34:52 AM IMATest.exe:9428 QUERY INFORMATION C:\WINDOWS\MfAppSal.dll NOT FOUND Attributes: Error

9:34:52 AM IMATest.exe:9428 QUERY INFORMATION C:\WINDOWS\system32\MfAppSal.dll NOT FOUND Attributes: Error

9:34:52 AM IMATest.exe:9428 QUERY INFORMATION C:\Program Files\Citrix\system32\MfAppSal.dll NOT FOUND Attributes: Error