Hi,
So... what's your question?
Wouldn't it be easy to just expose a property on Form 3 that allows access to the Grid? Or a public method on Form 3 that would call the refresh on it's grid?
MainForm foreach (Form frm in this.MdiChildren) { if (frm is frm_MF_Sales) { frm.Activate(); ((frm_MF_Sales)this.MdiParent).RefreshSalesGrid(); }
You are going through Form1's MDIChildren (so the forms opened by "this" which if I read this correctly is the MDIContainer), and then you are trying to cast the this.MDIParent (which if you are on the MDIContainer form, would be null) into your sales form
foreach (Form frm in this.MdiChildren) { if (frm is frm_MF_Sales) { frm.Activate(); ((frm_MF_Sales)frm).RefreshSalesGrid(); }