BAQDataView Not Refreshing

I’ve added a BAQDataView using the oTrans.Add method and then set the EpiBinding of a native grid to the new dataview. When I click refresh on the form, the grid does not refresh. Is there more that needs to be done to get this new binding to refresh when the toolbar button is clicked?

I am trying to find a similar solution at the thread below:

Seems to me that there is simply a method call missing.

2 Likes

Jose,

I have a UD table (UD39) set as a child to the Supplier Maintenance screen (via the VendorDetail view). I have three custom fields that bind to UD39. I have a grid view that is populated by a BAQ of UD39 data. I want the grid to refresh whenever a user hits the save or refresh button after adding new data to UD39 via the three custom fields. Right now I have to clear the page and reload the Supplier in order for it refresh with the newly added data. Will the code you shared help with this?

Thanks,

Nate

How’s the BAQ called? Is it a BAQDataView that is subscribed to the parent?

Yeah, here’s the code:

public void CreateCertificationsBAQView()
{
	baqViewCertifications = new BAQDataView("_Vendor_Certifications");
	oTrans.Add("CertificationsBAQ", baqViewCertifications);

	string pubBinding = "VendorDetail.VendorNum";
	IPublisher pub = oTrans.GetPublisher(pubBinding);
	if(pub==null)
	{
		oTrans.PublishColumnChange(pubBinding, "MyCustomPublish");
		pub = oTrans.GetPublisher(pubBinding);
	}
	if(pub!=null)
	{
		baqViewCertifications.SubscribeToPublisher(pub.PublishName, "UD39_Key1");
	}
}

It loads the BAQ fine when I first select a Supplier or when I change the Supplier, but when I hit refresh it doesn’t update with newly added data that was submitted to the child UD table.

Basically, I’m just trying to figure out how to trigger the BAQ to run again as a refresh without having to reload the supplier.

Yeah just call the refresh code referenced in the above post.

Thanks Jose, I really appreciate the help! Not sure if you get tired hearing it, but you’re a life saver!

1 Like