Ye Meri Life Hai - Chirag Mehta

Be Good & Do Good!

Month: September 2009 (page 1 of 2)

Difference and similarity between Wii, XBOX & PS ?


Wii XBox Play Station

The Sony PlayStation 3 and Nintendo Wii both jumped into the game console ring to compete against Microsoft’s Xbox 360. Who is going to win?

Everyone’s watching to see how this battle plays out, because each company is pursuing a very different strategy. Sony and Microsoft are gunning for pure performance systems, while Nintendo is shooting at fun, playable games that rely more on its unique controllers than impressive graphics hardware.

The consoles’ prices follow the features and product strategy of each company:

Sony PlayStation 3
Sony’s PS3 is the most expensive at $500-600, because it includes a standard hard drive, a high definition Blu-ray optical drive, HD video output, Bluetooth wireless controllers, and–in the premium version–WiFi wireless networking.

Sony is setting up the PS3 as a PC alternative. Sony originally announced plans to ship the PS3 with Linux pre-installed, but currently user installation of “another operating system” is only a boot option. The PS3 is also the new HD core of Sony’s modern take on the stereo system, offering 5.1 Dolby Digital Surround and true 1080p high definition video playback from prerecorded Blu-ray movies.

Microsoft Xbox 360
Introduced last winter, Microsoft’s Xbox 360 is $300-400, uses a standard DVD optical drive, and only includes a hard drive and wireless game controller in its premium version. Microsoft recently updated the 360 to provide support for full HD, 1080p video output to match the PS3.

Rather than positioning the Xbox 360 as a standalone PC alternative, Microsoft pairs it with its plans for Windows Media Center, allowing the 360 to be used as a media extender to stream music and movies from a central Media Center PC.

Microsoft has plans to offer HD movie playback both with an optional HD-DVD player in an external box, and over the web through its online Xbox Live video store.

However, the Xbox 360’s optional, external HD-DVD player is $200, pushing the 360 up to the same price as the PS3. Further, the $300 core Xbox 360 systems can’t use Microsoft’s online video store because they don’t have the required hard drive to save downloaded movies.

Nintendo Wii
The Wii is the least expensive of the three at $250, and includes both Bluetooth for wireless controllers and a DVD drive, but will not be able to play DVD movies. It also lacks a hard drive. Instead, the Wii focuses on physically involving games using the wireless Wii Remote paired with the accessory Nunchuk controller.

The Wii Remote uses accelerometers to sense how players swing, point, and tilt the controller, encouraging game titles to incorporate activity. The Wii will also wirelessly connect to Nintendo’s DS portable game system, using its microphone and touchscreen as inputs for Wii games. While the Wii has no movie store, Nintendo has an online store that sells classic games from the Nintendo 64 and other previous game consoles.

The Last Generation
So which console is going to assume the lead, or will there be a tie? A half decade ago, many analysts projected a close race between the Sony’s PlayStation 2, Microsoft’s original Xbox, and Nintendo’s GameCube, but their prediction turned out to be wrong: Sony simply blew away the competition with its PS2.

This time around however, a number of factors have changed. For example, while Nintendo’s 2001 GameCube was also the cheapest console, its sales were hurt by a game lineup that mainly targeted the youth market rather than teens and adults, something Nintendo has attempted to address.

Here’s a quick look at the lessons learned in the last generation of consoles, how Microsoft got involved in console gaming, what resulted then, and what factors will determine how things work out this time.

Sources: http://www.roughlydrafted.com/RD/Q4.06/745E215D-460A-4393-96E6-56FD13A883A2.html

Really innovative international literacy day campaign

Really innovative international literacy day campaign

Google’s Chrome now inside Internet Explorer

Hmmm, this is interesting. Google had spotty luck trying to push its Chrome browser to users, but now it’s come out with Google Chrome Frame to embed Chrome’s functionality inside Internet Explorer.

The idea of embedding one browser’s functionality inside another browser isn’t new. Firefox users have IE Tab, for example, to run sites that absolutely require IE to run. With IE Tab the user can specify a list of sites and/or file extensions that should always be opened in an IE tab. That approach is problematic at times because the user isn’t always the best person to determine whether the site works correctly with a particular browser. It may take trial and error on the user’s part to determine that the site is breaking because it requires IE.

Google Chrome Frame lets web page developers specify that their page would really prefer to be rendered in Chrome rather than IE. Once the plugin is installed, the author of a web page can specify that IE should use the Chrome Frame plugin by putting a single tag into the top of the document:

<meta http-equiv=”X-UA-Compatible” content=”chrome=1″/>

If some other browser is in use, or if the user has IE with the plugin not installed, the page renders just like it normally would. If, however, the Chrome Frame plugin is installed in IE, the page is rendered using the Google Chrome engine even though it’s still within the IE application.

This sort of browser-in-browser solution could be great for developers that want to support IE6 users without having to deal with IE6 quirks. They’d just add the tag to their site and tell IE6 users that they’d be supported only with Google Chrome Frame. (IE7 and IE8 aren’t as problematic, so most developers can build a site that supports them with or without Chrome Frame.) The biggest problem I see is that many IE6 users are dealing with locked-down systems and won’t have the authority or ability to add the plugin. If they could do that, they’d also be able to upgrade their browser!

Read more on Google Chrome Frame @ Google Chrome

Ack : Dave Methvin

Life is too short and friends are too few

HOW POOR WE ARE?

One day, the father of a very wealthy family took his son on a trip to the country with the express purpose of showing him how poor people live. They spent a couple of days and nights on the farm of what would be considered a very poor family.
On their return from their trip, the father asked his son,
‘How was the trip?’
‘It was great, Dad.’
‘Did you see how poor people live?’ the father asked.
‘Oh yeah,’ said the son.
‘So, tell me, what did you learn from the trip?’ asked the father

The son answered:
‘I saw that we have one dog and they had four.
We have a pool that reaches to the middle of our garden and they have a creek that has no end.
We have imported lanterns in our garden and they have the stars at night.
Our patio reaches to the front yard and they have the whole horizon.
We have a small piece of land to live on and they have fields that go beyond our sight.
We have servants who serve us, but they serve others.
We buy our food, but they grow theirs.
We have walls around our property to protect us, they have friends to protect them.’
The boy’s father was speechless.

Then his son added, ‘Thanks Dad for showing me how poor we are.’

Isn’t perspective a wonderful thing?
Makes you wonder what would happen if we all gave thanks for everything we have, instead of worrying about what we don’t have.

Appreciate every single thing you have, especially your friends!

‘Life is too short and friends are too few.’

Online Shopping Coupon Codes

Really now a days people are turning for online shopping and even the providers are turning with great online discounts. You can find lot of coupon codes at following location ..

ebay India @ http://www.retailmenot.com/view/ebay.in
New Egg @ http://www.retailmenot.com/view/newegg.com
Dell @ http://www.retailmenot.com/view/dell.com
Best Buy @ http://www.retailmenot.com/view/bestbuy.com
HP @ http://www.retailmenot.com/view/shopping.hp.com

View coupon codes from many more online legends @ http://www.retailmenot.com

HTML : Non-breaking Hyphen

Is there such a thing as a non-breaking hyphen to prevent words like’e-mail’ and ‘e-commerce’ from breaking in two pieces at the end of a line?

Solution
I haven’t used it much, but placing the whole word between <nobr></nobr> tags should work……. It worked for me!

Apex – Update “non-setup” objects from a “setup” object like User

Dilemma

As this page of the Apex docs indicates, you can’t just make a User trigger that updates a Contact or an Account, because it’s forbidden to modify those “non-setup” objects from a “setup” object like User.

Solution

Fortunately there is a simple solution: the @future annotation.  The @future annotation allows you to create Apex that runs asynchronously at some point in the future (in my tests I’ve found that it runs immediately, or at least very soon after the trigger executes).  Methods that use @future are subject to different limits than normal trigger operations because @future methods don’t hold up the trigger (and therefore the entire user experience) while they’re working.  Therefore @future methods are often used to perform long-running web service callouts from triggers asynchronously.  However, they can also be handy for a case like ours, where we want to update an object that we’re not normally eligible to update.

Calling a method that has been marked as @future is just like calling any other static method.  Here’s my trigger, short and sweet:

trigger UpdateContactFromPortalUser on User (after update) {
	//We only want to run on the single item that the user edited
	if (Trigger.new.size()==1) {
		User u =  Trigger.new[0];
		//And only if it's a portal user
		if (u.ContactId!=null) {
		UpdateContactFromPortalUser.updateContacts(u.Id);
		}
	}
}

Let’s see how that works.  In the example given here, I just update a couple of fields from the user record: the name, the email address, and the title.

global class UpdateContactFromPortalUser {
    @future
    public static void updateContacts(String userId) {
    	User u = [select ContactId,Email,FirstName,LastName,Title
    				from User
    				where Id=:userId];

    	if (u!=null && u.ContactId!=null) {
	    	Contact c = new Contact(Id=u.ContactId);

			c.Email = u.Email;
			c.FirstName=u.FirstName;
			c.LastName=u.LastName;
			c.Title=u.Title;
			update c;
		}

Source :  http://blogs.salesforce.com/support/2009/01/index.html

Salesforce – Render visualforce page without Field Level Security

Scenario :
We are building a Visualforce page for creating a case. Now there are fields in case which are read only for all profiles except System Adminstrator. I need the user to enter the value for this field and so I created my page with a controller and not a standard controller. Also in my controller we have added the modifier as without sharing.

Now when we log in through another user, we still see the field as read only on the page. However from the controller we are able to insert value or update the field. It seems to me that the page is running in User mode following the user profile permissions and field level security while the controller is running in Sytem mode. Is this the intended behaviour or are we missing something

Following are few of the possible solutions….

Solution 1

It is an intented behaviour, If the fields rendered on the page is strongly binded (i.e Value = {!ObjectName.Fieldname}).
Why not create input/HTML fields and bind them using getter setter method (i.e you take input in a normal text field and bind it to the actual field in the controller). As these input Html fields are not binded to an object these fields will be editable regardless of profiles.

Solution 2

Create a Custom Object and assign permissions to this object to all profiles. Now render fields of that custom object, but in your controller don’t insert this custom object. Insert the actual records.
Use this custom object to generate the lookups and date pickers
The controller will be standard controller of this custom object with extensions.
So this object is used just to render fields ….

Solution 3

Make the fields read only at the page layout level and not at the profile level.

How to Lose a Guy in 10 Days

To help land in a big ad account, notorious player Ben (Dude Matthew McConaughey) makes a wager with his co-workers that he can get a woman to fall in love with him within 10 days. But he bets on the wrong girl — women’s composure magazine writer Andie (Cute Kate hudson).
It turns out she’s writing an article on how to dump a guy in 10 days — and is set on seeing her story through to completion.

Rating : 7/10

To help land in a big ad account, notorious player Ben (Dude Matthew McConaughey) makes a wager with his co-workers that he can get a woman to fall in love with him within 10 days. But he bets on the wrong girl — women’s composure magazine writer Andie (Cute Kate hudson).

It turns out she’s writing an article on how to dump a guy in 10 days — and is set on seeing her story through to completion.

It’s one time watch movie. It says loudly to guys that girls can knock anyone down in just 10 days. At the same time it also says that girls guys can knock you down anytime … lol …

Salesforce : Apex : Covert DateTime to Date

I look through the documentation and didn’t see a system method that converts a date time field to a date. There is one for formula fields but is there one for Apex?

Solution : Just create a date newInstance() and pass in just the year,month,day from the dateTime object.

Datetime dateTimetemp = System.now();

Date dateTemp = Date.newInstance(dateTimetemp.year(),dateTimetemp.month(),dateTimetemp.day());

Older posts