Tuesday, November 17, 2009

5005: Unknown error optimizing byte code

Recently while working with a large AIR project i ran into this problem. Every now and then all of a sudden, I will start getting this error while compiling the project :
"5005: Unknown error optimizing byte code"

Now as if MS was not enough with their cryptic messages everytime there was a problem with Windows, Adobe also came up with this gem of concept :x .

Friday, March 20, 2009

Develop in JDK1.5, deploy on 1.4 :-)


You must be wondering why the hell would I want to do that and why not just develop in 1.4? Well, for one, may be you want to use the new features of JDK1.5 but some of the customer for some reason still stuck with JDK1.4 or like in my case, due to some stupidity on our client's part that he bought license to an older version of the application server (yes, it was Websphere) which does not support 1.5 and rest of the stupidity on our part that we just assumed that the application server will be supporting 1.5.



We kept on developing the application and giving demos to the client on our server and when it came to deployment only then we realized that we are in one big soup. And as always Google to the rescue, which helped me find an open source solution Retroweaver  which operates by transforming Java class files compiled by a 1.5 compiler into version 1.4 class files which can then be run on any 1.4 virtual machine.



For more details follow the link. Hope this helps Batting Eyelashes

Wednesday, January 28, 2009

Problem Installing Windows CE 6 Platform Builder SP1

While installing Windows CE 6 Platform Builder, I ran into a problem. When I tried to install the SP1, it gave an error saying that I need to have CS 2005, VS 2005 SP1 and Windows CE6 installed. This seemed kind of funny as I had already all three installed. Googling led me to a thread where someone mentioned that installing Windows CE 6, breaks something in the VS 2005 SP1 and reinstalling SP1 should fix it. Tried that and after an agonizing 30 minutes, when I ran the PB SP1 again, no more error message.

Tuesday, January 13, 2009

Reset MySql root password


Well, it had been quite sometime since I used MySql and then for some demo I had to. But, the problem was that I had forgotten the password and googling for help told me that I am not the only stupid in this universe Embarassed. Well here is the solution to the problem:





  1. Stop your MySql service.




  2. Open and command window.




  3. cd to the MySql bin directory (if the MySql bin is not added to your path).




  4. Now run this command
    mysqld-nt.exe --skip-grant-tables &




  5. Now open another command window and if required again cd to the MySql bin window and run this command
    mysql -u root mysql




  6. In MySQL command line prompt run the following commands:
    UPDATE user SET password=PASSWORD("password1234") WHERE user="root";
    FLUSH PRIVILEGES;




  7. Yippe... the root password is reset to "password1234" and MySQL will now
    know the privileges and you'll be able to login with your new password.





 Of course this set of instruction is for Windows and MySQL 5. For Linux, I guess (am not sure, so please look around in the mysql bin directory for correct file name), the command in step 4 will change to "mysqld_safe --skip-grant-tables &" (based of googled results). Rest I believe should be same. In case someone I missed something or you have instruction for other OS/ mysql versions, let me know, will be happy to update it.



 

Center align site layout using CSS


Recently I began creating 100% CSS layouts, and faced a lot of problems in getting the content to be centered in both IE and FF. After lot of googling, the final working css is :


LiveCycle Form Designer quits on opening a dynamic form


A weird solution to a weird problem. My LiveCycle Designer was working fine and then all of a sudden, it started quitting the moment a dynamic form was opened. The error message was standard application crash one saying



"Adobe LiveCycle Designer ES has encountered a problem and needs to close. We are sorry for the inconvenience."



 Googling led to the Adobe forums and there found this solution - Delete the folder "Designer" residing in your User folder "Appplication Data\Adobe". Usually that should be "C:\Documents and Settings\YOUR USER NAME\Application Data\Adobe". Just delete the folder names "Designer" and when you start the LiveCycle Designer, it will be created again and this time there should be no problem opening a form. Apparently this may also be caused if you have SQL 2008 installed on your system. If thats is the problem in your case, follw this link



http://www.adobe.com/go/kb407823



 

Tomato Basil Risotto

Ingredients:




8 cup chicken broth
1/8 tsp. saffron threads
1/4 cup Olive oil
4 tbsp. butter (preferably unsalted)
1/4 cup chopped onion
3 cup choopped plum tomatoes
2 cup Arborio rice
1/4 cup. chopped fresh basil
1/2 cup grated Parmesan cheese
1/3 cup white wine
1/2 tsp. (or to taste) pepper (preferably freshly ground)
Salt to taste




Directions:



In a medium saucepan, bring th stock to a simmer and crumble in the saffron threads. Maintain simmer over low heat.



In a large thick base saucepan, heat the oil and 2 tbsp. butter over medium heat. Add the onion and cook until the onion is translucent, about 2 minutes. Add the rice and stir for about 2 minutes until coated with oil. Add tomato and cook for another 2 minutes, stirring constantly. Add the wine and cook, stirring, until it evaporates.




Add 1/2 cup of the stock and cook, stirring constantly, until the rice has absorbed most of the liquid. Gradually add stock, 1/2 c. at a time, cook, stirring constantly, until the rice is almost tender but still slightly crunchy, about 20-25 minutes.

Add the cheese and season with salt and pepper. Cook, stirring and adding stock as necessary, 1/4 cup at a time, until the rice is tender but still firm with a creamy sauce, about 5-6 minutes longer. Stir in remaining 2 tbsp. butter, chopped basil, and remaining ingredients. Serve hot.