Tuesday, September 14, 2010

Asp.net website in hindi or other native language with simple steps

Dear all,
For Indian its great news that you can now create web site in your native language like Hindi, Marathi, Punjabi, Urdu, Tamil etc.
Kudos to Microsoft for introducing “Microsoft Indic Language” with help of this we can easily create web site in any language without doing much efforts.
So here we go with the sample and things to remember with simple step



Step 1:- Add following line in your html page
< input type=”hidden” id=”MicrosoftILITWebEmbedInfo” attachMode=”optout” value=”" />



Remember here: I am using hindi here that’s why i used hindi.js you can use your own choice.
Step 2:- Add new attribute with each input control which is “MicrosoftILITWebAttach” as shown in below.
< asp:TextBox ID=”txtPost” runat=”server” MicrosoftILITWebAttach=”true” >

Step 3:- If you want to store this value in database the just remember all the field which contain string data type should be “NVARCHAR”
Otherwise your searching will not work and all the data will be change to question mark instead of actual data.

Step 4:- for searching in database hindi text or text which you insert you have to use following syntax

SELECT * FROM tblPost where postName =N’प्रोफेसर’
So Enjoy

Thanks
Rajat
Toy Story 3 (Four-Disc Blu-ray/DVD Combo + Digital Copy)