Archana,
Your question does not provide enough information about what you are trying to do. I will say that the Help Centre covers information on using Synchronization Robots. There are different "type" settings for these Robots that determine how the code is run. An expression type with run the code periodically (Documentation states every couple of seconds) to evaluate if a condition has been met and proceed if true. An Object type will "listen" to events on the Object supplied by a variable and you can choose which type of event your Robot is listening for and evaluate accordingly. One example is listening for a State change and processing if "State A" then do this otherwise do that (result = this, result = that). The last is Class type where the Robot listens for events emitted by all objects of a given class.
I will qualify the above with this being my understanding. Experts - if I have misinformed please correct.