Technical support This forum is closed.
Version 1.x > Technical support > Display Attributes by type View modes: 
User avatar
Member
Member
czapata - 3/21/2006 5:08:55 PM
   
Display Attributes by type
Hi!

Is there any way to display attributes dynamically in a custom document template by another attribute value?

For example if I have a custom document for Person with the fields FirstName, LastName, etc. but I also want it to display other fields by the selected value of a Profession attribute.

Is this possible?

Thanks
czapata

User avatar
Guest
admin - 3/21/2006 5:52:22 PM
   
Re: Display Attributes by type
Hello,

yes, this is possible. You will need to create a custom field type for that. You can see <web project>\cmsdesk\Metadata\_CustomFormControls\CMS_MenuItemType.ascx for example.

Best Regards,

User avatar
Member
Member
czapata - 3/27/2006 8:11:10 PM
   
Re: Display Attributes by type
Hi!

I've created a custom user control that is displayed or hidden depending on an attribute's value. I want to retreive the text for the labels for each field in my custom control from the customs document's attributes. Do I need to create a resx? What's the best way to do this if I want the app to support various cultures?


Thanks!
Carlos

User avatar
Guest
admin - 3/28/2006 12:44:49 PM
   
Re: Display Attributes by type
Hello,

Thank you for your message. If you want to use multilingual captions for the labels, you will need to add them to the resource file Kentico.CMS-CMSDesk.<lang>.resx and retrieve them using the ResMan class like this:

ResMan.GetString("string_name")

Please let me know if you need any help with that.

Best Regards,