Trigger a plugin on selection of a Lookup value. RRS feed

  • Question

  • Hi

    1.    I have form i.e "Account". That contain a lookup "contact" and a textfield.

    2.    when user will select a record from contact lookup,  a field form selected contact  should update the textfield.(in Main            form).

    3.    is it possible through plugin.(I can not use java script due to some security reason).




    microsoft blog

    Tuesday, August 27, 2013 7:26 PM

All replies

  • You will need to trigger the plugin on create/update of the entity and filter on the lookup. This means the value won't be pulled through until the form is saved.


    If my response helped you find your answer please show your thanks by taking the time to "Mark As Answer" and "Vote As Helpful".

    Twitter LinkedIn Facebook Blog Magnetism

    Tuesday, August 27, 2013 8:00 PM
  • Hi,
    if you don't want to use javascript (or you can explain what are these security reasons) you can write a plugin that will update the textfield when the record is created and updated. The user will see the value only after he saves the record, will not see the change in real-time (as will happen using javascript).

    You can't trigger directly a plugin when the onchange event occurs (can be triggered indirectly but in that case you need to use javascript, and if can use javascript is useless to use a plugin for this purpose)

    My blog: www.crmanswers.net

    Tuesday, August 27, 2013 8:00 PM
  • Hi,

    If You need to update the entity field during Create operation, you can try this link:


    Otherwise, If You are doing the same on Update of Account entity, try registering your plugin in post Image condition:

     You can just refer this:



    • Edited by Naren MN Thursday, August 29, 2013 5:43 AM
    • Proposed as answer by Paul Nieuwelaar Friday, September 6, 2013 8:41 PM
    Wednesday, August 28, 2013 11:08 AM