MSCRM 4.0 Form Properties

Do pól formularza odwołujemy się poprzez obiekt crmForm:

[js]
crmForm.propertyname
[/js]

Tabelka poniżej przedstawia dostępne właściwości.

Właściwość Typ Opis
IsDirty bool Określa czy formularz był modyfikowany
FormType int Tylko do odczytu. Typ formularza.Możliwe wartości:

  • Undefined Form Type = 0
  • Create Form = 1
  • Update Form = 2
  • Read Only Form = 3
  • Disabled Form = 4
  • Quick Create Form = 5
  • Bulk Edit Form = 6
ObjectId string Tylko do odczytu. Identyfikator encji. Jeśli formularz jest w trybie edycji
ObjectTypeCode string Tylko do odczytu. Kod typu encji którą edytujemy/wyświetlamy na formularzu
ObjectTypeName string Tylko do odczytu.  Nazwa typu encji której dotyczy formularz
all.{field name}  Kolekcja poszczególnych pól formularza odpowiadającym polom w encji lub IFRAME formularza.

Przykład

[js]

var CRM_FORM_TYPE_CREATE = 1;
var CRM_FORM_TYPE_UPDATE = 2;

// Test the FormType and ObjectId properties.
switch (crmForm.FormType)
{
case CRM_FORM_TYPE_CREATE:
alert("This is a create form.");
break;

case CRM_FORM_TYPE_UPDATE:
alert("This is an update form, the ID is " + crmForm.ObjectId + ".");
break;
}
[/js]
[js]
var CRM_ENTITY_ACCOUNT = 1;
var CRM_ENTITY_CONTACT = 2;

// Test the ObjectTypeCode property.
switch (crmForm.ObjectTypeCode)
{
case CRM_ENTITY_ACCOUNT:
alert("This is an Account form.");
break;

case CRM_ENTITY_CONTACT:
alert("This is a Contact form.");
break;
}

[/js]

Żródło: http://msdn.microsoft.com/en-us/library/cc150873.aspx

7,628 thoughts on “MSCRM 4.0 Form Properties”

  1. Betting MLB baseball totals is also common and requires heavy analysis
    into bullpens, starting pitchers, even umpire stats.

  2. Pretty section of content. I just stumbled upon your weblog and in accession capital to assert that I acquire actually enjoyed account your blog posts. Anyway I’ll be subscribing to your feeds and even I achievement you access consistently quickly.

  3. Thank you for the auspicious writeup. It in fact was a amusement account it.
    Look advanced to far added agreeable from you!
    However, how can we communicate?

  4. I do consider all of the concepts you’ve presented to
    your post. They’re very convincing and will certainly work.
    Still, the posts are very short for novices. May just you please extend
    them a little from next time? Thank you for the post.

  5. I am really enjoying the theme/design of your website.
    Do you ever run into any internet browser compatibility problems?
    A couple of my blog readers have complained about my site not working correctly in Explorer but looks great in Firefox.
    Do you have any advice to help fix this problem?

  6. Pretty element of content. I simply stumbled upon your web site and in accession capital to claim that I get actually enjoyed
    account your blog posts. Anyway I will be subscribing on your feeds
    and even I fulfillment you get entry to persistently quickly.

  7. Simply want to say your article is as astonishing.
    The clearness to your publish is simply cool and that i could suppose you’re knowledgeable on this subject.

    Well together with your permission let me to snatch your feed to stay
    updated with impending post. Thanks 1,000,000 and please carry on the rewarding work.

  8. Just wish to say your article is as astonishing.
    The clearness in your post is simply spectacular and i could assume you are an expert on this subject.
    Fine with your permission allow me to grab your feed to keep updated
    with forthcoming post. Thanks a million and please
    continue the gratifying work.

  9. Looking for the ideal providers and their recovery plan combined with the number of
    numerous data centers actually using is incredibly important.
    To compare one thing to another, you have to know what are the right off
    the bat was. The good reason that a Collocation center is popular by the great deal of business entrepreneurs is that
    this affords a particular amount of to protect the key data and applications employed by
    the firm.

Leave a Reply

Your email address will not be published. Required fields are marked *