Thanks for your advice, I have tested 1)I use a frameset with only 1 frame content called “Main”, I use “Call notesUIWorkspace.SetTargetFrame(“Main”)” as suggested to test for my button, it shows “Target frame is ancestor of script object”.
SetTargetFrame seems just useful for two frame contents. When button in “Left” frame is pressed to open document on frame “Main”, it is ok but button in “Left” could not open doucment in “Left”.
For 2)
I would like to open another window but not tab(that means i can drag the new one to another screen), any suggestions? thanks