Sorry if the title is rather vague, but I am writing a simple application, sort of a multifunctional xml ide/text editor kinda thing and was wondering if you editied a file in window1 suppose, and you have 3 windows open, so when you click the save button how do you make sure that you save the one that you want? I mean by default usually it is the text window that is already selected or the one that is higher above in the layering scheme right? How would you recommend going about it? I know how to write to the disk but I am wondering how i would get the particular file windows contents that I modified to save. Thanks a lot. If my post does not make sense let me know and I will repost.