Dynamics CRM Support Blog
Problems configuring the CRM Outlook client? Use the wizard!
CRM Resource Center
FAQ About Technical SupportOnline | On-Premise
FAQ About Billing
Microsoft Dynamics CRM Developer Center and SDK
I have a custom entity called "TID" which contains a lookup field to it's parent (Account). There are several fields of data on the parent, that apply to the child (TID) which need to be displayed on the TID record. I'm having trouble figuring out how to display these applicable values on the child record.
FYI. The parent almost always has multiple children records, Which means if any of the 10-15 fields from the parent need to be changed, those changes would be reflected on all child records, avoiding the necessity of having to rekey all changes on not only the parent ,but on each child, which can obviously lead to inadvertantly not updating all applicable or typo's...
If more clarification is necessary, I'm happy to give specifics.
ps. the parent fields that display on the child would be Read Only (uneditable from the child), which means they could only be edited on the parent record.
Can This Be Done!
Just noticed this question, sorry no-one replied to you earlier, and while I realise you may not read this, hopefully the answer may still be useful for others that find this thread.
You don't mention your CRM version, but if it is 2011 then a great way to do this is to not copy the information from the parent to the child at all, but rather display it using an HTML resource which you can embed on the child record's form.
This article has a great example, with code:
You can of course show the parent record values in view natively, and use them as part of a query, so unless you need to use them in a workflow running against a child of the child then this technique is probably best.
Hope this helps. Adam Vero,
MCT, MCTS:CRM 4.0, 2011
Thanks for updating this question. We have a similar requirement, but a few points arise:
1) The Gap Consutling link is broken; I suspect that the blog was archived last year. Do you know of an alternative?
2) You state 'you can of course show the parent record values in view natively' - do you mean that, for example, a form showing account details could display values from the related parent account (via parentaccountid)?
3) We need to extend point (2) to display a list of records related to the parent account (1 account : n records). The account form has a list section to show them but this picks them up only for the parent account. Am I correct in thinking that that is where your suggestion to use the web resource technique would come in? Or might it be possible to tweak the selection condition in the list ('show only related records') to include those related to the parent account as well?
4) Is it possible in an advanced find to list all accounts with a particular related record type and all of their child accounts? This is an attempt to 'flatten' the list for a particular output, but if it can't be done it is not a worry; we can use a report for it).
Sorry to throw so many questions at you.
1) This is an internet archive version of that article (not great to read in this format unfortunately):
Another similar idea here (this example shows data for Primary Contact, but the principle is the same):
2) No, you can easily shows values from a parent record in a VIEW, not on a form. For a Form, see (1)
3) This might help: blogs.msdn.com/.../deep-queries-for-subgrids.aspx
Technically unsupported, but essentially steps for how to create a grid on a form using any query you like, so should be fine for parent account to be included. Not sure if you can do an OR on this (records related to this Account OR the Parent Account). you may have to have two grids, one above the other.
4) In advanced find, you usually have to start at the bottom. So you could list all (child) Accounts which have a Parent Account which has some property or other (or is related to a specific type of parent or child records, which in turn may have some specific properties). In other words, you can't find the parent accounts and ask it to list the children, you go look for the children based on their relationship to a parent you are interested in.
Thanks very much for the link and explanations. Sorry for the delay in acknowledging; I forgot to enable email notifications and I'd moved on to other work temporarily.
You my also use this from codeplex (crm2011lookuppreview.codeplex.com) which is in the same tenor of idea than the second one from Adam before.
Let me know if this helps :)
Microsoft Dynamics CRM Consultant
Other Microsoft Sites
I'm a Customer
I'm a Partner
Use the official Twitter tags:
#MSDYNCOMM | #CONV13