Friday, September 18, 2009

The Art of Changing Easily & Gracefully!!!

  • Accept yourself exactly as you are.
  • Focus on what you want, not what you don’t want.
  • Get familiar with what you want.
  • Focus on changing your thinking, rather than focusing on changing your behavior.
  • Break your change into small, achievable steps you can take on a daily basis.
  • Practice, practice, practice.
  • Surround yourself with people who are being the way you want to be and living the life you want to live.

Passing information between parent and child window.

Had a problem in fixing a javascript scenario of passing information between parent and child window.

If you are going to assign a parent windows variable from child window, that variable has the assigned value , even if the child window is closed.

But if you try to assign an object like array or something in the child window, the assigned variable or object exists in the parent window only if the child window is still open. If the child window is closed , the variable becomes null.

It seems, in this case the parent variable just has the reference to the variable in the child window and not the exact values.

In my case , i want to pass array from child to parent window and i did in the following way.


function settingParentWindowVariable(obj)
{ if(obj.length>0)
{
for(var i=0;i
parentvariable[i] = obj[i];
}
}
}

I am not sure, whether it is the correct way of doing it.But it works in this case.

PS: There exists Tech post. Atleast to serve my bad memory.

Politically correct!!!!

The Prime Minister of China called President Bush to console him after the
attack on the Pentagon:

"I'm sorry to hear about the attack.It is a very big tragedy. But in case
you are missing any documents from the Pentagon, we have copies of
everything."


Musharraf calls Bush on 11th sept:

Musharraf: Mr President, I would like to express my condolences to you. It is a real tragedy. So many people, such great buildings... I would like to ensure that we had nothing in connection with that..

Bush: What buildings? What people??

Musharraf: Oh, and what time is it in America now?

Bush: It's eight in the morning.

Musharraf: Oops...Will call back in an hour!

Vajpayee and Bush are sitting in a bar.

A guy walks in and asks the barman,"Isn't that Bush and Vajpayee?"

The barman says "Yep, that's them."

So the guy walks over and says, "Hello, what are you guys doing?"

Bush says, "We're planning world war 3".

The guy says, "Really? What's going to happen?"

And Vajpayee says, "Well, we're going to kill 14 million Pakistanis and one bicycle repairman."

And the guy exclaimed, "A bicycle repairman?!! !"

Vajpayee turns to Bush and says, "See, I told you no-one would worry about the 14 million Pakistanis!"