Geeks With Blogs

News My Blog has been MOVED to
Michael Freidgeim's OLD Blog My Blog has been MOVED to October 2012 Entries
Helper method to Replace/Remove characters that do not match the Regular Expression
I have a few fields, that use regEx for validation. In case if provided field has unaccepted characters, I don't want to reject the whole field, as most of validators do, but just remove invalid characters. I am expecting to keep only Character Classes for allowed characters and created a helper method to strip unaccepted characters. The allowed pattern should be in Regex format, expect them wrapped in square brackets. function will insert a tilde after opening squere bracket , according to ......

Posted On Sunday, October 28, 2012 1:30 PM

maxItemsInObjectGraph limit required to be changed for server and client
We have a wcf service, that expects to return a huge XML data. It worked ok in testing, but in production it failed with error "Maximum number of items that can be serialized or deserialized in an object graph is '65536'. Change the object graph or increase the MaxItemsInObjectGraph quota."The MSDN article about dataContractSerializer xml configuration element correctly describes maxItemsInObjectGraph attribute default as 65536, but documentation for of the DataContractSerializer.MaxI... ......

Posted On Sunday, October 28, 2012 1:02 PM

PostSharp deployment to build machine- use Setup installation, not NuGet package.
PostSharp has well documented different methods of installation. I've chosen installing NuGet packages, because according to Deploying PostSharp into a Source Repository NuGet is the easiest way to add PostSharp to a project without installing the product on every machine. However it didn't work well for me. I've added PostSharp NuGet package to one project in the solution. When I wanted to use PostSharp in other project, Visual Studio tab showed that PostSharp is not enabled for this project I've ......

Posted On Wednesday, October 17, 2012 10:04 PM

Missing error handling in Streaming-AJAX-Proxy Log
We are using AjaxProxy(FROM on our web site, but started to notice errors accessing log.txt file. I found that the file is created by Log class and doesn't have ability to switch it off and error handling. I've added reading file name from configuration and try/catch block public static class Log { private static StreamWriter logStream; private static object lockObject = new object (); public static void WriteLine(string msg) { string logFileName ......

Posted On Saturday, October 6, 2012 12:49 PM

Copyright © Michael Freidgeim | Powered by: