Monday, August 25, 2008

Error showing reports for Team Projects on Team Site, when Team Foundation Server is installed on different server that WSS

When you have the following:

  • Team Foundation Server installed on ServerA
  • Windows Sharepoint Services installed on ServerB
  • Reporting Services installed on ServerC (or ServerA or any Server different of ServerB)
  • Assume you are creating Team Projects on WSS using the Uri http://ServerB/Sites

And you create a Team Project on TFS, which is configured to use WSS 3.0 (maybe it works onf WSS 2.0), maybe the following error message is showed when the page tries to display the reports:

The following registry key is not set: HKLM\Software\Microsoft\VisualStudio\9.0\TeamFoundation\ReportServer\80\Sites for Uri /Sites/[ProjectName]/_layouts/tfsredirect.aspx?IsReport=1&ReportName=Remaining+Work

This is 'cause the ServerB, where is installed WSS need to know the Uri for the Report Server to redirect you, on this case, you need to create the following key on the registry for the ServerB (where WSS is installed)

  • HKLM\software\Microsoft\VisualStudio\9.0\TeamFoundation\ReportServer\80\Sites

After created it, create the following String Values:
  • BaseReportsUrl with value http://ServerC/Reports
  • ReportsService with value http://ServerC/reportServer

With that key and values, the problem is resolved.

The reason for this, is because the WSS try to redirect your report to the server when Report Service is working, and for that reason need those keys on the registry.

Thursday, August 21, 2008

Connect Visual Studio 2005 with Team Foundation Server 2008

Trying Team Foundation Server 2008, i found the need to use projects created on Visual Studio 2005 with TFS 2008, but i found a problem.

Attempting to create a Team Project, i get an error with the following message:

Plugin error text: "The language id specified in the process template does not exist on the WSS server"

Searching on the web, i found the solution and how can i configure Visual Studio 2005 to work with TFS 2008, just follow the next:

1. We need use the TFS Client for VS 2005, it's the Team Explorer 2005, download from here: Team Explorer 2005

2. The problem bellow is when VS and the Team Explorer try to create the site in SharePoint 3.0, but VS 2005 works with SharePoint 2.0, on this point, if you take a look to the path \Microsoft Visual Studio 8\Common7\IDE\PrivateAssemblies and look the version of the file Microsoft.VisualStudio.TeamFoundation.TeamExplorer.dll, this need to be at least the version 8.0.50727.804, so we need to install (or reinstall) the VS 2005 Service Pack 1, this install the Team Explorer 2005 SP 1 too.
After installed, check if the version of the library is 8.0.50727.804.

3. The last step is install a hotfix for Visual Studio 2005, with it, VS 2005 can comunicate with Sharepoint 3.0, the hotfix is VS80sp1-KB932544-X86-ENU.exe



Remember, you can't install the hotfix without installing VS SP1 and when you install the Team Explorer 2005, you need to reinstall the VS SP1, that's the reason why you need to install VS SP1 after Team Explorer and not only the hotfix.

That's All

Wednesday, August 20, 2008

Change SQL Version without uninstall

If you want to change the SQL version, i.e. SQL Express Edition To SQL Standard, you can do it using the following:

1. Put the DVD on the Drive.
2. Start the installation from the command line (supose the DVD Drive it's e:\) using the following:

e:\setup SKUUPGRADE=1

3. Follow the instruction. If the instance to be updated is named, like myserver\sqlinstance, use the same name for the current instalation.

4. After the installation, you need to install all the SP for SQL.

Friday, August 15, 2008

Use Google Maps to display a route

I will show how to display a route using google maps on a web site.

1. go to http://code.google.com/apis/maps/ and get a key for your web site, you need a google mail account, and write your web site address, if you are working locally, type the URL like http://mycomputername/, this is because the web site can be displayed from other computer on the network, if we use http://localhost/, we can only use the page locally. If you are using a public web site, use http://mywebsite/

2. With your key, add the following lines between the head tag of your web page:
<head>
<
script src="http://maps.google.com/maps?file=api&v=2&key=mykey" type="text/javascript"> < / script>


Note the key=mykey, where mykey is the key you got from the google.

3. Add the folowing script between the head tag too, of your web page:

<script type="text/javascript">
function initialize()
{
var map;
//Verify if the browser is compatible
if (GBrowserIsCompatible()) {
//Create the map object, for the div with id map_canvas
map = new GMap2(document.getElementById("map_canvas"));
//Set the center of the map and the initial zoom
map.setCenter(new GLatLng(5.971217,-74.95697), //Center
6 // zoom from 1 to 15
);
//Create the line secuence
var polyline = new GPolyline([
new GLatLng(6.252507, -75.583191),
new GLatLng(6.342597, -75.555725),
new GLatLng(6.247046,-75.421143),
new GLatLng(6.118708, -75.187683),
new GLatLng(5.971217,-74.95697),
new GLatLng(5.807292, -74.602661),
new GLatLng(5.20857,-74.742737),
new GLatLng(4.646920, -74.093170)], //Line points array
"#ff0000", //Color for the line
5 //width
);
map.addOverlay(polyline); //Add the line to the map
//Add mark for the start
map.addOverlay(new GMarker(new GLatLng(6.252507, -75.583191)));
//Add mark for the end
map.addOverlay(new GMarker(new GLatLng(4.658555, -74.100037)));
//Create the map control to show diferent type of the map
var mapControl = new GMapTypeControl();
//Add the control to the map
map.addControl(mapControl);
//Add zoom in/out control
map.addControl(new GLargeMapControl());
}
}
< /script>

4. Asign the onload event to the body, the function initialize:
<body onload="javascript:initialize();">


5. Add the following div to the body, the div size will be the size of your map window in the explorer:


<div id="map_canvas" style="width: 500px; height: 300px">< /div>


note the div id, is the same used when creating the map object.

that's all, browse your web and enjoy the google maps.