programmatically adding items to the document's ultimate picker property?
Hi guys,
I was wondering could someone please show me how to programmatically add items to the ultimate picker property (I've searched around for this but couldn't find any examples, I'm guessing something then something trivial like document.getProperty("relatedMedia").Add(nodeID) should hopefully exist and that it could be called numerous times (to add multiple related items) - or instead of that maybe call Add(nodeIDs) - using nodeIDs = (nodeID1 + "," + nodeID2...) since I've read Ultimate Picker holds comma separated data).
I don't have a complete answer for you. But I suggest you try to find the value in the cmsPropertyData Database table. I think it's a comma seperated field, not 100 sure. So you only have to assign a string with comma seperated nod id's to the property (document.getProperty("relatedMedia").value = "1021,1480,1320")
Yep, check either in umbraco.config in /data directory how a value of this datatype is saved and make sure to do it the same way programmatically (value is most likely a comma separated string but can be a xml fragment as well)...
Bottom line: find a doc that has such an ultimate picker property, and check the vaue in either db or umbraco.config.
Thanks for your replies first...will try the comma-separated values and check back if I get it to work...
I'm just rethinking how to use this in the situation where I'd like those values to be inserted/set in a Windows Live Writer editor...one way (my initial thinking) was to insert those ids in a special kind of tags (I'd rewrite the InsertUmbracoLink plugin from Mr. Hoehler) and have them later be cleared/rewritten in the ultimate picker by some custom event handler code of mine...however I saw that there should be a properties (F2) field which should/could be set via the WLW, only it's disabled for me, maybe I setup the content channel wrong?
Was any one able to setup their description/category/excerpt fields so that more than one property is editable (for me only the bodyText which is set to the description field in the content channel) beside the nodeName - which is auto-set by the title text in the WLW? How please? TIA
programmatically adding items to the document's ultimate picker property?
Hi guys,
I was wondering could someone please show me how to programmatically add items to the ultimate picker property (I've searched around for this but couldn't find any examples, I'm guessing something then something trivial like document.getProperty("relatedMedia").Add(nodeID) should hopefully exist and that it could be called numerous times (to add multiple related items) - or instead of that maybe call Add(nodeIDs) - using nodeIDs = (nodeID1 + "," + nodeID2...) since I've read Ultimate Picker holds comma separated data).
TIA
Hi,
I don't have a complete answer for you. But I suggest you try to find the value in the cmsPropertyData Database table. I think it's a comma seperated field, not 100 sure. So you only have to assign a string with comma seperated nod id's to the property (document.getProperty("relatedMedia").value = "1021,1480,1320")
Hope it helps you,
Richard
Yep, check either in umbraco.config in /data directory how a value of this datatype is saved and make sure to do it the same way programmatically (value is most likely a comma separated string but can be a xml fragment as well)...
Bottom line: find a doc that has such an ultimate picker property, and check the vaue in either db or umbraco.config.
Cheers,
/Dirk
Hi guys,
Thanks for your replies first...will try the comma-separated values and check back if I get it to work...
I'm just rethinking how to use this in the situation where I'd like those values to be inserted/set in a Windows Live Writer editor...one way (my initial thinking) was to insert those ids in a special kind of tags (I'd rewrite the InsertUmbracoLink plugin from Mr. Hoehler) and have them later be cleared/rewritten in the ultimate picker by some custom event handler code of mine...however I saw that there should be a properties (F2) field which should/could be set via the WLW, only it's disabled for me, maybe I setup the content channel wrong?
Was any one able to setup their description/category/excerpt fields so that more than one property is editable (for me only the bodyText which is set to the description field in the content channel) beside the nodeName - which is auto-set by the title text in the WLW? How please? TIA
is working on a reply...