Take the 2-minute tour ×
SharePoint Stack Exchange is a question and answer site for SharePoint enthusiasts. It's 100% free, no registration required.

Does anybody know how to achieve a cascading dropdownlist in an editor web part?

share|improve this question
    
Do you mean a 'Content Editor WebPart'? Is so, than you have to write your own JavaScript (try it with jQuery). –  Dribbel Sep 16 '11 at 14:26
    
sorry, custom editor web part –  Abu Hamzah Sep 25 '11 at 16:46
add comment

3 Answers

Check out Marc Anderson's SPServices library, there is a cascading drop down operation. You could also achieve that functionality through InfoPath forms, but not in the web enabled forms I believe.

share|improve this answer
add comment

I assume you are talking about a custom editorpart (toolpanepart). I've done this before using dropdownlist controls and implementing icallbackeventhandler to ajax load the cascading dropdowns. The only gotcha I ran into was a pagevalidation error. I got around that by using the Page.ClientScript.RegisterForEventValidation for my new values of the dropdownlist before my partial postback was complete (in the GetCallbackResult method).

If you don't need dynamic cascading dropdowns, as in the data will always be the same, then you can create an htmlgenericcontrol that has all of your html data in it like you normally would on a html page. I don't think you have to worry about naming conflicts as much with this because you can only have one toolpart pane open at a time.

share|improve this answer
    
do you have sample code? –  Abu Hamzah Sep 25 '11 at 16:45
    
For which solution i outlined above? –  Steve Lineberry Sep 26 '11 at 1:02
add comment

Try RichControls for Sharepoint 2010, an open source project hosted github. enter image description here

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

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