Cascading drop down lists in another language

Feb 16, 2010 at 8:04 AM

Hi,
I can't seem to get it to work on my norwegian site, when I allow multiple values on the child column. It works fine if you can only select one parent and one child. But with multiple values I get the error:
"Error in function: SPServices.SPCascadeDropDowns
Parameter: childColumn: By
Message: Column not found on page"
I tried following the same procedure on an english site, and it worked fine, with multiple values and all. The only difference seems to be the language.

What can I do to get it to work? :)

This is how I want to it to work: Choose parent column: Company, and child column: Product. And is has to be possible to choose more than one product. I followed this procedure: http://www.uccorner.com/54/sharepoint/cascading-drop-down/ 

Coordinator
Feb 16, 2010 at 1:51 PM
Edited Feb 16, 2010 at 2:09 PM

Jasmine:

As you might expect, I don't have a Norwegian installation to look at.  The only obvious thing that I can think of is that the Title of the multi-select component selects might be in Norwegian.  Here (en-US), the Titles are:

  • Left side: columnName + " possible values"
  • Right side: columnName + " selected values"

Are you able to check the titles with Firebug or Developer Tools?

M.

p.s. It's interesting that you found the "documentation" on someone else's site!

Feb 17, 2010 at 11:12 AM

Hi,

I know it's kind of weird that I followed someone else's documentation, but it's because I know him, and he was helping me at the time :)

I don't understand what you mean with the "Title of the multi-select component selects"...how can I see if the title is in English or Norwegian? The only thin I can find is, FieldName, FieldInternalName and FieldType. And there doesn't seem to be anything wrong with this.

I made a list called Company with just one column Title. Then I made a list called Product with the title column, and a lookup column showing Company-title. In my third list I added two lookup columns to Product and Company, and added the following code in my own NewForm.aspx under ContentPlaceHolderId="PlaceHolderMain":

<script language="javascript" type="text/javascript" src="/sites/audun/jasmine/Documents/jquery-1.3.2.min.js"></script>
<script language="javascript" type="text/javascript" src="/sites/audun/jasmine/Documents/jquery.SPServices-0.5.0.min.js"></script>
<script language="javascript" type="text/javascript">
    $(document).ready(function() {
        $().SPServices.SPCascadeDropdowns({
            relationshipList: "Product",
            relationshipListParentColumn: "Company",
            relationshipListChildColumn: "Title",
            parentColumn: "Company",
            childColumn: "Product",
            debug: true
        });

    });
</script>


Can you see anything wrong with my code?

In the third list, when you can only choose one product, it works just fine. It shows the Products only after you've chosen Company. If I allow multiple selects on the Products column, I get the following error:

"Error in function: SPServices.SPCascadeDropDowns
Parameter: childColumn: Product
Message: Column not found on page"

 

/Jasmine

Coordinator
Feb 17, 2010 at 11:23 AM

Jasmine:

Sorry if I was cryptic.  My theory is that it may not be your code, but the way I find the controls on the page.  I have an email into Bjørn Furuknap asking if he can take a look at this, too, since he's bound to have a Norwegian instance around.

If you can find the FieldName, FieldInternalName and FieldType stuff in the page, then a bit lower down in the DOM, you should see the SELECT constructs for the multi-select control. Here's what I see for my multi-select City column:

<select name="ctl00$m$g_e845e690_00da_428f_afbd_fbe804787763$ctl00$ctl04$ctl07$ctl00$ctl00$ctl04$ctl00$ctl00$SelectCandidate" title="City possible values" id="ctl00_m_g_e845e690_00da_428f_afbd_fbe804787763_ctl00_ctl04_ctl07_ctl00_ctl00_ctl04_ctl00_ctl00_SelectCandidate" style="width: 145px;" onkeydown="GipHandleHScroll(event)" ondblclick="GipAddSelectedItems(ctl00_m_g_e845e690_00da_428f_afbd_fbe804787763_ctl00_ctl04_ctl07_ctl00_ctl00_ctl04_ctl00_ctl00_MultiLookupPicker_m); return false" onchange="GipSelectCandidateItems(ctl00_m_g_e845e690_00da_428f_afbd_fbe804787763_ctl00_ctl04_ctl07_ctl00_ctl00_ctl04_ctl00_ctl00_MultiLookupPicker_m);" size="350" multiple="multiple">

As you can see, the title="City possible values". What I'm wodering is if the "possible values" text is different in your Norwegian site.

M.

Feb 17, 2010 at 11:47 AM

Yes, it says title = "Product mulige verdier". Mulige verdier = Possible values. What does this mean? Is this the reason it doesn't work you think? Thank you for forwarding it to Bjørn Furuknap.

/Jasmine

 

Coordinator
Feb 17, 2010 at 11:51 AM

Ok, that's definitely the issue. In the short term, you'll be able to get the function to work by replacing "possible values" with "mulige verdier" in the code. Also look for and replace "selected values" with the Norgegian equivalent:

<select name="ctl00$m$g_e845e690_00da_428f_afbd_fbe804787763$ctl00$ctl04$ctl07$ctl00$ctl00$ctl04$ctl00$ctl00$SelectResult" title="City selected values" id="ctl00_m_g_e845e690_00da_428f_afbd_fbe804787763_ctl00_ctl04_ctl07_ctl00_ctl00_ctl04_ctl00_ctl00_SelectResult" style="width: 145px;" onkeydown="GipHandleHScroll(event)" ondblclick="GipRemoveSelectedItems(ctl00_m_g_e845e690_00da_428f_afbd_fbe804787763_ctl00_ctl04_ctl07_ctl00_ctl00_ctl04_ctl00_ctl00_MultiLookupPicker_m); return false" onchange="GipSelectResultItems(ctl00_m_g_e845e690_00da_428f_afbd_fbe804787763_ctl00_ctl04_ctl07_ctl00_ctl00_ctl04_ctl00_ctl00_MultiLookupPicker_m);" size="20" multiple="multiple">

I apologize for my English-centric approach. I'll rework this in the next release so that it doesn't rely on the English but this fix ought to get you up and running for now.

M.

Coordinator
Feb 17, 2010 at 11:54 AM
This discussion has been copied to a work item. Click here to go to the work item and continue the discussion.
Feb 17, 2010 at 12:31 PM

Thank you so much. It works now that I replaced "selected values" and "possible values" with the norgwegian :)

 

Coordinator
Mar 1, 2010 at 7:49 PM

Jasmine:

I was away on vacation, and I'm looking at fixing this issue. Could you paste the similar section of HTML as I'm showing above from your Norwegian site? What I'm wondering is if the SelectResult texts bolded below are also in Norwegian or if they are consistently English.

<select name="ctl00$m$g_e845e690_00da_428f_afbd_fbe804787763$ctl00$ctl04$ctl07$ctl00$ctl00$ctl04$ctl00$ctl00$SelectResult" title="City selected values" id="ctl00_m_g_e845e690_00da_428f_afbd_fbe804787763_ctl00_ctl04_ctl07_ctl00_ctl00_ctl04_ctl00_ctl00_SelectResult" style="width: 145px;" onkeydown="GipHandleHScroll(event)" ondblclick="GipRemoveSelectedItems(ctl00_m_g_e845e690_00da_428f_afbd_fbe804787763_ctl00_ctl04_ctl07_ctl00_ctl00_ctl04_ctl00_ctl00_MultiLookupPicker_m); return false" onchange="GipSelectResultItems(ctl00_m_g_e845e690_00da_428f_afbd_fbe804787763_ctl00_ctl04_ctl07_ctl00_ctl00_ctl04_ctl00_ctl00_MultiLookupPicker_m);" size="20" multiple="multiple">

Thanks,
M.

Coordinator
Mar 2, 2010 at 8:42 PM

Jasmine:

I've got a potential fix in place for this in my latest alpha release:
http://spservices.codeplex.com/releases/view/40577

I'd appreciate it if you could test it in your enviroment.

Thanks,
M.

Mar 3, 2010 at 7:24 AM

Hi,

SelectResults are consistently English J

I’ll be able to test the alpha version on Friday.

/Jasmine

From: sympmarc [mailto:notifications@codeplex.com]
Sent: 1. mars 2010 21:50
To: Jasmine Garry
Subject: Re: Cascading drop down lists in another language [SPServices:85478]

From: sympmarc

Jasmine:

I was away on vacation, and I'm looking at fixing this issue. Could you paste the similar section of HTML as I'm showing above from your Norwegian site? What I'm wondering is if the SelectResult texts bolded below are also in Norwegian or if they are consistently English.

<select name="ctl00$m$g_e845e690_00da_428f_afbd_fbe804787763$ctl00$ctl04$ctl07$ctl00$ctl00$ctl04$ctl00$ctl00$SelectResult" title="City selected values" id="ctl00_m_g_e845e690_00da_428f_afbd_fbe804787763_ctl00_ctl04_ctl07_ctl00_ctl00_ctl04_ctl00_ctl00_SelectResult" style="width: 145px;" onkeydown="GipHandleHScroll(event)" ondblclick="GipRemoveSelectedItems(ctl00_m_g_e845e690_00da_428f_afbd_fbe804787763_ctl00_ctl04_ctl07_ctl00_ctl00_ctl04_ctl00_ctl00_MultiLookupPicker_m); return false" onchange="GipSelectResultItems(ctl00_m_g_e845e690_00da_428f_afbd_fbe804787763_ctl00_ctl04_ctl07_ctl00_ctl00_ctl04_ctl00_ctl00_MultiLookupPicker_m);" size="20" multiple="multiple">

Thanks,
M.

Read the full discussion online.

To add a post to this discussion, reply to this email (SPServices@discussions.codeplex.com)

To start a new discussion for this project, email SPServices@discussions.codeplex.com

You are receiving this email because you subscribed to this discussion on CodePlex. You can unsubscribe on CodePlex.com.

Please note: Images and attachments will be removed from emails. Any posts to this discussion will also be available online at CodePlex.com

Coordinator
Mar 3, 2010 at 12:49 PM

Thanks, Jasmine.  Bjorn confirmed the same for me.  Let me know how it goes.

M.

Mar 10, 2010 at 1:53 PM

Hi,

Sorry I haven’t got back to you before now. I saw that it’s no longer an alpha release. I tried the one that’s out, and it worked excellent. J thank you!

/J

From: sympmarc [mailto:notifications@codeplex.com]
Sent: 3. mars 2010 14:49
To: Jasmine Garry
Subject: Re: Cascading drop down lists in another language [SPServices:85478]

From: sympmarc

Thanks, Jasmine. Bjorn confirmed the same for me. Let me know how it goes.

M.

Read the full discussion online.

To add a post to this discussion, reply to this email (SPServices@discussions.codeplex.com)

To start a new discussion for this project, email SPServices@discussions.codeplex.com

You are receiving this email because you subscribed to this discussion on CodePlex. You can unsubscribe on CodePlex.com.

Please note: Images and attachments will be removed from emails. Any posts to this discussion will also be available online at CodePlex.com

Coordinator
Mar 10, 2010 at 2:09 PM

Great, Jasmine.  You were the one test case, and I'm glad it works!  I had confidence in the changes that I made, so I want ahead and released it.  Let me know if you run into anything else odd that might be explained by a language difference.  I took a look through and didn't see anything else obvious, but I could have missed something.

M.