1

Although I've been doing a lot of sharepoint 2010 branding lately, programming webparts is something completely new for me.

  1. I need to put together three webparts.

  2. I want to create a Webpart1 (Dropdownlist), Webpart2 (Checkbox) and Webpart3 (GridView)

  3. My grid in webpart3 should display data based on filter values from the other two webparts.

Do I have to implement connectable webparts to do this?

Ie: http://www.c-sharpcorner.com/UploadFile/DipalChoksi/4035/ http://msdn.microsoft.com/en-us/library/dd584164(office.11).aspx

Many thanks,

KS

3

Yes, you should make the Web Parts connectable - if you really want them as three Web Parts.

Why can't you make one Web Part containing all three controls?

| improve this answer | |
  • Because I guess my boss wants each one of them to be re-usable.thx. – Perplexed Apr 18 '11 at 20:02
  • to increase reusability you could go for user controls and a virtual web part. – Anders Rask Apr 18 '11 at 20:38
  • Do you mean that I can just create a standard asp.net usercontrol and deploy that to a sharepoint site? Thx. – Perplexed Apr 18 '11 at 20:52
  • 1
    You would deploy the user control to %SharePointRoot%/CONTROLTEMPLATES and then reuse it whether you want it on your masterpage or loaded from WebPart code using LoadControl("path/name.ascx"). – Alexey Krasheninnikov Apr 19 '11 at 9:15
  • What project template should I choose in VS if I wanted to create a re-usable webpart that can be used in Sharepoint and in a Asp.Net website? Hmmm, just a UserControl? Thx. – Perplexed Apr 19 '11 at 17:59

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.