Top 3 Sites Searched

July 10th, 2007 by mosslover

We had a meeting at my client site the other day and the guy we built the site we were demoing came up with an interesting idea.  He wants us to be able to display the top 3 sites visited by a user in a webpart.  I think this idea is incredibly interesting, so right now I am doing all kinds of insane research.  I have never touched the Sharepoint Object Model related to search.  The most I have ever done with search deals with SPS 2003, where I added a few content indexes and scopes.  I promise you guys I will try and post that example I promised, but I am not entirely sure when it will get posted.  I also promise to blog about the solution I find for this problem.

SQL Server Webpart for Document Library Creation is Conquered

July 5th, 2007 by mosslover

I swapped out the username and added an 's' to the table name.  Sometimes it's very minuscule errors that cause problems with the entire lump of code.  I am still having problems with the BDC Version, however I am not ready to tackle it again just yet and will save it for a later date.  As far as I know the Sql Server Version of this webpart is just as speedy as the BDC Version.  I definitely think the concept of pulling data from a BDC Webpart to create sites or document libraries sounds like a good idea.  Unfortunately, I spent an entire week trying to debug it, so I need to take at least a one week break from debugging it.  I need to come back to it with a fresh perspective.  If anyone is interested in the working SQL Server Version of the webpart I can post a full version of the sample code.  I will only post it if someone expresses interest.

BDC Webpart Update

July 2nd, 2007 by mosslover

I went through and commented out most of the code up until the point where it calls the SSP.  I am pretty sure there something wrong with the SSP Name.  I have tried typing in the name of the SSP and it still does not work.  I am going to test it again today to see if somehow I can get it to work.  If anyone wants to use that code and play around with it there should be no problems if they use the SSP name and not the url of the SSP I believe.  I think there is something off about the permissions or the fact that there is no DNS Entry for the SSP.  I will keep you guys posted. 

Duking it Out with the BDC Object Model in a Webpart

June 28th, 2007 by mosslover

I created a webpart that could create document libraries pulling in client names and ids from a sql server instance.  Unfortunately, it did not work in the production environment for some reason or another, so my colleague thought it might be  a good idea to use his BDC Instance.  I thought this was a good idea, but I am not very familiar with code related to the BDC.  I went to MSDN and Sezai's Blog to find some code.  I debugged the code a bit and added the proper references and import statements.  When I tested the webpart for some reason it did not work.  I am not 100% sure, but it's feeling as though the SSP is not opening properly.  I tried to get more information from the event log without luck.  If anyone wants to see what it looks like here is my code block(who knows maybe there is a tiny problem someone sees):

Dim SSPName As String

SSPName = "http://sspwebapp"

SqlSessionProvider.Instance().SetSharedResourceProviderToUse(SSPName)

Dim sysinstances As New NamedLobSystemInstanceDictionary

sysinstances = ApplicationRegistry.GetLobSystemInstances()

 

Dim NationalClientInstance As LobSystemInstance

NationalClientInstance = sysinstances("NationalClientsApp")

Dim NationalClients As Entity

NationalClients = NationalClientInstance.GetEntities()("NatClient")

Dim fc As New FilterCollection

fc = NationalClients.GetFinderFilters()

Dim NCEntityInstanceEnumerator As IEntityInstanceEnumerator

NCEntityInstanceEnumerator = NationalClients.FindFiltered(fc, NationalClientInstance)

 

While (NCEntityInstanceEnumerator.MoveNext())Dim row As DataRow

row = ClientTable.NewRow()

 

 

Dim IE As IEntityInstance

IE = NCEntityInstanceEnumerator.Current

row("ID") = IE("ID").ToString()row("Name") = IE("Name").ToString()

ClientTable.Rows.Add(row)

End While

 

I am pretty confident the part relating to the document library creation works as it worked in my VPC.  Also, if anyone has some good suggestions for other projects please let me know.  I love working with the Sharepoint Object Models and creating applications and webparts.

Looking for the Kansas City Sharepoint User Group Members

June 26th, 2007 by mosslover

I found a website for the Kansas City Sharepoint user Group at http://sharepointusergroup.corasworks.net/kc1/default.aspx.  Every once in a while I go there and I am entirely too late to attend any of there events or they are in the afternoon when I was working.  I wanted to try and contact someone from the user group, but I can not find any type of contact information.  Maybe I am not looking hard enough or maybe Google has finally failed me.  Either way I have hit a roadblock and I urge anyone who has any type of contact information to come forward please.  I will be eternally grateful to that person.  I am also curious what the Sharepoint Community is like in Kansas City (big, small, active, non-active…).  I am willing to help you guys out in any way.  I hope to hear from you soon.

Silverlight for Linux

June 26th, 2007 by mosslover

I was reading Slashdot today and found this insane entry about a guy who created Silverlight for Linux (more like a guy who encouraged and contributed to a bunch of people hacking into the MS version, but still cool).  Here is a link to his blog: http://tirania.org/blog/archive/2007/Jun-21.html.  It only took 21 days to hack into Silverlight and create this version.

Welcome Back Everyone!

June 21st, 2007 by mosslover

A lot has happened since I last posted.  I bought a plane ticket to Los Angeles, got braces, and did some cool things with Sharepoint.  I actually took the webpart I used to create a single site and modified it.  Now I can pull from a database the host header and site name/description from a database in sql server.  I wrote a dataset in vb .net that pulls an id and name in bulk.  I added a ui to the webpart that allows the person to input values in case they don't want to kill Sharepoint and create 100+ sites.  The bulk site creator is what I did last week.  This week I actually went out and created a batch file that takes a back up of the SSP and Site Collection in Sharepoint.  I ran it once, then hooked it into Windows Scheduler.  I had a weird notion to throw it into my VPC and see what happens.  It turns out I can create a perfect backup minus some items, such as the BDC, because I did not hook it into the SSP or share the ADF.  I may export the ADF that my colleague created and play around with it today while we wait for more projects.  Sometimes it drives me insane how much time it takes to hash out the correct prototypes and sites in the beginning of a Sharepoint Implementation.  This is the second time I am at a client site just figuring out what Sharepoint can and cannot do.  I usually swoop in after Sharepoint is implemented and fix or modify a site collection someone else broke or needs enhancing.  It is a far different perspective than the usual.  I will probably look back in a couple of months and say "wow this was cool I got to see everything from planning to user implementation".  Anyway, that's my scatterbrained first entry since the great server crash of 07, so I guess I will catch you guys later.

Building a Site Creation Webpart – How do you get a list of templates?

May 29th, 2007 by mosslover

I am playing around with a webpart in my new VPC that will inevitably create a site based on what a user inputs to a combo box and a couple text boxes.  I can get the user to create the site if I hardcode in the id for the template name, however I want to get all the template codes and shove them into a combo box.  Then the user can choose which template they want.  My problem comes when I need to figure out what code is used to actually pull in the template code list to the combo box.  Has anyone experimented with the object model at all?  If so does anyone know how I would go about solving the problem I have or at least know of some website with some sample code?  After I am done with the template part I am going to work on a couple textboxes, where the user can input a couple usernames to add to this site.  Thanks for any help in advance.  If anyone would like me to post the code when I am done I will most definitely do so.

VPC Conversion to VMWare

May 25th, 2007 by mosslover

Andrew Connell had an interesting post on his blog a few days ago discussing VMWare vs. VPC (http://andrewconnell.com/blog/archive/2007/05/22/6052.aspx).  I had been toying with the idea of using the VMWare Conversion tool on my MOSS 2007 VPC once I finally fished it.  Two Days ago I went to the VMWare Site and downloaded the conversion tool plus VMWare Workstation 5.5 from my company.  I noticed a couple differences.  When you load up the VMWare version I was able to go to the host computer and keep Outlook open plus surf the web without any memory problems.  I am constantly unable to open anything on my host machine when I use a VPC 2007 image, even when running an optimized image.  Also, my MOSS 2007 Sites loaded incredibly fast compared to the VPC Image and I could run a few programs in the VPC, including VS 2005, IIS, and about 3 other windows of who knows what, without any kind of performance degradation on the host machine.  The only problem I had is that I could not figure out how to create an equivalent to a differencing disk and/or an undo disk.  Granted the conversion took a total of 15 minutes at most, however I don't want to keep converting my VPC Image multiple times.  Right now I am working Microsoft Sharepoint:Building Office Solutions in VB 2005.  I am hoping to build a couple test web parts before things get hectic.

Trials with a VPC

May 22nd, 2007 by mosslover

So a couple weeks ago I decided that I wanted to toy with a VPC and MOSS 2007 for testing purposes.  I started up a VPC on my external hard drive that was dynamically expanding with 15 gb of space.  About a week later and 15 unplugs to my VPC I had completely eaten all of the possible space on the virtual disk.  I had messed up the hard disk so bad by unplugging it.  Unfortunately, I forgot to install the add-ons that would allow me to create an undo disk.  I was so frustrated that I completely deleted the hard disk and the virtual machine.  I gave up for about 3 weeks.  For some reason last Friday I decided to try again.  I shoved my power cable into a position where I would not completely unplug it and I tried yet again.  This time I followed the internet guide I had found pretty closely (http://www.pptspaces.com/sharepointreporterblog/Lists/Posts/AllPosts.aspx).  Right now I have a fully working MOSS 2007 VPC with Office 2003 and 2007 working side by side.  I am hoping within the next week I can start writing some basic applications to create MOSS 2007 websites.  I am starting to read Developer's Guide to Windows Sharepoint Services 3.0 by Todd Bleeker, so that I can check on the differences in object models from 03 to 07.  I will keep everyone posted on what happens.  Who knows I may be writing a great post on how to virtually eradicate a MOSS 2007 VPC using code…I'm also officially moving to Kansas City from St. Louis, so I may end up incredibly frustrated with the external hard drive slammed against the cubicle wall.