Sunday, January 30, 2011

Refresh UpdatePanel using JavaScript

In case you'd like to refresh the content of UpdatePanel by javascript (e.g. after PageMethod call, etc.), use following syntax:

__doPostBack('<%=UpdatePanel1.ClientID %>', '');

Notice, that you have to use the ClientID of the control!

Thursday, January 27, 2011

TFS 2008 to 2010 migration

I'll be migrating my TFS 2008 server (32bit) to TFS2010 (64bit) soon. I'll have to completely reinstall the machine, so this is my reading so far:


Monday, January 17, 2011

Hidden workspaces in TFS

I've ran into an issue where I had to switch user under which i was connecting to TFS. Somehow workspace from my previous account was still present in the system and checking out solution to the same folder under the new workspace ended up with errors.
There's a tool called Team Foundation Sidekicks which can help to resolve this situation. You can view all workspaces, modify them, etc... Awesome tool, free one too!

Thursday, January 13, 2011

ASP.Net Web Service Reference error

I've encountered interesting error when dealing with web-services in Web Site (ASP.Net 4.0).
Scenario:
MyWeb - ASP.Net 4.0 web site project
MyService - ASP.Net WCF service
MyCode.dll - library share user by both, MyWeb and MyService.

Now, the issue is when you change MyCode, recompile MyService and do "Update Service Reference" in the MyWeb. What I found, that I start getting compilation errors saying that the client class from the MyService reference is not known (as if the reference was missing).

Cause: The MyWeb project was referencing the MyCode library not as a project, but rather as DLL reference.

Solution: Quite obvious - either use project reference or update the DLL used by the web-site.

This behavior is to be expected, however if you don't realize that you're not using same DLL version from both MyService and MyWeb, it can be quite confusing.