This form template is browser-compatible, but it cannot be browser-enabled on the selected site !!!

May 21st, 2007 by unclaimed blog

Today we encountered this error at our current client location too. We were able to deploy forms to basic site collections but not able to deploy to certain site collections that fell under the following path format: http://servername/sites/sitecollection or the custom url: http://customurl/sites/sitecollection Didn't make much sense, we had activated all the necessary features and the Form Server components were properly installed. Finally we found a difference between a site collection where it…(read more)

IE 6.0 + MOSS 2007 + Office 2007

April 4th, 2007 by unclaimed blog

So, recently I had been facing an issue with my machine that I could not understand properly. I have Windows XP SP2, IE 6.0 with the patches, Office 2007 Professional on my machine and MOSS 2007 in the environment. Every time I accessed the MOSS team…(read more)

Microsoft Certified Partner!!!!

March 16th, 2007 by unclaimed blog

NGenious Solutions, Inc . is proud to announce that it has achieved Microsoft Certified Partner level in Mobility Solutions Competency . Microsoft competencies are achived by performing specialized work performed for customers, customer referrals, and…(read more)

Windows Vista Business….It Rocks!!!

February 25th, 2007 by unclaimed blog

So after all the hype, I have finally managed to install Windows Vista Business on my laptop. My hard drive crashed on me a couple of weeks ago and I got myself a new hard drive yesterday. So I figured why not give Windows Vista a try. NOTE: I have a…(read more)

Outlook 2007 Headaches

February 13th, 2007 by unclaimed blog

So, we have all been looking forward to Office 2007 release and I think everyone loves it for the most. I for one have been really impressed with a lot of features in the 2007 version. The one thing that is really beginning to bother me lately is Outlook…(read more)

I was tagged :)

February 11th, 2007 by unclaimed blog

  Just found out I was tagged by my friend Bob Fox . For all those who don't know me much yet, here's a little something about me:

1. Born and brought up in Mumbai (Bombay), India. Just as lively as NYC and great crowd.

2. I love singing and almost went on my way to become a singer. Lucky me, I found computers at the right time :) …though I often try something now and then.

3. I am a really lively person and love to laugh a lot. I love sports, especially Volleyball and cricket. I will watch a lot of football too..and the superbowl this year was great, however, I wonder where all those great superbowl ads went??

4. I have a lovely daughter -  Prisha (1 year old). She's is a great kid and brings me the most joy in the world.

5. At the end of the day, I just want to be a good person. I hate myself if I ever hurt anyone and try my best to make sure that I always keep the people around me happy.

You will see that I have written a lot of useless stuff here and that is because I can't think of many things to write about myself :) Just another normal person.

Always thankful to god for giving me some of the best people in this world as my friends.

Cheers,

nilaish

SQL Server 2005 Analysis Service set up for Project Server 2007

February 4th, 2007 by unclaimed blog

Recently also had the opportunity to set up SQL 2005 Analysis Server for Project Server 2007. Sad to say that I had not had the opportunity to install this so far, however, was still able to help the client set this up in a matter of hours.

If any one of you has installed Project Server 2003 and used analysis services with it for Portfolio analysis, know that it is pretty much a standard process and very easy to implement. However, Microsoft has once again managed to make this as another complicated project. Here we were just trying to make sure our environment was in place and that we could just install the SQL 2005 SP1 and DSO components so that we could set up SQL 2005 Analysis service, but that's not enough, this time around, in order to set up SQL 2005 Analysis services, you have to actually create a project in Visual Studio 2005 for Analysis services. It could be just a very basic project with no data in it, but when you build it, you get a .asdatabase file. You need to ship this file to the SQL Server 2005 Analysis Services box, and then use it to set up the Analysis services. I found that a lot different from what it was with SQL 2000.

Anyways, something new learnt again. I will post the actual steps soon once I have some screen prints from the install.

nilaish

MOSS 2007 and Project Server 2007

February 4th, 2007 by unclaimed blog

This was an interesting one. Last week I helped a client install MOSS 2007 and Project Server 2007 in a medium size farm. Interesting project. I was on the phone call for only 10 hours :) and helped the client set up MOSS 2007 properly and then set up Project Server 2007.

What I find interesting and not sure why Microsoft is going that route is that in order to install Project Server 2007 in a MOSS 2007 server farm, you need to install MOSS 2007 bits and Project Server 2007 bits on all servers in the farm.

This is way different from the 2003 versions where in the two could be on separate boxes and still be able to communicate with each other easily. I am not sure if we would have to buy additional licenses from Microsoft in this scenario or not.

However, let's just say the project was very interesting and a real challenge to implement. More details to follow up soon.

nilaish

SharePoint Search Query for UserProfiles

December 12th, 2006 by unclaimed blog

Following code shows how to use SQL search for UserProfile properties in SPS 2003. In the code here, I am searching for AccountName, FirstName, LastName, UserName, PreferredName by default. In addition, we are searching for all the public properties that were returned by the Topology Manager for the User Profiles.

 

The code is part of a web part which has a interface similar to that of the regular SharePoint search, but returns only UserProfile data.

 

The only important thing to note here that the path for PictureURL is different from the other properties for User Profiles.

 

The code searches for both Portal content and Non-Portal Content. It also allows you to build query and perform the "Contains" or "Is Exactly" clause for search restrictions.

 

The last section of the buildQuery function shows how to sort the results returned by Last Name.

 

This query is then embedded in to an XML as shown in the BuildMSQuery method. Most of the sample code shown around different web sites show how to only build the query but fail to mention how to embed it into an XML for the final search.

 

 

public string buildQuery()

{

string strxml = null;

 

string[] ssarray = m_SPSelected.Split(';');

if(this.val1.Value.Length > 0 || this.val2.Value.Length > 0 || this.val3.Value.Length > 0)

{

strxml = "SELECT " +

""DAV:href"";

strxml += ","urn:schemas-microsoft-com:sharepoint:portal:profile:AccountName"";

strxml += ","urn:schemas-microsoft-com:sharepoint:portal:profile:FirstName"";

strxml += ","urn:schemas-microsoft-com:sharepoint:portal:profile:LastName"";

strxml += ","urn:schemas-microsoft-com:sharepoint:portal:profile:UserName"";

strxml += ","urn:schemas-microsoft-com:sharepoint:portal:profile:PreferredName"";

 

for(int i = 0; i < ssarray.Length – 1; i++)

{

if ((ssarrayidea != "AccountName") && (ssarrayidea != "FirstName") && (ssarrayidea != "LastName") && (ssarrayidea != "PreferredName") && (ssarrayidea != "UserName"))

{

if(ssarrayidea == "PictureURL")

{

strxml += ","urn:schemas.microsoft.com:fulltextqueryinfo:" + ssarrayidea + """;

}

else

strxml += ","urn:schemas-microsoft-com:sharepoint:portal:profile:" + ssarrayidea + """;

}

}

}

strxml += "from ( TABLE Portal_Content..Scope() UNION ALL TABLE Non_Portal_Content..Scope() ) where ";

 

// Generate the conditions here now:

if(val1.Value.Length > 0 && lbclause1.SelectedValue == "Contains")

{

// First row has "Contains" clause

strxml += "(Contains("urn:schemas-microsoft-com:sharepoint:portal:profile:" + lbprops1.SelectedValue + "",'" + SPEncode.HtmlEncode(val1.Value) + "')) ";

}

else if(val1.Value.Length > 0 && lbclause1.SelectedValue == "Is Exactly")

{

// First row has "Is Exactly" Clause

strxml += " "urn:schemas-microsoft-com:sharepoint:portal:profile:" + lbprops1.SelectedValue + ""='" + SPEncode.HtmlEncode(val1.Value) + "' ";

}

 

// Add the AND or OR conditions

if ((val1.Value.Length > 0 && val2.Value.Length > 0) || (val1.Value.Length > 0 && val3.Value.Length > 0))

{

strxml += lbcondition.SelectedValue;

}

 

// Row 2 processing

if(val2.Value.Length > 0 && lbclause2.SelectedValue == "Contains")

{

// Second row has "Contains" clause

strxml += "(Contains("urn:schemas-microsoft-com:sharepoint:portal:profile:" + lbprops2.SelectedValue + "",'" + SPEncode.HtmlEncode(val2.Value) + "'))";

}

else if(val2.Value.Length > 0 && lbclause2.SelectedValue == "Is Exactly")

{

// Second row has "Is Exactly" Clause

strxml += " "urn:schemas-microsoft-com:sharepoint:portal:profile:" + lbprops2.SelectedValue + ""='" + SPEncode.HtmlEncode(val2.Value) + "' ";

}

 

// Add the AND or OR conditions between second row and third row

if ((val1.Value.Length > 0 && val3.Value.Length > 0) || (val2.Value.Length > 0 && val3.Value.Length > 0))

{

strxml += lbcondition.SelectedValue;

}

 

// Row 3 processing

if(val3.Value.Length > 0 && lbclause3.SelectedValue == "Contains")

{

// Third row has "Contains" clause

strxml += "(Contains("urn:schemas-microsoft-com:sharepoint:portal:profile:" + lbprops3.SelectedValue + "",'" + SPEncode.HtmlEncode(val3.Value) + "'))";

}

else if(val3.Value.Length > 0 && lbclause3.SelectedValue == "Is Exactly")

{

// Third row has "Is Exactly" Clause

strxml += " "urn:schemas-microsoft-com:sharepoint:portal:profile:" + lbprops3.SelectedValue + ""='" + SPEncode.HtmlEncode(val3.Value) + "' ";

}

 

// Added code to sort results by last name

strxml += " ORDER BY "urn:schemas-microsoft-com:sharepoint:portal:profile:LastName"";

return strxml;

}

 

/// <summary>

/// Builds an MSQuery with an embedded MSSQLFT query embedded

/// for submission to SharePointPS Query Service.

/// </summary>

/// <param name="keywords">Keywords submitted for search.</param>

/// <param name="searchScope">SPS Search scope to filter.</param>

/// <returns>MSQuery</returns>

public string BuildMSQuery(string queryXml)

{

if(queryXml == null)

return null;

 

StringBuilder msQuery = new StringBuilder();

 

// create the main header of the XML string

msQuery.Append("<?xml version="1.0" encoding="utf-8" ?>"

+ "<QueryPacket xmlns="urn:Microsoft.Search.Query" "

+ "Revision="1000">"

+ "<Query domain="QDomain">"

+ "<SupportedFormats>"

+ "<Format>urn:Microsoft.Search.Response.Document.Document"

+ "</Format></SupportedFormats>");

 

// create the actual full-text query

msQuery.Append("<Context>"

+ "<QueryText language="en-US" type="MSSQLFT">"

+ "<![CDATA[" + queryXml

+ "]]></QueryText></Context>");

 

// create the range, page, and number of results to return

msQuery.Append("<Range><StartAt>1</StartAt><Count>" + M_MaxReturnResults + "</Count>"

+ "</Range></Query></QueryPacket>");

 

return msQuery.ToString();

}

 

The XML should be passed to the Query or QueryEx function of the search web service:

PortalContext ctx = PortalContext.Current;

site = ctx.SiteUrl;

usrprof.Search.QueryService qs = new usrprof.Search.QueryService(site + "_vti_bin/search.asmx");

qs.Credentials = System.Net.CredentialCache.DefaultCredentials;

strresults = qs.Query(queryXml);

results = qs.QueryEx(queryXml);

RenderWebPart and ToolPart Pane

December 12th, 2006 by unclaimed blog

 

Recently when I was working on a web part, I ran across a small problem. I was writing a custom ToolPart Panes and my code seemed to work properly, but when I tried viewing my ToolPart it would appear all weird on the screen. I was at some point able to access all the properties in my ToolPart but the screen would look completely different.

 

After some working through the code, I found out that the HTML that is used in the RenderWebPart method is related to the HTML on the ToolPart Pane. My HTML in the RenderWebPart method was incomplete and hence it was messing up the ToolPart Pane.

 

I found that weird and completely wrong since the ToolPart Pane shows up in a different frame on the same page and would not have thought that they were related.

 

Anyways, something to keep in mind when writing web parts again.

 

nilaish