Thursday, February 22, 2007 11:32 AM Jan Tielens

SmartPart for SharePoint - ASP.NET AJAX Support

There has been a lot of buzz around SharePoint support for ASP.NET AJAX the last couple of days, resulting in some nice posts, even from the Microsoft guys. If you are new to the topic; some required reading:

  • Integrating ASP.NET AJAX with SharePoint (by Mike Ammerlaan)
    Mike clearly described what you need to do to get the ASP.NET AJAX extensions working in a SharePoint site. First install the extensions (of course), then make some changes to the web.config of the SharePoint site.
  • AjaxBasePart: Easy ASP.NET 2.0 AJAX Extensions 1.0 and Office SharePoint Server 2007 (by Eric Schoonover)
    Eric describes how you can make use of ASP.NET AJAX in a SharePoint web part, he posts code for his implementation of a base web part class that supports AJAX. The nice thing about this base web part class is that it dynamically adds the AJAX ScriptManager control to the class (required for the AJAX stuff).

Yesterday evening (very late :-) ) I've created a version of the SmartPart that makes use of the Eric's technique, let me introduce you the SmartPart with AJAX! So basically said: you can create a Web User Control (ASCX) with the Visual Studio Designer, that uses the ASP.NET AJAX extensions and run that user control as a SharePoint web part. At this point in time, it's still a beta version, you can get it from the GotDotNet workspace (releases section). How do you get started? First of all you need to download and install the ASP.NET AJAX Extensions. Next you need to extend your SharePoint site with these extensions, check Mike's post for detailed instructions. You only need to change the web.config, you don't need to add the ScriptManager to the master page! Now you can install the SmartPart (check the Installation guide, or this screencast).

Now you can start building ASP.NET AJAX style user controls and use them in SharePoint! The beta version of the SmartPart ships with a couple of examples, but I've recorded a small screencast (no sound yet) as well, you just need to see AJAX in action, screenshots don't give you an idea about how the web parts behave without postbacks. Just watch the demos and see how easy it is! :-)

To finish of I would like to thank two persons who helped me with this release of the SmartPart. First of all Eric Schoonover for posting the code for his AjaxBasePart and for the support via Messenger. :-) Secondly I'd like to thank my friend and colleague Kevin DeRudder (still no blog?) who introduced me to the wonderful world of AJAX and helped me a lot with the demos.

Here's a screenshot of the Calendar control from the ASP.NET AJAX Control Toolkit, hosted in a SmartPart on a WSSv3 site:

 

Filed under: ,

Comments

# re: SmartPart for SharePoint - ASP.NET AJAX Support

Thursday, February 22, 2007 6:32 AM by Vikram

The news is that Sharepoint services will support ajax extension 1.0 afer service pack 1

# re: SmartPart for SharePoint - ASP.NET AJAX Support

Thursday, February 22, 2007 8:40 AM by Sral

VERY COOL!!!!!!!!!

# re: SmartPart for SharePoint - ASP.NET AJAX Support

Friday, February 23, 2007 4:08 AM by res

Indeed, very cool!

Is there a workaround for sending parameters to a Smartpart?

# re: SmartPart for SharePoint - ASP.NET AJAX Support

Monday, February 26, 2007 4:04 AM by Jason, Lee

Very nice!!

But,

How to default Date Changed?

ex )  Default Year Style    "1970-1979"...Like this..

                                     1969  1970 1971....

# re: SmartPart for SharePoint - ASP.NET AJAX Support

Tuesday, February 27, 2007 9:44 PM by Renelou Esperanzate

Hi,

Never mind my last comment. It seems that I was a little impatient on the Central Administration > Operations > Solution Management module. I had retracted the old version now and installed the new one.

Thanks for this once again!

Regards,

# re: SmartPart for SharePoint - ASP.NET AJAX Support

Friday, March 02, 2007 12:34 AM by scarlet

Hi,

I have a query.How do we debug smart part webpart?

# re: SmartPart for SharePoint - ASP.NET AJAX Support

Tuesday, March 06, 2007 3:18 AM by yuval korin

hi,

i have difficulties in getting the ajax smart part to work

on a publishing portal (wcm site) while its working great on a collaboration portal. are there any known issues about that?

besides that, very cool component!!

thanks!

# re: SmartPart for SharePoint - ASP.NET AJAX Support

Tuesday, March 13, 2007 1:01 PM by Peter Matthews

Hi Jan,

Nice addition to Smart Part!  However, I was trying to put a gridview control into a update panel (as in your screen cast), but when I try to use paging it comes up with the following error:

Sys.WebForms.PageRequestManagerParserErrorException: The message received from the server could not be parsed. Common causes for this error are when the response is modified by calls to Reponse.Write(), reponse filters, HttpModules, or server trace is enabled.

Any ideas how to fix this?

Many thanks in advance,

Peter

# re: SmartPart for SharePoint - ASP.NET AJAX Support

Tuesday, March 20, 2007 11:22 AM by Leon Zandman

The BETA seems to work. I did notice that you didn't update the documentation (Installation Guide), since it uses the wrong filename for the .wsp file.

# re: SmartPart for SharePoint - ASP.NET AJAX Support

Wednesday, May 23, 2007 2:28 AM by Patrick

Jan, this is great! Just what we needed for a large MOSS project. It seems to be working fine (I tested it with your ASCX file), but when I try to preview SmartPartv3AJAX by clicking it in the Web Part Gallery I get this exceedingly verbose and helpful error: "An error occured when previewing the Web Part." This does not happen with SmartPartv3. Any ideas?

# re: SmartPart for SharePoint - ASP.NET AJAX Support

Tuesday, June 05, 2007 11:02 AM by Pedro

Hi,

I've tried to use the ReturnOfSmartPart.dll (Smartpart with AJAX) but i recevied an error :

"Unable to add selected web part(s). A Web Part or Web Form Control on this Page cannot be displayed or imported. The type is not registered as safe."

Any ideas ?

Tanks

# re: SmartPart for SharePoint - ASP.NET AJAX Support

Saturday, June 09, 2007 8:29 AM by Daniel

Hi,

I've created your Textbox-CalendarExtender Demo, but SmartPart write

Error: unable to load ~\/UserControls\meinKalender.ascx

Details: Unknown server tag 'ajaxToolkit:CalendarExtender'.

what's my mistake, what make I wrong?

thx

regards

Daniel

# Rinaldo Hodzelmans » Blog Archive » SmartPart for SharePoint - ASP.NET AJAX Support

Pingback from  Rinaldo Hodzelmans  » Blog Archive   » SmartPart for SharePoint - ASP.NET AJAX Support

# re: SmartPart for SharePoint - ASP.NET AJAX Support

Saturday, June 16, 2007 4:29 PM by ...

[URL=www.lebend16.org/testi-di] testi di [/URL]   <a href='www.lebend16.org/testi-di'> testi di </a> [URL=www.lebend16.org/case-vacanze] case vacanze [/URL]   <a href='www.lebend16.org/case-vacanze'> case vacanze </a>

# re: SmartPart for SharePoint - ASP.NET AJAX Support

Sunday, June 17, 2007 5:33 AM by ...

[URL=www.lebend16.org/foto-filmati] foto filmati [/URL]   <a href='www.lebend16.org/foto-filmati'> foto filmati </a> [URL=www.lebend16.org/foto-di] foto di [/URL]   <a href='www.lebend16.org/foto-di'> foto di </a> [URL=www.lebend16.org/grande-fratello] grande fratello [/URL]   <a href='www.lebend16.org/grande-fratello'> grande fratello </a> [URL=www.lebend16.org/sesso-con-cavalli] sesso con cavalli [/URL]   <a href='www.lebend16.org/sesso-con-cavalli'> sesso con cavalli </a> [URL=www.lebend16.org/donna-cerco] donna cerco [/URL]   <a href='www.lebend16.org/donna-cerco'> donna cerco </a> [URL=www.lebend16.org/sesso-video-gratis] sesso video gratis [/URL]   <a href='www.lebend16.org/sesso-video-gratis'> sesso video gratis </a> [URL=http://www.lebend16.org/pop-up] pop up [/URL]   <a href='http://www.lebend16.org/pop-up'> pop up </a> [URL=www.lebend16.org/www-giochi-it] www giochi it [/URL]   <a href='www.lebend16.org/www-giochi-it'> www giochi it </a> [URL=www.lebend16.org/calcio-on-line] calcio on line [/URL]   <a href='www.lebend16.org/calcio-on-line'> calcio on line </a> [URL=www.lebend16.org/annunci-vendo] annunci vendo [/URL]   <a href='www.lebend16.org/annunci-vendo'> annunci vendo </a> [URL=www.lebend16.org/signore-mature] signore mature [/URL]   <a href='www.lebend16.org/signore-mature'> signore mature </a> [URL=www.lebend16.org/calendari-donne] calendari donne [/URL]   <a href='www.lebend16.org/calendari-donne'> calendari donne </a> [URL=www.lebend16.org/film-hard-gratis] film hard gratis [/URL]   <a href='www.lebend16.org/film-hard-gratis'> film hard gratis </a> [URL=www.lebend16.org/donne-per-sesso] donne per sesso [/URL]   <a href='www.lebend16.org/donne-per-sesso'> donne per sesso </a> [URL=www.lebend16.org/girls-sexy] girls sexy [/URL]   <a href='www.lebend16.org/girls-sexy'> girls sexy </a> [URL=www.lebend16.org/guerra-vida-wallpaper] guerra vida wallpaper [/URL]   <a href='www.lebend16.org/guerra-vida-wallpaper'> guerra vida wallpaper </a> [URL=www.lebend16.org/gratis-sms] gratis sms [/URL]   <a href='www.lebend16.org/gratis-sms'> gratis sms </a> [URL=www.lebend16.org/play-station-2] play station 2 [/URL]   <a href='www.lebend16.org/play-station-2'> play station 2 </a> [URL=www.lebend16.org/bologna-lavoro] bologna lavoro [/URL]   <a href='www.lebend16.org/bologna-lavoro'> bologna lavoro </a> [URL=www.lebend16.org/annunci-incontri] annunci incontri [/URL]   <a href='www.lebend16.org/annunci-incontri'> annunci incontri </a> [URL=www.lebend16.org/locale-milano] locale milano [/URL]   <a href='www.lebend16.org/locale-milano'> locale milano </a> [URL=www.lebend16.org/juegos-gratis] juegos gratis [/URL]   <a href='www.lebend16.org/juegos-gratis'> juegos gratis </a> [URL=www.lebend16.org/il-giornale] il giornale [/URL]   <a href='www.lebend16.org/il-giornale'> il giornale </a> [URL=www.lebend16.org/di-palermo] di palermo [/URL]   <a href='www.lebend16.org/di-palermo'> di palermo </a> [URL=www.lebend16.org/fiat-punto] fiat punto [/URL]   <a href='www.lebend16.org/fiat-punto'> fiat punto </a>

# re: SmartPart for SharePoint - ASP.NET AJAX Support

Sunday, July 08, 2007 3:12 AM by Syed

"An unexpected error has occurred"

I am recieving the above Error when i try to Edit the page with SmartPart AJAX Extension Webpart. I am recieving the same Error when i try to close this webpart or modify this webpart.

Functionaliy wise Webpart has no problem.

From Event Viewer i got the following Error Description.

Error: Failure in loading assembly: ReturnOfSmartPart, Version=1.0.0.0, Culture=neutral, PublicKeyToken=9f4da00116c38ec5

Kindly help me in solving the problem.

# re: SmartPart for SharePoint - ASP.NET AJAX Support

Friday, July 20, 2007 6:51 PM by psiEnergos

GotDotNET is effictively gone, anywhere else to obtain AJAX version?

Thanks!

# re: SmartPart for SharePoint - ASP.NET AJAX Support

Friday, July 20, 2007 8:46 PM by Sheri Salomone

How can I download SmartPart? The link is broken.

# re: SmartPart for SharePoint - ASP.NET AJAX Support

Monday, July 23, 2007 5:42 AM by ugin

Where can I download SmartPart? GotDotNet site is down.

# re: SmartPart for SharePoint - ASP.NET AJAX Support

Thursday, July 26, 2007 7:56 PM by Nate

# re: SmartPart for SharePoint - ASP.NET AJAX Support

Monday, August 06, 2007 10:25 AM by raffaeu

Only 1 issue, i have installed and everything work fine but my webparts make every time a postback ... without using the asyncro from the update panel they reside in...

# re: SmartPart for SharePoint - ASP.NET AJAX Support

Thursday, August 09, 2007 3:28 PM by Kiran

I can not see the "Connections" menu item at all on the smartpart.

This is funny because all the screencasrs tell its very easy. Can anyone help me?

Thanks

Kiran

# re: SmartPart for SharePoint - ASP.NET AJAX Support

Thursday, August 16, 2007 11:58 PM by tumharadost

Hi

I have one smart(having user control) part which is a producer on PageNo1.

Secondly, I have another smartpart(having user control) on PageNo.2 which is a consumer for smart part on PageNo1.

Now, the problem is that I am finding "Connections" link coming disabled showing tooltip something as "Connection type not compatiable with other parts of the web page."

Now the catch is it works prefectly fine when both producer and consumer are on the same page, but does not work if put on different pages.

My second big concern is that on "Submit" click, I want to move to next page and then show the consumer data fetched from producer on PageNo1.

Please Suggest. It is too critical for my application.

# re: SmartPart for SharePoint - ASP.NET AJAX Support

Friday, August 17, 2007 12:15 AM by tumharadost

Hi

I have one smart(having user control) part which is a producer on PageNo1.

Secondly, I have another smartpart(having user control) on PageNo.2 which is a consumer for smart part on PageNo1.

Now, the problem is that I am finding "Connections" link coming disabled showing tooltip something as "Connection type not compatiable with other parts of the web page."

Now the catch is it works prefectly fine when both producer and consumer are on the same page, but does not work if put on different pages.

My second big concern is that on "Submit" click, I want to move to next page and then show the consumer data fetched from producer on PageNo1.

Please Suggest. It is too critical for my application.

# re: SmartPart for SharePoint - ASP.NET AJAX Support

Friday, August 17, 2007 11:00 AM by ultragc

Hi,

Trying to create this calendar demo.  Followed all the directions given.  I am getting

"Unknown server tag ajaxToolkit:CalendarExtender" error when trying to bring up the calendar in the web part.  What am I missing?

Thanks

# re: SmartPart for SharePoint - ASP.NET AJAX Support

Thursday, August 23, 2007 4:03 PM by Tony Contrada

Regarding the issue with SharePoint SafeControls...

Jan's documentation is missing another entry for the AJAX SmartPart. In the web.config file you must add the following element in the SharePoint SafeControls section:

<SafeControl Assembly="ReturnOfSmartPart, Version=1.2.0.0, Culture=neutral, PublicKeyToken=9f4da00116c38ec5" Namespace="SmartPart" TypeName="AJAXSmartPart" Safe="True" />

The difference is the TypeName which for AJAX is AJAXSmartPart.

Otherwise, nice work Jan!

# re: SmartPart for SharePoint - ASP.NET AJAX Support

Friday, September 07, 2007 4:43 PM by Adrian

Hi Jan,

Your SmartPart is awesome. Did you had any issues with web part pages that have the smartpart loaded with an user control not running the Ajax scripts for users that are not allowed to customize the page? Like only Team Members not Team Visitors.

Thanks again for you your tremendous work,

Adrian

# home science projects for kids

Friday, September 07, 2007 8:23 PM by home science projects for kids

home science projects for kids

# re: SmartPart for SharePoint - ASP.NET AJAX Support

Tuesday, September 11, 2007 3:57 PM by daastan

Hi All

I Tried everything as mentioned in the Article when I go to the site click on SmartPart  " Open tool Pane " > User Control to display I see that my creared user control is not appearing its says" Could not load BasicDemo.ascx " Any Idea what i am doing  wrong. Any help will be appriciated.

Thank You

# re: SmartPart for SharePoint - ASP.NET AJAX Support

Thursday, September 20, 2007 3:47 AM by Anupam Shrivastava

Hi,

 Please le me know, from where can I download SmartPart with AJAX, as the GotDotNet URL provided in this article has been phased out and I couldn't find this SmartPart anywhere else.

Pls let me know ASAP, as I need this urgently.

Thanks,

Anupam

# re: SmartPart for SharePoint - ASP.NET AJAX Support

Thursday, September 27, 2007 4:30 AM by leon

I've followed all the steps required. I've managed to add the Smart Part into my SharePoint Server page. But when I click a button that supposed to update a textbox.text, nothing happens.

Anyone knows why?

# re: SmartPart for SharePoint - ASP.NET AJAX Support

Wednesday, October 10, 2007 7:00 AM by shilpa

I've tried to use the ReturnOfSmartPart.dll (Smartpart with AJAX) but i recevied an error :

"Unable to add selected web part(s). A Web Part or Web Form Control on this Page cannot be displayed or imported. The type is not registered as safe."

# re: SmartPart for SharePoint - ASP.NET AJAX Support

Sunday, October 21, 2007 12:49 PM by Soren K.

Jan, Thank you.  This is a great tool!!

# re: SmartPart for SharePoint - ASP.NET AJAX Support

Tuesday, October 23, 2007 10:05 AM by Amir

Hi there

I´ve tried to run the exact same example with the button and the timer. But the update panel does not update anything though the things I want to happen in the button click event, they do actually happen, but the stuff in the update panel isnt updated.

Can anyone please help on this issue.

Thanks in advance Amir

# re: SmartPart for SharePoint - ASP.NET AJAX Support

Wednesday, October 24, 2007 9:07 AM by Bala

Hi Jan,

I have a cascading dropdown functionality to implement. I am using AJAX version of web part hosting a user control having the beforesaid functionality.

when I change selection for dropdown first time, the event is invoked and handler code is executing. However for subsequent selection changes in dropwdown, the handler is not invoked.

Do you have any suggestions in specific using Cascade dropdown list functionality?

Thanks in Advance

Bala

# re: SmartPart for SharePoint - ASP.NET AJAX Support

Tuesday, November 06, 2007 7:54 AM by Bob

It appears that workspaces.gotdotnet.com/smartpart is being 'phased out'.  Where can I go to get the SmartPart with Ajax?

# re: SmartPart for SharePoint - ASP.NET AJAX Support

Thursday, November 22, 2007 1:59 PM by Luis Castanheira

i was getting a "unespect erro..." in the sharepoint when using ajaxtoolkit components , i saw the erro in the log file:

w3wp.exe (0x0D14)                      

0x0D5C SharePoint Portal Server       Runtime                       7pma

Exception

Unhandled exception caught during execution of Microsoft.SharePoint.Portal.PageBase::ErrorHandler().

Exception information: Exception information: System.NotSupportedException:

This page is missing a HtmlHead control which is required for the CSS stylesheet link that is being added.

Please add

<head runat="server" />.    

at AjaxControlToolkit.ScriptObjectBuilder.RegisterCssReferences(Control control)    

at AjaxControlToolkit.ExtenderControlBase.OnLoad(EventArgs e)    

at System.Web.UI.Control.LoadRecursive()    

at System.Web.UI.Control.LoadRecursive()    

at System.Web.UI.Control.LoadRecursive()    

at System.Web.UI.Control.LoadRecursive()    

at System.Web.UI.Control.AddedControl(Control control, Int32 index)    

at System.Web.UI.ControlCollection.Add(Control child)    

at SmartPart.Sm...

in my master page i have <head runat="server" /> but in the page that i was adding this acx i didn't so i put the <head runat="server" /> on that page and it solve the problem

why this ?

# re: SmartPart for SharePoint - ASP.NET AJAX Support

Thursday, November 29, 2007 7:47 AM by Meera

Hi,

I've created your Textbox-CalendarExtender Demo, but SmartPart write

Error: unable to load ~\/UserControls\meinKalender.ascx

Details: Unknown server tag 'ajaxToolkit:CalendarExtender'.

what's my mistake, what make I wrong?

thx

regards

Meera

# re: SmartPart for SharePoint - ASP.NET AJAX Support

Thursday, December 13, 2007 8:46 AM by GSWorLD

is there a way to change the localization of the ajaxsmartpart?

e.g. i ve dutch calandercontrol and i would like to show this calander in dutch format but scriptmanager in ajaxsmartpart is localizied  in english format and i would like to change it. How?? any help??

# AJAX in Windows SharePoint Services 3.0 (und MOSS 2007)

Friday, January 25, 2008 11:09 AM by Swiss DPE Team Blog

Vor wenigen Wochen ist das SP1 f&#252;r SharePoint erschienen ( weitere Infos ). Es enth&#228;lt mehrere

# AJAX in Windows SharePoint Services 3.0 (und MOSS 2007)

Friday, January 25, 2008 12:06 PM by Noticias externas

Vor wenigen Wochen ist das SP1 für SharePoint erschienen ( weitere Infos ). Es enthält mehrere Dutzend

# MSDN Blog Postings &raquo; AJAX in Windows SharePoint Services 3.0 (und MOSS 2007)

Pingback from  MSDN Blog Postings  &raquo; AJAX in Windows SharePoint Services 3.0 (und MOSS 2007)

# AJAX in Windows SharePoint Services 3.0 (und MOSS 2007)

Tuesday, March 18, 2008 10:01 AM by Spootnic

Vor wenigen Wochen ist das SP1 für SharePoint erschienen ( weitere Infos ). Es enthält mehrere Dutzend

# Enable SmartPart with AJAX in SharePoint

Monday, June 09, 2008 11:25 AM by Colt Kwong Blog

I just try SmartPart and enable AJAX functionality in SharePoint tonight, here are few notes: 1. Download