When I follow the steps in the KB article “Create Embedded Dashboard to Subscribe (KB0052605 )” I can get the example to work, the tracker pulls in the value. But when I try to use UD tables instead of the example tables, I cannot get it to work. The tracker does not pull in the published value.
For example, using the UD100 form, add a dashboard that Displays a BAQ for UD37, with UD37.Key1 subscribing to UD100.Character10. The Character10 value for the current UD100 record does not automatically populate the tracker input like it does in the KB example.
I’ve been going back and forth on a case regarding this since the first of January - can’t seem to communicate or something…
Unless you have a specific requirement to do so, I would not use an embedded dashboard and hand code the BAQ into your screen as a standard dataview.
I or @josecgomez have posted this code in other topics, as well as the refresh and clear code required to have it behave in a native form fashion. So if you need more pieces of this to get the desired effect take a quick search out for it.
private void CreateMyBAQView() {
// create the baq view and add it to the transaction
bdv = new BAQDataView("CMP-MyBaq");
bdv.AddEnabled = true; // This allows new rows in the view
bdv.AddText = "New Record"; // This captions new button on toolbar
oTrans.Add("MyBaqView", bdv);
// publish columns we'll bind to
var binding = "UD100.Key1";
// This publishes a field on the form. It's global so if you have more than one BAQ needing the same published field refactor this
oTrans.PublishColumnChange(binding, Guid.NewGuid().ToString());
var publish = oTrans.GetPublisher(binding);
// Subscribes the baq field to the published form field
bdv.SubscribeToPublisher(publish.PublishName, "MyBaqTable_SomeField");
}
I actually already did that since I couldn’t wait for the case to get resolved. Now I am just annoyed that they claim everyone else can make the embedded dashboards work.
Thanks for taking the time to help.
Maybe I should just close the case and let the bug go…
I would. This is more flexible anyways IMHO a better solution even if it is custom code. You can take this and go to updatable, at which point the world is your oyster. I’ve used BAQs as boilerplate adapters, added Custom Methods and built out my own BO that way no SDK required. The BAQ is the adapter. It’s really pretty limitless