Dim pCmdItem As ICommandItem Dim pUID As New UIDClass() pUID.Value = "{256176AD-0C33-406C-9ED8-9F7AC784A3E3}" pCmdItem = My.ArcMap.Application.Document.CommandBars.Find(pUID) pCmdItem.Execute() Dim tableWindow As ITableWindow3 = New TableWindow Dim pSet As ISet = Nothing tableWindow.Application = My.ArcMap.Application tableWindow.FindOpenTableWindows(pSet) pSet.Reset() tableWindow = pSet.Next While Not tableWindow Is Nothing If tableWindow.IsOpen Then tableWindow.TableControl.RemoveAndReloadCache() tableWindow.Refresh() End If tableWindow = pSet.Next End While
Do you have a query filter on the layer by any chance?
I apologize for bumping an open thread (there are so many without answers in this forum, which is quite disappointing to me), but I am having the same problem.
When I insert a value into a Field within a FeatureClass or a Table of a Feature, it doesn't reflect visually.
How can I refresh my Attribute Table I have open, as shown in my picture, programmatically.
Thank you for the time.
EDIT
And now for my solution, however this will not directly solve the problem of targeting a specific table window:
public void RefreshOpenWindows()
{
ITableWindow pTableWindow = new TableWindowClass();
pTableWindow.Application = ArcMap.Application;
ITableWindow3 pTableWindow3 = pTableWindow as ITableWindow3;
ISet pTableSet = new SetClass();
pTableWindow3.FindOpenTableWindows(out pTableSet);
pTableSet.Reset();
ITableWindow pTableWindowTemp = pTableSet.Next() as ITableWindow;
while (pTableWindowTemp != null) {
pTableWindowTemp.Refresh();
pTableWindowTemp = pTableSet.Next() as ITableWindow;
}
}