Thanks Shabbir.You mean to say I should use timer.In the timer i should check for IE, once found run the required function.Is it like that?If it is,i already done that.The problem is that by that way the process becomes slow.What i have done is.I have function check which will get all opened windows.Then i will check for windows title.If it is internet explorer the navigate to some url.But this process becomes slow.So I thought of another way like this where my program gets fired when user clicks internet explorer.For example systemdevicearrival function.This function fires when some device is inserted.Similary i want my program to fire when ie is clicked.Got it?