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

I have new form modified via xslt. So i have DataFormWebpart. I want to implement cascading drop down for 2 of my lookup field(Area and Country).

Can anyone help on it. I am aware of the SPServices.SPCascadeDropdowns but its not working.

share|improve this question
add comment

1 Answer

SPCascadeDropdowns works. It is one of the most popular functions in whole SPServices library, thus it is tested and proven to be functioning by tens of users, at the very least. Also Marc has demo page, there you can see it yourself.

XSLT in SharePoint acts as server-side templating engine, not less and not more. You should use it for one-time-only formatting of some data. XSLT by itself doesn't allow creating any AJAX or even simple postback-based solutions.

Actually, there are plenty of options when it comes to implementing cascaded dropdowns in SharePoint list forms. The most preferrable way here is to use InfoPath forms.

Here is the article which explains creation of cascaded dropdowns in InfoPath:

If you don't like Infopath for any reason, you have at least 3 other options:

  1. Custom field types
  2. Completely custom form or form based on custom RenderingTemplate
  3. Javascript/jQuery hack

First two options will involve programming. Third option is already implemented for you in SPCascadedDropdowns.

Thus if you cannot use InfoPath, and don't want to stick with development, I'd recommend you to identify your particular difficulties with SPCascadeDropdowns, and create the specific question either on the SPServices Codeplex Discussions Page, or here on SharePoint StackExchange.

share|improve this answer
    
i will show you the exact xslt code of the newform.aspx :<br/> where A and B are lookup field. can someone hel pwith the values required for following : codefunction<br/>$(document).ready(function() $().SPServices.SPCascadeDropdowns({ relationshipList: "B", relationshipListParentColumn:"AA", relationshipListChildColumn:"Title", parentColumn:"A", childColumn:"B", debug:true }); });code –  Monica Jagani Jun 8 '12 at 4:31
    
code<tr> <td>A</td> <td><SharePoint:FormField runat="server" id="ff27{$Pos}" controlmode="New" fieldname="ASource" __designer:bind="{ddwrt:DataBind('i',concat('ff27',$Pos),'Value','ValueChanged','‌​ID',ddwrt:EscapeDelims(string(@ID)),'@ASource')}" /></td> </tr> <tr> <td>B</td> <td><SharePoint:FormField runat="server" id="ff28{$Pos}" controlmode="New" fieldname="BSource" __designer:bind="{ddwrt:DataBind('i',concat('ff28',$Pos),'Value','ValueChanged','‌​ID',ddwrt:EscapeDelims(string(@ID)),'@BSource')}" /></td></tr>code –  Monica Jagani Jun 8 '12 at 4:33
    
Please, post the question about SPCascadeDropdowns as a separate one. –  Andrey Markeev Jun 8 '12 at 5:37
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.