locked
Get Custom Property Value RRS feed

  • Question

  • How can i get/set custom property (a property that i added to Acconut)
    Let's say i added property "MyNotes" on account.
    Is there a method like account.Properites("MyNotes") or something like that?

    I've read that i could update web service reference, but i need more generic approach.

    Also:
    How to access Custom Entites and all their properties?
    Is this right/only way to do it? 

    Thank you!
    Wednesday, January 14, 2009 11:13 AM

Answers

  • hi,

    Ok u can set values to an attribute through both server side coding and Client side Javascript.

     

    Javascript:

    crmForm.all.Mynote.DataValue='Hello World';

     

    Server side.: It may be a Plugin or a workflow..

     DynamicEntity entity = (DynamicEntity)context.InputParameters.Properties["Target"];

    entity.Properties["Mynote"] = "Hello World";

    try...
    Wednesday, January 14, 2009 12:32 PM

All replies

  • Hi,

    U've added a property in the Account entity,u mean u've added a new custom entity in the Account Entity,right? or else?

    I'm not clear about your requirement!

     

    Wednesday, January 14, 2009 11:29 AM
  •  Krishna Raj.R wrote:

    Hi,

    U've added a property in the Account entity,u mean u've added a new custom entity in the Account Entity,right? or else?

    I'm not clear about your requirement!

     


    Sorry, maybe I wasn't clear enough:
    Two questions:

    1. I added new attribute ("MyNote") to Account entity.  Now i want to get/set value from code.

    2. I added new Entity ("MyNewEntitiy") an added attributes to it ("NewAttirbuteName").  How to set/get values to this attribute.

    Thank you!
    Wednesday, January 14, 2009 12:22 PM
  • hi,

    Ok u can set values to an attribute through both server side coding and Client side Javascript.

     

    Javascript:

    crmForm.all.Mynote.DataValue='Hello World';

     

    Server side.: It may be a Plugin or a workflow..

     DynamicEntity entity = (DynamicEntity)context.InputParameters.Properties["Target"];

    entity.Properties["Mynote"] = "Hello World";

    try...
    Wednesday, January 14, 2009 12:32 PM