Thursday, February 28, 2008

Application of Interest - K-Lite Mega Codec Pack

It is always a big problem if you can not find an application which you desperately need it. The main problem is to find a suitable application which will run any video\audio files. In this regard, the VLC player is the best one. It runs almost all the format of video files and is of great use to young people, and it is also free.

But there was a specific need for me to find an application that will extract the audio out of the video file. I am quite sure that there will be hundreds of application that will be available to do this, but I am quite tired of searching for them. Recently I downloaded a video file from youtube and the format is of .flv and I did not have a proper codec for windows media player and I did not VLC player also.

But I remembered there is a codec called k-lite codec which when installed will give your windows media player some great abilities and will enable it to support many video format. So, I installed it and enjoyed the video. I wanted to extract the audio also. Intuitively I explored the application and found that it is possible in the codec itself to extract the audio.

So, I thought it will be of use to many and I am talking about that. The application is K-Lite Mega Codec and it is free. Once you install it and run a video using that, you can go to File->Utils->DSM Convertor. Right click on the panel and browse your file. Once you select a file, all the components will be shown. Right click on the audio and select "Demux" and that is it. The audio will be saved as an mp3 file and you are done!

Click here to download the K-Lite Mega Codec.

[P.S.: If you are so curious as to know what is the video I enjoyed and wanted to have the audio ripped off, click here. You could also click here to know more about that.]

Wednesday, February 20, 2008

The Dark Future

I sometimes wonder how is it possible for people to incur a great loss in shares. Why should someone lose money when the market crashes? Why don't they simply keep the shares and sell it when the market again goes up? The answer to these questions is, there is a dark concept called *Futures* in share market. It could give you in thousands and take back millions. Lets see how it works, again, I am not an expert in share market and what I say here may be wrong, and in that case, please let us know of the correct concept behind it.

As the name *Future* suggests, this concept is about the value of a share in the future. That is you buy only in lot (here lot means groups of shares, for example, Tata Motors has lot of size 412, Sathyam has lot of size 650, Moser Baer has lot of size 800, etc.). But the amount of money that the broker will take will be very less. If for example, if 650 shares of Sathyam cost 2.8 lakhs, you only need to have about 50 thousand. With 50k you can buy a lot worth 2.8l.

If the price of the share increases 2 rupees, you will gain a profit of 1300. You can book the profit and enjoy. On the contrary (actualy, there is no contrary here), if the price goes down by about 10, and if you do not have enough money to back up, you will get a call from the broker asking you to have more money in your demat account. If at the moment, you do not have the money, the broker will simply sell the shares, without even asking you, and will force you to lose 6500.

So many people get bankrupted because of this reason due to crash. They would have invested all their money in (dark) Futures, and, during the crash, if they can not put more money in their account, the broker will sell all the lots and say: 'You now have 0 rupees in your account. Better luck next time'. That is it. You are bankrupted.

Lets see in the next blog about ways to escape from the dark Futures. Share you comments as well as your experience in futures (if you have) here.

Wednesday, January 30, 2008

The Tale of Two Friends - Part I

[Disclaimer: This is the only series of blogs in which I do not expect any comments, in the sense, every time any blogger publishes a blog, his\her intentions will be to get appreciated or at least criticized by comments from readers, in my opinion, and I am no exception to that; but this series, I write for my own self-satisfaction and I do not expect people to like it and comment about that (illana mattum, comment kumiyuramadhiriye pesuven naan :D ). Ultimately, what I want to say is that, this series may not be interesting.]

I just want to write at least one blog per month for this series and I will finish this series by the end of the year at any cost. The hero of our story is Aravind. The story will move mostly in his views. Okay, shall we start our story? On one fine Monday morning, Aravind, woke up and [ippduiyellam eludha aasai thaan... but let me follow my own style...]

The innocent Aravind entered into the room which was allotted for him. He was equally excited as he was afraid of the new environment, but he was not worrying about the school friends he had left behind in his village. Actually, he did not have remarkable friends over the past, the reason being, he was so innocent and sincere about his studies that he did not have time to make great friends. The room was empty. It was not fully occupied as it was supposed to be. The immidete fear was about the seniors of the college. Had the seniors entered into the room and had taken all of the first year students to rag? was it possible that they may come again to check for new comers again? "I should have asked my parents to stay with me at least for one day", Aravind told himself.

The fear of ragging increased as he could locate other suitcases and baggages of other room mates. The whole premise was very silent. So, he kept his luggages in the room allotted for him and ran down to talk to the securities about other first year students. To increase his fear and desperation the security was not there. Aravind wanted to search in other rooms in the building. Thank God, there were a few first year students available in other rooms. In one of the rooms, there was only one student sitting in one of the 6 beds. So, Aravind decided to inquire about the silence to him.

"Hi, I am Aravind. I have taken Computer Science. Do you know anyone from Computer Science?"
"You don't seem to be interested in knowing about me. First of all, you should have asked my name. Then you should have asked which department am I from. Or at least, you should have asked which year I am in!", threatened Murugan.
"Sir... sorry... I thought you are a first year student. Shall I leave?"
"You call me a Sir? Am I looking too old? Or have I taught you lessons before? Of course, I will teach you lessons now... but you want to leave? Where are going to go? Come and sit down near me. By the way, what is your name?"

Aravind became very pale. He did not know what he should to do now. Run away? or plead him to leave him? Running away will be most stupid thing he could ever do. So, with all the remaining courage in his body, Aravind went near him and sat.

"Look here... he is sitting near me without even asking permission... damn it... go and lock the door and come here. You are about to punished for the crimes you have done now...", said Murugan angrily with a slight smirk on his face.

Aravind now came to realise that his first day is going to be memorable throughout his life. But he wanted the day to be memorable in the other way. Fear mixed with anger made his eyes red and soon the red color got paled due to the water that had gathered in it. Tears in Aravind's eyes almost burst out when Murugan stood up.

to be continued...

[P.S. When I was typing in the desclaimer, "this blog may not be interesting", I myself chuckled, as many of you might have thought, 'this is not the specialty of this series of blogs.' :D. All the character and events in this series are supposed to be fictitious. This story may not be about any real person.]

Tuesday, January 22, 2008

A Good Thief - but not the one like a Hero in a movie

It was 6 o'clock in the morning my friend woke up to get ready for practising Veena (here Veena means the music instrument :D and nothing else). Rubbing his eyes he went out to hall and was shocked to see that the door was ajar. It is so impossible for anyone else in my house to have gotten up that early, at least 6 o'clock is almost like a midnight for us. To make sure that nothing was wrong, he went to the other room to check anyone has woken up.

As you can guess, no one was awake. He panicked and woke up others to let them know that the door was ajar and everyone has gotten up (except me, I was in a good dream then). They were shocked to know that 2 of their purses are gone and one of the mobiles is gone. The friend who woke up first did not lose anything as he and I always lock our room's door. When the whole house was in panic and everyone was calling for credit card customer care to block their card, I woke up.

The moment I heard that some theft had happened, all my attention went to my purse and my purse was sleeping silently in peace. Happy that it was not abducted I went to inquire about how it could have happened. It is still a mystery. We locked the doors with 2 latches. How that bloody **** (any bad word that pleases you) has opened the doors and how he was so daring to enter the rooms and took the purses and mobile, only He knows.

So, we came out of the room and I saw a Rs. 2 coin was placed on the wall just outside our house. It was a good comedy then. One of the my friends who lost his purse had not kept any money in the purse. May be the thief indicated us that, *come on guys... keep some money in the purse... you just had Rs. 2... for this bloody stupid money I had to do Alohomora*. We laughed (yes, we laughed in that misery also). The friend who woke up first has seen the other side of the wall to find out the purse and the wrist watch. All the cards were intact.

So, we had some hunch that, the other purse may also have been thrown some where and we started to search. The same friend, who woke up first and who found the first purse, had somehow managed to find the other purse, which was hidden under clothes. Again, all the cards were intact and only the money was looted. But the mobile which was gone is gone. So, we made fun of the friend who woke up first, to find (or give back) the mobile also. We were very happy that at least the cards are safe.

This incidence made me to write this blog, the next day of my previous blog, which the market made me to write. A Good Thief. The thief had some soft corner on as and left the purses and the cards. Though it will be impossible for him to use the cards, as we would block it before he could use it, he might have simply thrown it some where. Or, who knows? He might have noted down the details of the cards and he may use the details to purchase a flight ticket to America in some days. But I strongly suggest to you that, do not give place to good thieves. They may get better and become the best thieves.

It is always better to think how anyone could break through your doors and loot; and take necessary prevention or precautions for that. I heard similar incidences from my friends many times but was lethargic that it wont happen to us. And, it had happened to us no matter how much we were cautious. So, be double safe. Think like a criminal and do the counter part by yourself. Keep your doors locked always and only open it when you really need to go out. Or, you can do one thing. Write a blog about your experience also, when it happens to you in the future :D

[P.S.: If you do not know what is *Alohomora* please read Harry Potter, at least the first part]

Monday, January 21, 2008

Don't Catch a Falling Knife!

Its been a long time since we talked about Share Market isn't it? So, I just wanted to share some of the theory I have heard about Share Market. Again, I want to tell you that, I am not even close to novice regarding Shares, but I have heard about them a lot. And the theory which I want to talk about it is: Don't catch a falling knife. And that too, at this point of time, this one will prove to be a good theory everyone (every novice in market) must bear in mind.

It is a common mentality for people to do exactly what is to be done and unfortunately that applies to Share Market as well. We tend to sell rising shares (shares whose price increases) and to buy falling shares (vice versa). According to theory (why I say *theory* very often is that, there is NO PROVEN technique which could gain you money in shares. Please click here to know more) we should buy rising shares and sell falling shares.

What one might think when a share falls is that, they can buy it and sell it at a later stage. But no one knows when it will start to rise. It may continue to fall for a long time and it may take still longer period to rise or it may be there in the low price for years. So, some share is falling, it is always better not to buy it, unless it starts to rise. (Again, it may rise one rupee and fall 10 rupees).

This could also be a common case. Someone buys a share. The price goes down for some limit and then it starts to come up. The moment, it has touched the buying price, anyone will be tempted to sell it for very less profit. This could also be wrong. Since, it is in rising phaze, it may go up for some more limit. The buyer could wait for some more time for the share to go up for some more limit. (Again, it may touch the buyer's price and fall 100 rupees.)

So, enna dhaan da solla vara ***** (some bad words) nu neega kekalaam. One advisable thing to do is to, when the market crashes i.e. when it falls, do not buy any shares until the market gains some support and start to rise. (Again, who knows when, the real support, comes to market? It may act as though it has got some support and when many buy shares, it may again fall still more... enna koduami sir idhu!!!)

Monday, January 14, 2008

Forward Mails

[Disclaimer: Not recommended for very sensitive people. I am not responsible if you are hurt by this blog. If at any point of time, you realize that you may be offended, please do not read further. I want every customer of my blog to be happy and I want everyone to come again.]

Hmm... nothing new of course. What to do? Having some free time. So, thought of talking something about Forward Mails. To make this mokka topic (still more mokkai or) somewhat interesting, let me tell you a story first, which was published in the first or second edition of Chip Magazine on 1997 (First Chip came as Chip and then it got renamed to Digit and then again new Chip started to come. I do not know whether both are available nowadays).

One of the authors of the magazine got a mail, with a story: A lady (or for 100% sure, in the name of a lady) writes a mail that, she has gone to a hotel and had a special dish that she did not inquire the price of the item that it turned out to be very costly that she was embarrassed for not having enough money that she wanted to take revenge for the hotel that she has somehow managed to get the recipe for the special item that she is going to make everyone aware of how to make the dish that she is sending a mail with the recipe that we all (all fools and vettis) have to send the mail to everyone they know of. The author with a shame admitted that he even forwarded the mail without analyzing that he later recognized that that was a junk mail, I am not clear.

Those were about 10 years earlier, when very few knew about these junk mails. Later, this has taken multiple forms and the most irritating (sometimes making me to talk very [really very] bad words) form is: AOL and\or Microsoft has admitted to give you 5 paise for every time you forward this mail that we have to forward the mail to everyone we know of. Bloody shit! what the ****? Why in the **** AOL or Microsoft has to give us money for simply creating junk traffic in the internet world?

Later all the fools recognized that they were fooled, that they did not even ask for bank account or anything that the money could not reach them. Later it took another form that if you forward a mail to your friends, someone else will get the money (aanalum idhaiyum namburaangapa, I do not know how). Someone who lost a child and husband needs to undergo operation or someone who is very poor needs money to undergo operation something like that. AOL and Microsoft does not have anything to do and they have created a very complex algorithm to track where and all the junk (and ****ing) mail goes and they will one day knock your doors and give you a cheque. Is that so?

People somehow recognized about this nature of mails also. And now, it has taken a very sensitive form which is what confusing me. A 2 year or 3 year old child needs to take a open-heart surgery and they need blood and that we have to forward the mail to everyone we know of so that someone could help them. Since this is very sensitive, I can not simply say that it is junk. I have never known anyone who personally knew the subject-in-need. So, if at all you do not know (or at least you know the someone who knows the needy person directly) please do not forward the mails.

Just because there are 1000s of junk mails a real needy person should not miss what he desperately wants. I never forwarded any mail which asks me to forward it (unless the theme of the mail is to make the other laugh). I have it as a policy. I might have done a mistake of not forwarding a real genuine mail. But the chances for the Forward mails to be genuine is one in a million, in my opinion.

There is one more form which is also equally irritating. Asking us to forward a mail with a friendhip band (****ing band) that we have to send to all our friends. And the most ****ing part of the mail is that, it will ask us to send to the sender itself if he is our friend. This will create an infinte loop isn't it? Bloody ****! We don't have to be a bloody fool to be friend of a bloody fool. If that is the only way possible to prove that we are a friend to the sender, lets part from them, in my opinion.

But this is not the only medium these junk things are availble. It is present for centuries I hope so. I even got a letter (postal letter) when I was studying in school that I had to write the same content and send letters to 20 or 30 people. If we do that, we will get luck in a week, otherwise, we will die (or lose something or something disastrous will happen). God does not have anything to do and he watches and makes sure that all the people he created are behaving like fools. Is that so? This is even available in e-mails also.

The tougher part of the story is that, even brilliant, educated people send these junk mails. That is what disappointing. Lets hope these junk things are extinguished at least in the future or make sure that at least we do not do these junk things.

[P. S.: Sorry for writing such a big blog. Everything I told is in my opinion. Your opinions are most welcome. I am sorry, if any of you are hurt.]
[A.P.S.: To make this junk blog a junker one, I wish to say this: *Please let everyone you know of to read this blog* :D eppudi, mulla mullala thaan edukanum [diamond cuts diamond])

Thursday, January 10, 2008

Water, the elixer of life!

The problem with my blogs is that, I tell what everyone knows and what everyone is tired of hearing. But what else could I do? I could not find anything unique to talk about. So, let me tell what everyone knows in a way that not everyone knows (oxymoron?). The unique advice is, drink water! (how is it? you could never have heard this advice :D)

The reason why I give so much of importance and spend a decent amount of time (in vain), is that, I learnt a lesson and I wanted to share it. May be a life lesson, who knows. In the recent times, I am spending quite a lot of time in front of a computer. Actually, I spend most of my time in front of the computer, but in recent times, it is very high! And obviously, my intake of water level has come very down. Drinking water when I have breakfast, lunch and dinner and before going to sleep.

Didn't realize the effects for some time. Spending happily a lot of time in front of a system. My eyes got affected (many may think: wow, what a discovery? bull-shit, don't I know that?). But, my eyes got affected in a different way. It was watering and I was not able to continuously look at the monitor. Water kept coming out of my eyes. Horribly distracting. I was wondering, if my eyes got weakened, it should pain. It should not behave like Niagara.

Luckily I got a forward mail. I usually do not read forward mails (click here to find how much I hate forward mails), but that one I read (may be because I did not have any work at the time) which compared the Water and Coke. I thought of deleting it right away, but it said about the goodness of water, with some valid points. As I kept reading, I saw that "
A mere 2% drop in body water can trigger fuzzy short-term memory, trouble with basic math, and difficulty focusing on the computer screen or on a printed page".

Though it is my policy, never to believe anything that comes from a forward mail, I took that seriously and started drinking water madly. Every now and then. As much possible. And you may not believe me, I felt better. My eyes don't water now. May be it is because of something else... or mere psychology.... I do not know. But I think drinking more water could not harm us, but if we take less, we will surely suffer.

[P.S.: We can have a habit like this, to drink a lot of water, I mean a lot of water, whenever we visit rest rooms (of course, not in the rest room... but where you could get drinking water :)). In that way, we will have to visit rest rooms often and drink water often. It may also help us for avoiding back-pain by not continuously sitting and also, it could give us a break. Your views are most welcome! Let me go and have some water.]


[A.P.S.: One of my collegues said that I even became fair. I was happy; that, my theory is right. His intake of water should be less :D and that his eye sight has terrible problems (A.P.S. = Another P.S.)]

Monday, December 31, 2007

A Tale of Two Friends - New Year Gift! (or curse?)

After much contemplation, I have at last decided to write a story in my blog. This story will be continued for a lot of episodes, I am thinking now. It is my long time dream to do so. I was contemplating about the fact that, I do not want to make the very few people reading my blog to run off from my blog forever. But I do not want to follow the policy *Never try... never fail...*

[Disclaimer: Weak hearted, pregnant ladies, Old people please do not read this series as it will be so boring and torture that you may not survive after reading this :D]

I do not want to start the story in this blog itself. Let this only be a build up and a start for the story. What should I name the characters? How many episodes should this come? How long can I write this? I have no idea! Do I know the storyline which I have to write? No!. Do I have a better and a clear script? No!

Then how dare am I going to write such a story? could be your question. Have not you heard about mega-serials? They are my motivation. They prolong the serial for years and years with no story or a nastier-than-a-cow-dung-story. But I promise, my story will not be as bad a bull shit as them. Even if they may be very bad, they wont be pointless, I presume.

Okay, see you all in my A-Tale-Of-Two-Friends blogs. I will post other blogs also in the middle. See you soon!

[P.S.: First I had an idea of asking the reader to tell their comments and start such story only if at least one has interest in and has commented. But I abandoned the idea, as I am quite sure, none will actually post any comments and I do not want to promise-and-withdraw. So, I silently started this!]

Monday, December 24, 2007

பொன்னியின் செல்வன்

மதி மயக்கம் கொள்ள செய்யும் ஒரு அருமையான காவியத்தை, நான் சில நாட்களுக்கு முன்பு படித்தேன். பொன்னியின் செல்வன். தமிழ் மீது காதல் கொள்ள செய்துவிடும் அந்த காவியம். கவிதை மீது காதல் கொள்ள செய்துவிடும் அந்தக் கதை. மற்ற சாதரண கதைகளை காட்டிலும் இக்கதையின் சிறப்பு என்ன? இது நாம் தமிழ்நாட்டின் வரலாறு. ஒவ் ஒரு சம்பவங்களும் நம் தமிழ்நாட்டில் நடந்தவை. தஞ்சை பெரிய கோவில் கட்டிய ராஜ ராஜ சோழனை (அருள் மொழி வர்மன்) பற்றிய கதை. உலக அளவில் அதிசயமாக கருதப்பட்ட பெரிய கோவில் கட்டிய மன்னாதி மன்னனை பற்றிய கதை. ஒவ் ஒரு தமிழனும், குறிப்பாக தஞ்சை மார்க்கத்தில் உள்ளவர்கள் படிக்க வேண்டிய கதை.[என்னடா ஓவரா பில்ட் அப் குடுக்குராநேனு நேனைகுரீங்கள? அப்படிதான் அந்த கதையும் இருக்கும்... ஏக வர்ணனைகள்.. எக்கச்சக்க பில்ட் அப்புகள் அந்த கதையில் இருக்கும் என்பதை உணர்த்தத்தான் அவ்வாறு கூறினேன் (அனால், அக்கதையில் வரும் பில்ட் அப்புகள் ரசிக்கும் படி இருக்கும், இந்த ப்லாக் மாதிரி மொக்கையாக இருக்காது)]


மன்னர்கள் எப்படி மக்களுக்காக உழைத்தார்கள்? மக்கள் எப்படி மன்னர் மீது அன்பு வைத்திருந்தார்கள்? வீரன் என்பவன் எப்படி இருக்க வேண்டும்? அரசன் என்பவன் எப்படி இருக்க வேண்டும்? நாட்டில் குழப்பம் செய்யும் சதிகாரர்கள் எப்படி இருப்பார்கள்? இது மட்டும் அல்ல... கண்டதும் காதல், கேட்டதும் காதல், பழகியதால் வரும் காதல், காதலுக்காக உயிர் விடும் காதல், என்று special attention காதலுக்கும் குடுக்க பட்டுள்ளது.


இதற்கு மேல் என்னால் continue செய்ய முடிய வில்லை. அதனால், இந்த கதையை படிக்க வாய்ப்பு கிடைத்தால் கண்டிப்பாக படித்து பார்க்கவும். இந்த ப்லோகையே இவ்வளவு தூரம் படித்தீர்களானால், கண்டிப்பாக, அந்த கதையை வுங்களால் படிக்க முடியும் என்று உறுதி கூறுகிறேன். இனிமேல் தமிழில் ப்லாக் எழுதினால் கை கால் முறிக்கப்படும் என்று வுங்களில் யாருக்காவது தோன்றினால், கண்டிப்பாக கூறிவிடவும், இல்லையேல், நான் மீண்டும் தமிழில் ட்ரை பண்ணுவேன் என்று எச்சரிக்கை செய்கிறேன்!

Tuesday, November 06, 2007

A Puzzle and A Joke!

Try to answer this puzzle: A man (or a woman; in this case please replace all the *he* with *she*) has to guess the number which will result by throwing 2 unbiased, perfect dices. There are 11 possible numbers (from 2 to 12) that could come by using 2 dices and he is given 11 chances. He has to guess correctly (luckily) at least once otherwise, he will be killed. In the first ten chances, he simply says 11 and in all the chances the resulted number is 10. So, he has only one chance remaining. So, what will you guess for the 11th chance if you are in his shoes? Guessing which number could save your soul?

The answer is, if you want to take some more time, you can very well think and read further. The next statement will be the answer. Okay? Ready? The answer is, whatever is the number he guesses, he has 1\11 chances of saving his soul. This is because, the result from tossing a dice is 100% random and each and every time, it is tossed, it is a separate and unique event which has no connection with the previous results.

I do not know why, but nowadays, I am little or even more interested in share market. May be it is because my time is becoming bad or because it is becoming worse. This puzzle has a 100% valid connection with share markets. If the market goes up continuously 10 days, we can not be sure that will go up on the 11th day. We can not predict how it will go even within a single day or a single hour or a single minute. For, if anyone could predict that or control that, he\she will or will soon have an own aeroplane. Share market is like a black hole which contradicts a lot of concepts. Calculation, Brilliance, Analysis, Luck, etc. concepts are devoid in share market. For me share market is like a pet lion. It could be your pet for years and years and one day it could kill and eat us.

Lets come to the joke part (it is VVPJ (very very PJ [poor joke])). I and my dad was discussing about a company's share.
My Dad: "We have 500 shares of that company but it does not seem to increase. If a share lingers in a particular price, it is an indication for a break out. Either it could go up rapidly or go down rapidly. But I guess it will go up, but could not say when"
I: "I could say easily dad. If we sell all the shares, it will go up the next minute"
That is all. The joke is over. It was to mean that, we have had a lot of bitter experience that, the moment we sell a share losing the hope, the next minute it will increase and go up rapidly.

I think I will post some more blogs about this lovely killing beast. You may click here to see my first blog about share market. Keep watching both my blog and the market.

Wednesday, October 10, 2007

A Truth About setAccelerator method in JMenuItem - Technical Article in Java

[Disclaimer: This is going to be my first (and may be the last) technical blog. If you do not understand the subject (especially the words JMenuItem or Java), please click here to go to my previous blog.]

There is a special method called setAccelerator() in JMenuItem which is used to invoke the action listener method of the menu item without navigating through the menus. Simply pressing the key combination would give an effect of clicking the menu item. The most famous accelerators are (ctrl + c, ctrl + v, ctrl + z, ctrl + s, ctrl + a, etc.) which will be available for almost all the applications.

Suppose, if we develop our own application which has a GUI (Graphical User Interface), we will definitely have a menu bar and various menu items placed in different hierarchy of menus. Setting mnemonics is one way to let the user access the menu items without using mouse. But using mnemonics will require the user to navigate through various menus and there could be menus inside menus inside menus, etc. So, for power users, it is best we have this accelerators set.

To do it, we have to use the method setAccelerator() for the particular JMenuItem object. This method takes a KeyStroke object as an argument. This KeyStroke object defines which key stroke combination should be used to activate the menu item. The beauty about this KeyStroke class is that it has various ways to achieve a particular key stroke combination. It has many overloaded methods named getKeyStroke which takes various combination of arguments.

Suppose, if you want to set an accelerator of ctrl+x, if we set the accelerator using menuItem.setAccelerator(KeyStroke.getKeyStroke('x', InputEvent.CTRL_MASK)); it wont work!!! The character argument is considered as an int and it wont work. So, if we use menuItem.setAccelerator(KeyStroke.getKeyStroke(KeyEvent.VK_X, InputEvent.CTRL_MASK), then it will work fine. But what will we have to do, if we have to set the accelerator based on some runtime input or if we really want to use a character instead of KeyEvent object.

We have one more alternative, and we will be tempted to use KeyStorke.getKeyStroke(new Character('x'), InputEvent.CTRL_MASK). If we use this, we will see that, the accelerator we set, is mentioned in the menu item. But if we use the key combination, it wont work. Because, the key stoke object thus we got is decoded in to "ctrl typed x" but for accelerator it should be "ctrl pressed x". Fortunately, the KeyStroke class one more method which takes a String as an argument. So we will be tempted to use KeyStroke.getKeyStroke("ctrl pressed x"). And the truth is that, even this wont work!!!

The reason is that, we have to give a capital letter for the character and not small letter. So, if you give KeyStroke.getKeyStroke ("ctrl pressed X") will only the accelerator work and there is no documentation which says this, that we have to use capital letter in the key stroke object if we wish to set it as accelerator for a menu item.

So, if you wish to develop an application and then set the accelerator for menu items, and if that does not work, make sure the KeyStroke object that is set has the character "upper cased" and it has "pressed" instead of "typed". If you have had similar kind of technical difficulties and found a way to solve it, you can very well share it here.

P.S.: I am really sorry if this blog has been very confusing and not understandable. [I am editing this blog after some months because, I find that this is the blog which is most viewed, most of the viewers from Google searching about this method. If you find this blog is useful (or useless), please comment about it and let me know how can I improve this or my future blogs]

Wednesday, September 19, 2007

Stock Market!

[Disclaimer - I am not even close to novice regarding stock markets and I do not even have a Demat account yet. Yet, I want to talk about market as much as I know of.]

Stock Market seems to be the future for everyone. Everyone including government employees, house wifes, college students, software engineers, etc. are now in to it. It intrigued me and I learned some thing (which is very very less) about the market and it was intimidating to know how many have lost their life in this game. Game, yes, we can say Stock Market as a game, which is controlled by some one or some thing which in invisible and constantly watching us, for it is the case for almost everyone that, the moment anyone sells a company's stock, the price increases and the moment anyone buys the stock, the price decreases.

The thing which confuses me is that, I have seen lively, no one will be ready to buy stocks of a company, for say, at a particular time, for Rs. X and after some minutes they will be very much ready to buy it for Rs. X+10 (or 20 or 30) and it is the same case for selling also in the negative meaning. Meaning, no one knows the exact price of what they are buying or what they are selling, why they are buying and why they are selling, they simply do as many number of people all over the country do. Do they know that the stock which they buy for 100 or 200 or 500 or 1000 worths only Rs. 10 or even less? Less people will only actually know this and play in Stock Market, but all others just do without even knowing what they are doing.

Some experts say that you have to watch the market constantly to be a millionaire and that expert will not be rich or may even be poor, struggling to get money to invest in it. It is what I have learnt that, knowledge alone will do no good, for you will have to have a lot of money and luck. Luck is needed to help the price increase for the stocks you buy, as there is no way one can predict what the price will be in the market the next minute, otherwise, everyone will earn a lot of money. Money alone can make you earn more money and all other factors like knowledge about the company (whose stock you are going to buy), Predictability, Luck, etc. are secondary things only.

If you want to enter into the share market and if you have a little money, you will surely lose it and if you have money, you will still lose it and if you have more money, you could earn money and if you have a lot of money, you will surely make a lot from it. It is like, grabbing the money from those who have less and give it to those who have more. More over, a statistics says that, 95% of those who do intra-day share meets loss and those who wait (obviously having more money) could gain. Gain more knowledge about share markets before investing much. Much I have told now and you could think all I have said is an utter more bull-shit or some other shit, but these are the things I know with my little knowledge and I may be totally wrong. Wrong or right, I have told my view, and now is your time to share your views...

[P.S.: I have tried much to make every sentence's first word to be the previous sentence's last word. Word used might have given wrong meaning but I just wanted trying. Trying is not a bad thing isn't it?]

Sunday, August 26, 2007

Maturity - Different levels

[Disclaimer: This does not mean that I am very mature to classify and discuss about maturity. This blog is about, maturity in my opinion.]

What I mean by maturity is how one behaves in situations or how one handles situations. There could be various aspects of maturity and various form for it also. Different forms of maturity is like, how one behaves in happy moments, sad moments, frustrated moments, angry moments, etc. What I mean by different levels of maturity is, when they show the matured behavior.

For example, when taking a happy moments, showing maturity will mean not to make promises beyond our capacity, when talking about victorious moments, showing maturity will mean being modest, in angry moments, being mature will mean the ability to keep our mouth shut, etc. I would like the tell my opinion about the last case, different level of maturity in case of anger.

Being mature enough, in the first case, will avoid most of the situation to become angry. If we fail in that, being somewhat mature will stop from making the problem bigger. If again we fail in that, and if sudden increase in the maturity happens, we should be ready to apologize for shouting\hitting\sulking\etc.ing. And if we fail to show maturity in all the previous incidence, there is yet one chance to show the maturity. Accepting whatever happened because of the showing anger and appreciating the consequence of bad temper and not showing any more vengeance.

Failing all, will mean a miserable consequence corresponding to the level of the problem and the level of your contribution, being restless, disappointed, worried, still-more-anger, etc. Why I think like this is, I have shown maturity in all the levels in some cases and in most of the cases, I have failed to show maturity in any levels, and in all such situation I was, anyone would be, restless or frustrated.

There is yet another form for maturity, which is to show maturity in humiliating or embarrassing situations. This would be a bit funny to discuss and I would like to spare a separate blog for that case. Feel free to spare your comments.

Wednesday, August 08, 2007

Exaggeration a tool for humor and horror.

I use to get an unintended grin when I think of Exaggeration. Everyone in the world tend to exaggerate things when they convey or discuss anything, or propagate a gossip, etc. The amount of exaggeration is what that differs and differentiate individual's reliability. I recently heard a very good joke about exaggeration. It is: A mother says to her daughter, "I would have told you a million times not to exaggerate things when you talk".

I remember the word *slapstick* which means the use of exaggerated violence that is intended for humor where if there is no exaggeration, then it will mean a vigorous violence. This is the technique used by many comedians, especially Vadivelu. Even when friends get together and talk about a victim, one among them who will be the target of the speech and will be made fun of, there will be a lot of exaggeration to add masala of the topic they talk about him/her.

On the other hand, when someone is told about someone about something negative, exaggeration will prove to be a drastic tool. A little amount of exaggeration is enough to make adverse effect. Since we always see a lot of people whose habit is to exaggerate even when talking about something which is not for fun, and how we loathe about that and how we always hesitate to believe whatever they say, I always try not to exaggerate things when I talk about serious things. And of course, when I fail and when I exaggerate, I will later despise myself for that, and of course it continues till now.

So, let me try and stop completely to exaggerate; and when I mean stopping, I mean that the exaggerating factor be very very less about +\- 0.0001%, as this is the percentage which will happen without our intention, because of the excitement. What more, let me finish with another PJ (poor joke) which I heard when I was a small kid. 'Three friends are taking and one of them says "I had seen a snake of this much length" and he stretches out his one arm to show the measure. Suddenly the second one says "I had seen a snake of thisss much length" and he stretches both of his arms as wide as possible. Now the third one, slaps hard on the second one's face and says "Now, how can I say a size which is more than yours?, You should have used one and a half arms so that I could have used two arms".'

I could overhear some of you saying, "But you told that you are going to say a PJ?" :D Feel free to comment or tell about your views\experiences.

Wednesday, July 25, 2007

Harry Potter and the Prisoner of Azkaban

If you have not read my previous blog about HP, please click here.

Harry is excited to go his school, Hogwards, for the third year, after the adventures he has done in the second year. Harry is now every student's favorite, as what he has done has made the school Headmaster, Professor Dumbledore, to give a school treat of canceling all the exams! Before he is going to start he finds out that a prisoner who is heavily armed has escaped a prison and that everyone in the Muggle world is warned about him.

Disgusting things happen that Harry leaves his aunt's house and soon he finds out that the prisoner who had escaped is not a Muggle but is a very powerful wizard and an expert in dark magic, who had killed 12 people in a single curse. And also this prisoner is the only one who had ever escaped from the Prison of Azkaban, a prison for witches and wizards heavily guarded by Dementors: a magical creature which sucks the happiness out of a person and whose kiss will suck the soul out of the body.

How could anyone escape from such a prison? And in the history, the prisoner is the only one who had ever escaped. And to his horror, Harry finds out that, the prisoner has escaped to kill Harry! Harry is not only chased by this killer, but also by a death omen; a gigantic dog. Prophecy says that Harry has to encounter the Grim (the gigantic dog) and that he is going to die soon! The idea of Hogwards being the safest place also becomes false as the prisoner has already entered into the school and Dementors are guarding the school.

Harry becomes Dementors most favorite target as Dementors easily attack those who have a tragic memory. Harry almost dies in many instances due to the attack of the Dementors and narrowly saved. How Harry is going to tackle the Dementors?, how he is gong to face the Grim?, how he is going to escape from the prisoner? is the rest of the story. An excellent novel with an excellent twist. The story goes slowly in the start and at the end it goes in light's speed. If you have not read this book yet, I strongly recommend you to read it (after reading I and II part) and share your comments.

Saturday, July 21, 2007

Harry Potter and the Chamber of Secrets!

Now Harry is in the second year, of seven years at Hogwards, The school for Wizards and Witches, after the greatest adventure he had done in his first year, encountering Lord Voldemort face to face. Lord Voldemort is the greatest Wizard of Dark Magic, so powerful and dangerous that no one could even address him by his name, addressing him as *You Know Who* or *He Who Must Not Be Named* [and thank God he is not He Who Must Not Be Typed :)]. So, after conquering, or we can say escaping from, Lord Voldemort for the second time, Harry becomes even more famous in Hogwards.

But in the second year there are more dangers and threats awaiting him. Harry faces much more trouble even before going to Hogwards. But soon, a doubt arises to the whole school: "Whether the threat is for Harry or the threat is by Harry". The Chamber of Secret is opened again, which by myth has a dangerous monster locked in it which will kill the enemies of the heir of Slytherin; one of the founder of Hogwards, a very powerful Wizard who dislikes Muggles [non-magic creatures, humans :)]. Strangely those who disturb, or seem to disturb Harry are petrified one by one.

At some point of time, Harry uncovers some truths that make himself to doubt whether he is the heir. All the student fear Harry, talk bad about him, sing bad about him, loathe him. Harry after some efforts find out that, a very trusted staff is the one who has opened the chamber last time! Before he could do any further investigation, his close friend is also petrified. And one more! What happens and what is going to happen then becomes a million dollar question.

How Harry is going to overcome this and how he is going to face the deadly monster that is in the Chamber Of Secret is the rest of the story. A very unpredictable and extremely interesting adventurous story is this. Success of Harry Potter books is that it has many aspects like, sentiment, thrill, horror, who-done-it puzzle, friendship, fight of good and evil, school time adventure, etc. A must read novel! If you find many terms not understandable, it is time you start to read the HP novels. So, read this novel if not already read and comment about this book after you reading it.

Saturday, July 14, 2007

Not a Penny {More/Less} - Jeffrey Archer's First Novel

"Not a Penny More Not a Penny Less" is the first novel from Jeffrey Archer, one of the greatest story tellers of this modern time. This story is about a criminal who uses share market to cheat people and earn millions of dollars. In one of such occasions he messes up with a great mathematician, Stephan who invest about $250, 000 and becomes penniless. Not like other people who regret for losing, he wants to take revenge on the criminal, Harvey. Stephan later finds that there are three more people, who do not know each other mutually, who have invested a great amount of money.

With little investigation he finds the other three people to be an art dealer Jean-Pierre, a doctor Robin and a land lord, James who wishes to become an actor. Some how he manages to co-ordinate a meeting with all the three and they four decides to cheat Harvey and get all their money back, not a penny more; not a penny less. Though this is some what dramatic, to have mutually unknown persons meet up and agree to take revenge on an expert in swindling, it is acceptable; after all, anyone could be brain washed.

Everyone except James comes with a plan that could get some money from Harvey; when James meets a stunningly gorgeous a-typical-most-beautiful-girl-in-novels and falls in love with her at the first sight. When everyone dies to device a plan to get their money back, James devices plans to attract her and date with her, and like everyone else, he succeeds in his mission.

All the four of this team take part in others' plan and they somehow manage to get 3/4 of their total money loss; only missing the James part of contributing his 1/4 of the money. And James becomes the hero of the novel by an extra-ordinary twist in the end and he manages to get his team his contribution. There are more good news in the ends and the novel ends with a happy ending.

A good novel which is worth of the time spent in reading that. Though all the three plans are somewhat guessable, the twists and turns that happens when the plans are executed and how they fail because of lack of contingency plans and how they recover quickly from that are interesting. So, if possible read this novel and share your comments.

Saturday, June 23, 2007

Idea Aiyasamy - How to blog wihtout going to blogger.com?

I am proud to introduce one more character *Idea Aiyasamy* (to accompany *Karuththu Kandasamy* and *Mokka Muththusamy*) to you all (I could hear some of you saying, "Who asked you to? :) ); wearing this mask I will give you some tips and tricks (trying very hard not to be cliched ideas). First of all the ideas, I wanted to talk about blogging which makes this idea applicable only for bloggers; and I am sorry about this.

Yes, we do not need to go to blogger.com, log-in, click the *New Post* and then again click the *Publish* button. You can simply send a mail and that mail will become a blog (with subject as the heading). Simple isn't it? But before that you have to configure your account settings, a one time job. Click on the *Settings* link of your blog and then click the *Email* link under it. There you could see two rows. First row is to let you get a mail if anything is published in your blog and the next row, you will be asked to configure *Mail-to-Blogger Address* which will have your name as un-editable field and a text field you have to fill in. Fill in the text field with any word to make it a email address for example amudhan.movies@blogger.com like this. And also enable the Publish option by checking the check-box.

You are done! From then onwards, you could just send an email to that configured mail address (from any of your email account) and it will become a blog!!! So, if you are in office and have some free time, you could simply type the content as a email and send it to the configured mail id, thus publishing the blog. You do not have to reveal anyone that you are blogging in the office (and I strongly advice you not to blog in office time when you have work :) ).

PS:

I could hear someone doubting (sarcastically) that, *but you said you will try hard not to discuss cliched ideas? did you lie about that?*

I also could hear some of you saying that the conventional way of blogging is far better than this stupid idea :). But this one is particularly helpful when you do not want to be noticed, while blogging.

Do not reveal to anyone, the mail id you configured as any one could simply send a mail and publich blog in your website. (And do not try to send any mail to the mail id I used for example if you do not want to get bounced-mail ;) )

Karuththu Kandasamy - Reject any proposal that give you short time to think over. (life lesson)

I always learn things by experience; and I have heard of a saying "Experience is a costly school; only fools will learn from it" (but here trying to be optimistic, I could take that I am rich guy learning in a costly school :) ). I have a lot of brilliant people who could advice me very well, but I just do not understand till I experience it. This is one of the greatest advices I have had from my father and that I now understood after experiencing (I used experience a lot of times, I guess) it. Mark my words, *Reject any proposal that gives you a very limited time to think about it*. This is a life lesson; following which you could save a lot of your life (by reducing your BP, tension, etc). When I say something, I want to give you examples only then we could understand the karuththu well.


Here goes the example: One day I got a mail from one of my colleagues at about 11 AM that LIC had announced a very precious scheme and that it is going to be over by 3 PM in the same day and that 1000s of applications are already in queue and that getting that policy will be very tough and that it is very beneficiary, and that bla bla bla. I was so much intrigued by that and called up my father immediately and told him about that. He said coolly that it is all marketing tricks and that I had to wait and think before applying for it. I did not listen to him; got money from my friends (I did not even have money by that time) and got the policy, feeling very proud of my decision.


The next day, the same representative called me up and asked, 'do you have any friends you could refer?'. I was shocked and asked her whether the scheme is still available. She said plainly that the scheme has been extended for one week. Later after some weeks she again asked me to refer any friends saying that the scheme is extended for one month!!! What the heck? I thought and I felt myself as a jackass (and as a matter of fact the scheme is still available after an year :( ). Thank God it is an LIC policy; anyhow I will need it. What if, if that has happened for something very risky? So, what I want to say is that, *unless and otherwise you are given sufficient time to think of any proposal, just ignore it, how much ever it looks precious, unless and otherwise you will any how get that even without the scheme*. Just share your opinions and karuththus about this karuththu; also you could write an example of your experience.

Mokka Muthusamy: Harry Potter and the Philosopher's Stone

I am just a new born baby in the Harry Potter world, new friend to Harry, yet-another-guy who longs to enter 9 3/4 platform, who longs to have a broomstick (that could fly, of course), who longs to watch the Quidditch match, who longs to play wizard chess, etc. I hope most of you (again, as though 100s of people are reading this), would have read Harry Potter many times and there would be 1000s of bloggers blogging about this and 100s of Orkut communities etc. But that is not going to stop me from saying what I want to say. First of all, I would like to confess something. I am a conservative sometimes and I do not want to adopt new things; for example, listening to new movie songs, etc. Like this, I had refrained myself from reading HP (Harry Potter) for a long time thinking that everyone is just creating scenes by reading\talking\blogging\etc.ing about HP.

But for a very very close friend of mine who presented me all the six volumes of HP as my birthday gift, I had to start to read HP. The moment I started reading that book, the moment I started liking it. First I thought that having seen the movie, it wouldn't be nice to read that; but that is not true. Reading that book is much more fun and thrill than seeing the movie (but thank God, I have not seen the 2nd and 3rd part of the movies). If you are like me, thinking that reading the book would not be fun after watching the movie, just stop thinking like that and go ahead and read that book. Now that I have finished the first part, in a very less time, in the period I felt ill, in the period I had the most horrible personal problems. Being engrossed in Hogwards School has kept me reading and that relieved me from my personal worries.

After reading that book, I felt very thankful to my friend who had introduced his friend HP to me, and hope that you will also be to me, if this blog made you to read that book. I want to write a lot about this (and I will), how to read HP (similar to the blog Why To Watch Movies) and what will make you like HP (in case you have not read that already). So, what I want to convey from this blog is that, do not be a conservative and refrain yourself from reading it, and do not think that previous knowledge through the movie will lessen the fun of reading and more importantly do not think that HP is for kids (not in the sense that it also has some adult contents ;) but) in the sense that everyone will like it. Read that book (I would prefer to say 'study the book' instead) and share your comments whether, this blog is right or wrong.