I need to hide a my data table after opening but my table doesn't have a specific name, so I cannot use invisible command.
I'm using following script but it doesn't work. I appreciate any suggestion. Thanks
dt << show window(0);
Your script works fine for me. I'm able to use it to open a data table that is invisible.
When you say the script "doesn't work" do you mean that the data table remains visible, or does it not appear at all (even in the window list)? Is it possible that, if the table is very large or if the table is open from a remote location, the script needs to pause to let the table open completely? In that case, I'm guessing that inserting a Wait(1.0); command between your two lines of code could help. Otherwise, check for typos.
I mean the window is still visible for me.
you said "I'm able to use it to open a data table that is invisible" but my purpose for using it is to HIDE a table that newly opened and visible. do I use a wrong command?
I should clarify: I'm able to use your script to open a table, and the table BECOMES invisible immediately.
If the table is already open and visible, and it is currently your active table, you can "name" the table and make it invisible as follows:
cdt = Current Data Table();
cdt << Show Window(0);
I don't know why it's still visible for you. However, as you see, Vince's solution should definitely do the trick for you.
There are no labels assigned to this post.