Share MVC PartialView between server and client
In MVC you can divide a big view into smaller partial views, while with ajax these partial views can also be used by ajax to do partial update of an already rendered page. Read the rest of this entry »
Web Application Development and Engineering
In MVC you can divide a big view into smaller partial views, while with ajax these partial views can also be used by ajax to do partial update of an already rendered page. Read the rest of this entry »
When you try to bind a model field with a dropdownlist in view, you need to create a SelectList in controller then pass that SelectList to view from ViewBag or ViewData, normally there will be a conversion happening from your collection to SelectList, Read the rest of this entry »
When using MEF, you might one day find a class that is marked as export is not exported. Having a look at the trace window in VS, there is a line as:
More than one export was found that matches the constraint:
ContractName XXXX
RequiredTypeIdentity XXXX
Resulting in: Cannot set import ‘YYYY..ctor (Parameter=”operand1″, ContractName=”XXXX”)’ on part ‘YYYY’.
Read the rest of this entry »
You might be confused that when lifetime of parts that are created by MEF container.GetExportedValues appeared to be NOT controlled by their container. the confusion comes from that fact that most of MEF documentations have not mentioned that parts could be referenced by other objects in your system apart from container, in that case, container will not be responsible for life time of parts SOLELY. Read the rest of this entry »
Here is a complete example of using wcf and ajax via JQuery, the configuration for wcf under ssl is also included. Read the rest of this entry »