Quantcast
Channel: Microsoft Dynamics CRM Forum - Recent Threads
Viewing all articles
Browse latest Browse all 82002

Passing Data From Form to Quick Create Form Via "+" Button On Sub-Grid

$
0
0

Ok so here is the run down of what I am trying to do.  We have form that has 7 sub-grids on it.  All the sub-grids go to the same entity but use different views.  There are 7 different relationships setup.  In the mappings area those relationships show up and as we all know, you can't delete those.  We then have a quick create form for the entity linked to the sub-grid with 7 lookup fields.  The problem is that since there are 7 relationships all the lookups get populated with the same value.  We don't want this, we only want the one lookup to populate that we care about.  This is because of filtering I need to do against the another lookup field (that code I have and it works).  Here is what I have tried:

1) JQuery to get the "aria-selected" attribute of the tab that the user is in.  In unified interface this value is set to true when the user is in the specific tab and false when not.  My thought was if I could get this value, then I could use "setSharedVariable" on the execution context to pass a value to the quick create form.  That way when an onload script runs on the quick create to null out the lookups, it would skip the one I wanted.  Issue is JQuery is not supported and always return null when trying to get the "aria-selected".

2) We have tried to remove the relationships in the mapping, but you can't.

The main issues I am running into that would make this easy to do would be a get focus event for which tab the user is in.  Also thought about using a hidden option set but I have to have a way to dynamically set and save as the user goes down the form.  That would be extremely complicated.  Also, we have talked about splitting it out to 7 different entities that all do the same thing, but that is a bad design approach.  I have also considered using Ribbon workbench, but I have run into so many issues with it crashing or the buttons just stop working, that I don't want to consider it.  Also keep in mind that I don't want to use Xrm items since the majority of them are marked for deprecation.


Viewing all articles
Browse latest Browse all 82002

Latest Images

Trending Articles



Latest Images