Author Archives: poppyto

Deserialize nested Array property with Stream in JSON.net

Sometimes, you have to deal with importing big data files and the data is not really what you’ve expected. Here is a solution for handling Deserializing data with a nested property (array). You may need to add a Depth parameter … Continue reading

Posted in Non classé | Leave a comment

Optimize IN clause with LINQ Entity Framework with Ranges

Problem Suppose you have this simple query : if ids contains one million number, Linq provider will write a giant query like : You will have an exception because it’s too much for the SQL provider to execute this query.You’ll … Continue reading

Posted in Non classé | Tagged , , , , , | Leave a comment

TextBox Autocomplete – Crash AccessViolationException – Workaround

It seems a nogo, but there’s a bug with AutoCompletion on Winforms since years. (.net7 here)The only way to make it work is to set the source only once.If you try to have a dynamic Suggestion, you could set : … Continue reading

Posted in Non classé | Tagged , | Leave a comment

The solution for validating an email address (RFC compliant) in .net C#

It’s a common question : “How can I validate one email address” ? There are 0b10 (2) types of developers : lazy and ignorant. Lazy people always wins, because they do not reinventing the wheel, they prefer to search already done API. Ignorant people will probably use … Continue reading

Posted in Non classé | Leave a comment

WinRT Apps : Slow Compilation when you add WinRT components : Solution

PROBLEM When you create a Blank WinRT project (W8 or WP8.1) with Visual Studio, if you compile as it, it takes : 2 seconds => great ! BUT, if you just add a simple WinRT component library (winmd) as reference and build, it takes 12 to 15 … Continue reading

Posted in Non classé | Leave a comment

Solution to Empty Emulator List (plus 0x80070002) in Windows Phone SDK 8

Sometimes, Visual Studio fails and you can’t do anything. You can repair or reinstall but in this case it’s not works. PROBLEM : You can’t see any Emulators on Visual Studio : and when you try to compile it throws … Continue reading

Posted in Non classé | Leave a comment

Solution for blurry rendering with DirectX11 on Windows Phone 8

If you experienced a global blurry rendering on your screen when you use DirectX11 on your Windows Phone 8, you probably fails a thing : The swapchain size must be the screen size (means portrait), not the landscape size. So  : swapChainDesc.Width = 800;// swapChainDesc.Height = … Continue reading

Posted in Non classé | Leave a comment

Solution for Error ERROR_DLL_INIT_FAILED while Loading winmd file in Windows RT

If you experienced the Exception : Error in the DLL (Exception from HRESULT: 0x8007045a (ERROR_DLL_INIT_FAILED)) The solution is simple : You have to remove the main function. (I know, why the fonction “main” is called with DLL? idk :))

Posted in Non classé | Leave a comment

Solution for Error CO_E_ERRORINDLL while Loading winmd file in Windows Phone 8

If you experienced the Exception : Error in the DLL (Exception from HRESULT: 0x800401F9 (CO_E_ERRORINDLL)) The solution is simple : You Must Add the _WINRT_DLL flag in the compiler definitions.

Posted in Non classé | Leave a comment

Windows Phone Store 8 shows neutral titles instead of localized titles

Dear you, I experienced a bug in the Windows Phone 8 Store : I localized my app titles with the AppResLib.dll (& mui) and the tiles title were ok in the phone but the WP8 Store shown only the neutral language title. (on WP7 Store only, … Continue reading

Posted in Non classé | Leave a comment