- t-do- write this:)
Read More- t-do- write this:)
Read MoreWell, if i had a gun near by, i'd definitely use that rather than the former 2. So here's the deal: i needed to send an object over the wire, and i decided on using Json. First pick: DataContractJsonSerializer. What i wanted to serialize is Filter definitions. 1 The way i decided on doing it is using a nice wrapper over DataContractJsonSerializer which would just take known types and do the serialization or deserialization. So basically this unit test should work 1 However, it fails miserably. It seems that DataContranctJsonSerializer has a problem with implicit conversion of types, even though the Date type is...
Read MoreOk, so i finally have a sensible working environment and it only took me one thing to achieve it - disabling that damn XAML designer! Anyway, right click XAML -> Open with -> Source Code (Text) Editor and set it as default. 80% less...
Read MoreSource: AutoCompleteBox with Text 2-way binding Ok, so basically you have a following problem: Say you have a PartnerName property on your Task entity, but you also have a Partner property. You want a PartnerName to be set, but if there's a Partner in your database with the same name, you also want your Partner property to be set with that particular partner through async call to database. I could bind the Text field of the out-of-box AutoCompleteControl but it acted up on me really weird, and basically it's unusable in this type of scenario. Basically the main problem was that...
Read MoreI think it's one of the most common scenarios around, you would like to bind a button set for use of typical operations. See those 3 little buttons next to the title? It's a very common case, having 3 generic buttons for CRUD operations over data right next to datagrid for ease of use. It can be whatever and you could effectively put there a few more, but this will suffice for showing off a nice way how caliburn.micro can make your life easier. So for instance you have this control with these generic buttons, and you called it ListButtons: 1 U use...
Read MoreOk, this one was a real pain in the ass. I would get this strange [Format_BadDateTime] error when trying to type in a Date in any of the DatePickers i would try to use. And only on Windows XP. If i would use it outside the DataForm my binding would just get broken and that would basically be it! On a different project, with similair setup i would get a [Arg_TargetInvocationException]. The problem occurs only if you're using non-English localization settings on client computer (which means date formats other than MM/dd/yyyy) on Windows xp. Well, i figured it out and it's the Range...
Read MoreAutoCompleteBox connected to web service is often needed solution, and there are many solutions out there that are bare bone ones, but using such powerful UI framework as Caliburn.Micro is can reap some interesting benefits. So here's my implementation. I decided to subclass AutoCompleteBox because i subclass all of the controls i use. I called it AltiAutoCompleteBox. A new event was added called PopulatingAsync and a new EventArg called PopulatingAsyncEventArgs: AltiAutoCompleteBox basically just adds another event PopulatingAsync which is called every time Populating event is called: 1 PopulatingAsyncEventArgs class is consisted of a Parameter and an action which will be called on ViewModel side when...
Read MoreOk, i get this error Index was outside the bounds of the array. and i always bang my head up the wall what to do with it. Anyway, it's the enum! I have a mapping where enums are stored in referenced table. If the table's empty, my code generator generates an empty enum. Empty enum then causes this exception. And that's basically it! Now off to change that whole enum deal into something...
Read MoreI needed a classic "where guid in" type of query to do (though i'm not sure if i should be thinking in that way when using linq:) so i poked around a bit, but couldn't find anything good. So here it is: 1 A classic example of usage would be something like this 1 We are basically selecting partners by partnerguid, it's very useful for paging and such. An ispiration for this type of solution came from the this blog post for catching future values. Hope this...
Read MoreMan, why do i always have to learn the stuff the hard way? I was doing a deployment of my RIA solution to the production server after a visual studio update (not sure if it's connected or not), and i would start getting these strange errors when trying to log in:
There was a failure using the default 'ProfileProvider'. Please make sure it is configured correctly. The database 'C:INETPUBWWWROOTAPP_DATAASPNETDB.MDF' cannot be opened because it is version 661. This server supports version 655 and earlier. A downgrade path is not supported. Cannot open user default database. Login failed. Login failed for user 'NT AUTHORITYNETWORK SERVICE'.... Read More
Recent Comments