Thank you I have tried this. This default table form works only if you have a table. I tried putting my table name in the code above but get an error.
It all works nicely if your table starts in A1.
Ather
This browser is no longer supported.
Upgrade to Microsoft Edge to take advantage of the latest features, security updates, and technical support.
Hi,
Using Excel 2016. I have data formatted as table but which start on A5. When I run this macro I get the following error.
Run-time error 1004 ShowDataForm Method of Worksheet class failed
Sub DataForm()
ActiveSheet.ShowDataForm
End Sub
Any help would be greatly appreciated.
Thanks,
Ather
Thank you I have tried this. This default table form works only if you have a table. I tried putting my table name in the code above but get an error.
It all works nicely if your table starts in A1.
Ather
According to search results (https://www.bing.com/search?q=ShowDataForm+error+1004), try this:
Sub DataForm()
ActiveSheet.Range("A5").CurrentRegion.Name = "database"
ActiveSheet.ShowDataForm
End Sub