We have used the Label data type, in an e-commerce project of ours. We made an integration with an ERP system, where the products where stored. But in the Umbraco back office you could find all the products. When selecting a product, some of the basic, unique information of that product where displayed through a label data type. Eg. the product ID where displayed as a label, as this should not ever be changed, but it should still be vissible to the user.
We do a similar thing to Kim, when a node gets updated we use the Document.BeforePublish event, grab an auto id from another database (if the node doesn't have one already), then we modify the document property.
The Mystic Label
Hello!
So in Umbraco there is a datatype called Label, which is used on the media items to say get the file size, width, height.
But... what else can it do? I'm aware of;
umbracoBytes, umbracoExtension, umbracoWidth, umbracoHeight,
But what else is hiding there?
Hope everyone had a lovely week, Laurie x
Interesting question !
I'm guessing this behaviour is within the associated datatypes, so would all the above be set (if they exist) by the file upload datatype ?
This is a feature of the Upload datatype.
The label datatype just happens to be used for output purposes, it would work for a textbox just as well.
I pretty sure it only tries to set those 4 properties.
Hi there.
We have used the Label data type, in an e-commerce project of ours. We made an integration with an ERP system, where the products where stored. But in the Umbraco back office you could find all the products. When selecting a product, some of the basic, unique information of that product where displayed through a label data type. Eg. the product ID where displayed as a label, as this should not ever be changed, but it should still be vissible to the user.
/Kim A
Hi
So how do I do that Kim have described? what should I write in my c# code to give a value to the label?
/Johan
Hi Johan,
We do a similar thing to Kim, when a node gets updated we use the Document.BeforePublish event, grab an auto id from another database (if the node doesn't have one already), then we modify the document property.
Rich
Hi Rich
I have no idea how I should do it from what you say. my knowledge is not great yet. I had hoped that I could use simple code like
currentPage.getProperty ("number"). Value = value;
I looked a little on this link. http://our.umbraco.org/forum/developers/xslt/18699-Listing-Most-Visited-Page
But it seems I have done the same without xslt.
Johan
is working on a reply...