globalizationhttp://forums.asp.net/t/1512319.aspx/1?globalizationMon, 11 Jan 2010 07:22:11 -050015123193607156http://forums.asp.net/p/1512319/3607156.aspx/1?globalizationglobalization &lt;div&gt; <p>,when i&nbsp;am click the the arabic button instead on one&nbsp;click&nbsp;i have to take two cliks,i dono y</p> <p>then i&nbsp;am clicking arabic button the page is getting converted into arabic but when i am clicking the next hyperlink dat pages is also converted into&nbsp;arabic n when i am trying to clike the previous page or the next hyperlink,the page is loosing its control and comming back into&nbsp;english,so anyone solve it&nbsp;i am waitin for the reply,</p> <p>i dosent understand y&nbsp;i have to click the button twice to change the page in to arabic&nbsp;or english&nbsp;</p> <span></span>&lt;/div&gt; &lt;div&gt;muhammad imran&lt;/div&gt; 2010-01-09T07:16:46-05:003607624http://forums.asp.net/p/1512319/3607624.aspx/1?Re+globalizationRe: globalization <p>If you set the globalization in button click event handler, it will be applied in the next postback only. After clicking the button first time, refresh the page agian will load the page in the desired lanugage. To avoid this you need to set the language setting in the&nbsp; </p> <pre id="pre9" lang="cs" style="margin-top:0pt">InitializeCulture() method of the page class. refer the url for more <br><br><br></pre> <p><a href="http://www.codeproject.com/KB/aspnet/localizationByVivekTakur.aspx">http://www.codeproject.com/KB/aspnet/localizationByVivekTakur.aspx</a><br> </p> 2010-01-09T15:31:21-05:003609631http://forums.asp.net/p/1512319/3609631.aspx/1?Re+globalizationRe: globalization <p>hello,as u gave the site details&nbsp;i got an clear idea n i am thanx ful for it,n can u just let me know wheter where i&nbsp;have to writhe the initialize cultre()in my application as i am pasting the masterpage&nbsp;code&nbsp;just have a look in it&nbsp; n let me inform about it&nbsp;,this is my base calss code</p> <p>Imports System.Data<br> Imports System.Configuration<br> Imports System.Web<br> Imports System.Web.Security<br> Imports System.Web.UI<br> Imports System.Web.UI.WebControls<br> Imports System.Web.UI.WebControls.WebParts<br> Imports System.Web.UI.HtmlControls<br> Imports System.Threading<br> Imports System.Globalization<br> Imports Microsoft.VisualBasic<br> Imports System</p> <p><br> Public Class BasePage<br> &nbsp;&nbsp;&nbsp; Inherits Page</p> <p><br> &nbsp;&nbsp; </p> <p>&nbsp;&nbsp;&nbsp; Public Sub Arabic()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; SetCulture(&quot;ar-SA&quot;, &quot;ar-SA&quot;)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; If Session(&quot;MyUICulture&quot;) IsNot Nothing AndAlso Session(&quot;MyCulture&quot;) IsNot Nothing Then<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentUICulture = DirectCast(Session(&quot;MyUICulture&quot;), CultureInfo)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentCulture = DirectCast(Session(&quot;MyCulture&quot;), CultureInfo)</p> <p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; End If<br> &nbsp;&nbsp;&nbsp; End Sub<br> &nbsp;&nbsp;&nbsp; Public Sub Engilsh()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; SetCulture(&quot;en-US&quot;, &quot;en-US&quot;)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; If Session(&quot;MyUICulture&quot;) IsNot Nothing AndAlso Session(&quot;MyCulture&quot;) IsNot Nothing Then<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentUICulture = DirectCast(Session(&quot;MyUICulture&quot;), CultureInfo)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentCulture = DirectCast(Session(&quot;MyCulture&quot;), CultureInfo)</p> <p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; End If<br> &nbsp;&nbsp;&nbsp; End Sub</p> <p>&nbsp;</p> <p><br> &nbsp;&nbsp;&nbsp; Protected Sub SetCulture(ByVal name As String, ByVal locale As String)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Try</p> <p><br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentUICulture = New CultureInfo(name)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentCulture = New CultureInfo(locale)</p> <p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;MyUICulture&quot;) = Thread.CurrentThread.CurrentUICulture<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;MyCulture&quot;) = Thread.CurrentThread.CurrentCulture<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Catch ex As Exception<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; MsgBox(ex.ToString())<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; End Try<br> &nbsp;&nbsp;&nbsp; End Sub<br> &nbsp;&nbsp;&nbsp; <br> &nbsp;&nbsp; <br> &nbsp;&nbsp;&nbsp; <br> &nbsp;&nbsp;&nbsp; Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; If Session(&quot;MyUICulture&quot;) IsNot Nothing AndAlso Session(&quot;MyCulture&quot;) IsNot Nothing Then<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentUICulture = DirectCast(Session(&quot;MyUICulture&quot;), CultureInfo)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentCulture = DirectCast(Session(&quot;MyCulture&quot;), CultureInfo)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; End If<br> &nbsp;&nbsp;&nbsp; End Sub</p> <p><br> End Class</p> <p>&nbsp;and this is my master.vb code</p> <p>Imports System.Data<br> Imports System<br> Imports System.Collections<br> Imports System.Configuration</p> <p>Imports System.Linq<br> Imports System.Web<br> Imports System.Web.Security<br> Imports System.Web.UI<br> Imports System.Web.UI.HtmlControls<br> Imports System.Web.UI.WebControls<br> Imports System.Web.UI.WebControls.WebParts<br> Imports System.Xml.Linq</p> <p>Imports System.Threading<br> Imports System.Globalization<br> Imports System.Resources<br> Partial Class MasterPage<br> &nbsp;&nbsp;&nbsp; Inherits System.Web.UI.MasterPage</p> <p>&nbsp;&nbsp;&nbsp; Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; If Not IsPostBack Then<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; English()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;language&quot;) = &quot;English&quot;<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;PageDir&quot;) = &quot;ltr&quot;<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Response.Write(Session(&quot;language&quot;).ToString())<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; End If</p> <p>&nbsp;&nbsp;&nbsp; End Sub</p> <p>&nbsp;&nbsp;&nbsp; Protected Sub BtnArabic_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles BtnArabic.Click<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Arabic()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;language&quot;) = &quot;Arabic&quot;<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;PageDir&quot;) = &quot;rtl&quot;<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Response.Write(Session(&quot;language&quot;).ToString())<br> &nbsp;&nbsp;&nbsp; End Sub</p> <p>&nbsp;&nbsp;&nbsp; Protected Sub BtnEnglish_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles BtnEnglish.Click<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; English()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;language&quot;) = &quot;English&quot;<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;PageDir&quot;) = &quot;ltr&quot;<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Response.Write(Session(&quot;language&quot;).ToString())<br> &nbsp;&nbsp;&nbsp; End Sub<br> &nbsp;&nbsp;&nbsp; Private Sub English()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Dim obj As New BasePage()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; obj.Engilsh()</p> <p>&nbsp;&nbsp;&nbsp; End Sub<br> &nbsp;&nbsp;&nbsp; Private Sub Arabic()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Dim obj As New BasePage()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; obj.Arabic()</p> <p>&nbsp;&nbsp;&nbsp; End Sub</p> <p>End Class</p> <p>&nbsp;</p> 2010-01-11T07:21:16-05:003609633http://forums.asp.net/p/1512319/3609633.aspx/1?Re+globalizationRe: globalization <p>hello,as u gave the site details&nbsp;i got an clear idea n i am thanx ful for it,n can u just let me know wheter where i&nbsp;have to writhe the initialize cultre()in my application as i am pasting the masterpage&nbsp;code&nbsp;just have a look in it&nbsp; n let me inform about it&nbsp;,this is my base calss code</p> <p>Imports System.Data<br> Imports System.Configuration<br> Imports System.Web<br> Imports System.Web.Security<br> Imports System.Web.UI<br> Imports System.Web.UI.WebControls<br> Imports System.Web.UI.WebControls.WebParts<br> Imports System.Web.UI.HtmlControls<br> Imports System.Threading<br> Imports System.Globalization<br> Imports Microsoft.VisualBasic<br> Imports System</p> <p><br> Public Class BasePage<br> &nbsp;&nbsp;&nbsp; Inherits Page</p> <p><br> &nbsp;&nbsp; </p> <p>&nbsp;&nbsp;&nbsp; Public Sub Arabic()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; SetCulture(&quot;ar-SA&quot;, &quot;ar-SA&quot;)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; If Session(&quot;MyUICulture&quot;) IsNot Nothing AndAlso Session(&quot;MyCulture&quot;) IsNot Nothing Then<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentUICulture = DirectCast(Session(&quot;MyUICulture&quot;), CultureInfo)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentCulture = DirectCast(Session(&quot;MyCulture&quot;), CultureInfo)</p> <p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; End If<br> &nbsp;&nbsp;&nbsp; End Sub<br> &nbsp;&nbsp;&nbsp; Public Sub Engilsh()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; SetCulture(&quot;en-US&quot;, &quot;en-US&quot;)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; If Session(&quot;MyUICulture&quot;) IsNot Nothing AndAlso Session(&quot;MyCulture&quot;) IsNot Nothing Then<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentUICulture = DirectCast(Session(&quot;MyUICulture&quot;), CultureInfo)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentCulture = DirectCast(Session(&quot;MyCulture&quot;), CultureInfo)</p> <p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; End If<br> &nbsp;&nbsp;&nbsp; End Sub</p> <p>&nbsp;</p> <p><br> &nbsp;&nbsp;&nbsp; Protected Sub SetCulture(ByVal name As String, ByVal locale As String)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Try</p> <p><br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentUICulture = New CultureInfo(name)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentCulture = New CultureInfo(locale)</p> <p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;MyUICulture&quot;) = Thread.CurrentThread.CurrentUICulture<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;MyCulture&quot;) = Thread.CurrentThread.CurrentCulture<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Catch ex As Exception<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; MsgBox(ex.ToString())<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; End Try<br> &nbsp;&nbsp;&nbsp; End Sub<br> &nbsp;&nbsp;&nbsp; <br> &nbsp;&nbsp; <br> &nbsp;&nbsp;&nbsp; <br> &nbsp;&nbsp;&nbsp; Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; If Session(&quot;MyUICulture&quot;) IsNot Nothing AndAlso Session(&quot;MyCulture&quot;) IsNot Nothing Then<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentUICulture = DirectCast(Session(&quot;MyUICulture&quot;), CultureInfo)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentCulture = DirectCast(Session(&quot;MyCulture&quot;), CultureInfo)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; End If<br> &nbsp;&nbsp;&nbsp; End Sub</p> <p><br> End Class</p> <p>&nbsp;and this is my master.vb code</p> <p>Imports System.Data<br> Imports System<br> Imports System.Collections<br> Imports System.Configuration</p> <p>Imports System.Linq<br> Imports System.Web<br> Imports System.Web.Security<br> Imports System.Web.UI<br> Imports System.Web.UI.HtmlControls<br> Imports System.Web.UI.WebControls<br> Imports System.Web.UI.WebControls.WebParts<br> Imports System.Xml.Linq</p> <p>Imports System.Threading<br> Imports System.Globalization<br> Imports System.Resources<br> Partial Class MasterPage<br> &nbsp;&nbsp;&nbsp; Inherits System.Web.UI.MasterPage</p> <p>&nbsp;&nbsp;&nbsp; Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; If Not IsPostBack Then<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; English()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;language&quot;) = &quot;English&quot;<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;PageDir&quot;) = &quot;ltr&quot;<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Response.Write(Session(&quot;language&quot;).ToString())<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; End If</p> <p>&nbsp;&nbsp;&nbsp; End Sub</p> <p>&nbsp;&nbsp;&nbsp; Protected Sub BtnArabic_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles BtnArabic.Click<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Arabic()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;language&quot;) = &quot;Arabic&quot;<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;PageDir&quot;) = &quot;rtl&quot;<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Response.Write(Session(&quot;language&quot;).ToString())<br> &nbsp;&nbsp;&nbsp; End Sub</p> <p>&nbsp;&nbsp;&nbsp; Protected Sub BtnEnglish_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles BtnEnglish.Click<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; English()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;language&quot;) = &quot;English&quot;<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;PageDir&quot;) = &quot;ltr&quot;<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Response.Write(Session(&quot;language&quot;).ToString())<br> &nbsp;&nbsp;&nbsp; End Sub<br> &nbsp;&nbsp;&nbsp; Private Sub English()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Dim obj As New BasePage()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; obj.Engilsh()</p> <p>&nbsp;&nbsp;&nbsp; End Sub<br> &nbsp;&nbsp;&nbsp; Private Sub Arabic()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Dim obj As New BasePage()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; obj.Arabic()</p> <p>&nbsp;&nbsp;&nbsp; End Sub</p> <p>End Class</p> <p>&nbsp;wat </p> 2010-01-11T07:21:19-05:003609635http://forums.asp.net/p/1512319/3609635.aspx/1?Re+globalizationRe: globalization <p>hello,as u gave the site details&nbsp;i got an clear idea n i am thanx ful for it,n can u just let me know wheter where i&nbsp;have to writhe the initialize cultre()in my application as i am pasting the masterpage&nbsp;code&nbsp;just have a look in it&nbsp; n let me inform about it&nbsp;,this is my base calss code</p> <p>Imports System.Data<br> Imports System.Configuration<br> Imports System.Web<br> Imports System.Web.Security<br> Imports System.Web.UI<br> Imports System.Web.UI.WebControls<br> Imports System.Web.UI.WebControls.WebParts<br> Imports System.Web.UI.HtmlControls<br> Imports System.Threading<br> Imports System.Globalization<br> Imports Microsoft.VisualBasic<br> Imports System</p> <p><br> Public Class BasePage<br> &nbsp;&nbsp;&nbsp; Inherits Page</p> <p><br> &nbsp;&nbsp; </p> <p>&nbsp;&nbsp;&nbsp; Public Sub Arabic()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; SetCulture(&quot;ar-SA&quot;, &quot;ar-SA&quot;)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; If Session(&quot;MyUICulture&quot;) IsNot Nothing AndAlso Session(&quot;MyCulture&quot;) IsNot Nothing Then<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentUICulture = DirectCast(Session(&quot;MyUICulture&quot;), CultureInfo)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentCulture = DirectCast(Session(&quot;MyCulture&quot;), CultureInfo)</p> <p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; End If<br> &nbsp;&nbsp;&nbsp; End Sub<br> &nbsp;&nbsp;&nbsp; Public Sub Engilsh()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; SetCulture(&quot;en-US&quot;, &quot;en-US&quot;)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; If Session(&quot;MyUICulture&quot;) IsNot Nothing AndAlso Session(&quot;MyCulture&quot;) IsNot Nothing Then<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentUICulture = DirectCast(Session(&quot;MyUICulture&quot;), CultureInfo)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentCulture = DirectCast(Session(&quot;MyCulture&quot;), CultureInfo)</p> <p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; End If<br> &nbsp;&nbsp;&nbsp; End Sub</p> <p>&nbsp;</p> <p><br> &nbsp;&nbsp;&nbsp; Protected Sub SetCulture(ByVal name As String, ByVal locale As String)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Try</p> <p><br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentUICulture = New CultureInfo(name)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentCulture = New CultureInfo(locale)</p> <p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;MyUICulture&quot;) = Thread.CurrentThread.CurrentUICulture<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;MyCulture&quot;) = Thread.CurrentThread.CurrentCulture<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Catch ex As Exception<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; MsgBox(ex.ToString())<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; End Try<br> &nbsp;&nbsp;&nbsp; End Sub<br> &nbsp;&nbsp;&nbsp; <br> &nbsp;&nbsp; <br> &nbsp;&nbsp;&nbsp; <br> &nbsp;&nbsp;&nbsp; Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; If Session(&quot;MyUICulture&quot;) IsNot Nothing AndAlso Session(&quot;MyCulture&quot;) IsNot Nothing Then<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentUICulture = DirectCast(Session(&quot;MyUICulture&quot;), CultureInfo)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentCulture = DirectCast(Session(&quot;MyCulture&quot;), CultureInfo)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; End If<br> &nbsp;&nbsp;&nbsp; End Sub</p> <p><br> End Class</p> <p>&nbsp;and this is my master.vb code</p> <p>Imports System.Data<br> Imports System<br> Imports System.Collections<br> Imports System.Configuration</p> <p>Imports System.Linq<br> Imports System.Web<br> Imports System.Web.Security<br> Imports System.Web.UI<br> Imports System.Web.UI.HtmlControls<br> Imports System.Web.UI.WebControls<br> Imports System.Web.UI.WebControls.WebParts<br> Imports System.Xml.Linq</p> <p>Imports System.Threading<br> Imports System.Globalization<br> Imports System.Resources<br> Partial Class MasterPage<br> &nbsp;&nbsp;&nbsp; Inherits System.Web.UI.MasterPage</p> <p>&nbsp;&nbsp;&nbsp; Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; If Not IsPostBack Then<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; English()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;language&quot;) = &quot;English&quot;<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;PageDir&quot;) = &quot;ltr&quot;<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Response.Write(Session(&quot;language&quot;).ToString())<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; End If</p> <p>&nbsp;&nbsp;&nbsp; End Sub</p> <p>&nbsp;&nbsp;&nbsp; Protected Sub BtnArabic_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles BtnArabic.Click<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Arabic()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;language&quot;) = &quot;Arabic&quot;<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;PageDir&quot;) = &quot;rtl&quot;<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Response.Write(Session(&quot;language&quot;).ToString())<br> &nbsp;&nbsp;&nbsp; End Sub</p> <p>&nbsp;&nbsp;&nbsp; Protected Sub BtnEnglish_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles BtnEnglish.Click<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; English()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;language&quot;) = &quot;English&quot;<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;PageDir&quot;) = &quot;ltr&quot;<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Response.Write(Session(&quot;language&quot;).ToString())<br> &nbsp;&nbsp;&nbsp; End Sub<br> &nbsp;&nbsp;&nbsp; Private Sub English()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Dim obj As New BasePage()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; obj.Engilsh()</p> <p>&nbsp;&nbsp;&nbsp; End Sub<br> &nbsp;&nbsp;&nbsp; Private Sub Arabic()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Dim obj As New BasePage()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; obj.Arabic()</p> <p>&nbsp;&nbsp;&nbsp; End Sub</p> <p>End Class</p> <p>&nbsp;wat mistake i hav e</p> 2010-01-11T07:21:23-05:003609636http://forums.asp.net/p/1512319/3609636.aspx/1?Re+globalizationRe: globalization <p>hello,as u gave the site details&nbsp;i got an clear idea n i am thanx ful for it,n can u just let me know wheter where i&nbsp;have to writhe the initialize cultre()in my application as i am pasting the masterpage&nbsp;code&nbsp;just have a look in it&nbsp; n let me inform about it&nbsp;,this is my base calss code</p> <p>Imports System.Data<br> Imports System.Configuration<br> Imports System.Web<br> Imports System.Web.Security<br> Imports System.Web.UI<br> Imports System.Web.UI.WebControls<br> Imports System.Web.UI.WebControls.WebParts<br> Imports System.Web.UI.HtmlControls<br> Imports System.Threading<br> Imports System.Globalization<br> Imports Microsoft.VisualBasic<br> Imports System</p> <p><br> Public Class BasePage<br> &nbsp;&nbsp;&nbsp; Inherits Page</p> <p><br> &nbsp;&nbsp; </p> <p>&nbsp;&nbsp;&nbsp; Public Sub Arabic()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; SetCulture(&quot;ar-SA&quot;, &quot;ar-SA&quot;)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; If Session(&quot;MyUICulture&quot;) IsNot Nothing AndAlso Session(&quot;MyCulture&quot;) IsNot Nothing Then<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentUICulture = DirectCast(Session(&quot;MyUICulture&quot;), CultureInfo)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentCulture = DirectCast(Session(&quot;MyCulture&quot;), CultureInfo)</p> <p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; End If<br> &nbsp;&nbsp;&nbsp; End Sub<br> &nbsp;&nbsp;&nbsp; Public Sub Engilsh()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; SetCulture(&quot;en-US&quot;, &quot;en-US&quot;)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; If Session(&quot;MyUICulture&quot;) IsNot Nothing AndAlso Session(&quot;MyCulture&quot;) IsNot Nothing Then<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentUICulture = DirectCast(Session(&quot;MyUICulture&quot;), CultureInfo)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentCulture = DirectCast(Session(&quot;MyCulture&quot;), CultureInfo)</p> <p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; End If<br> &nbsp;&nbsp;&nbsp; End Sub</p> <p>&nbsp;</p> <p><br> &nbsp;&nbsp;&nbsp; Protected Sub SetCulture(ByVal name As String, ByVal locale As String)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Try</p> <p><br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentUICulture = New CultureInfo(name)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentCulture = New CultureInfo(locale)</p> <p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;MyUICulture&quot;) = Thread.CurrentThread.CurrentUICulture<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;MyCulture&quot;) = Thread.CurrentThread.CurrentCulture<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Catch ex As Exception<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; MsgBox(ex.ToString())<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; End Try<br> &nbsp;&nbsp;&nbsp; End Sub<br> &nbsp;&nbsp;&nbsp; <br> &nbsp;&nbsp; <br> &nbsp;&nbsp;&nbsp; <br> &nbsp;&nbsp;&nbsp; Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; If Session(&quot;MyUICulture&quot;) IsNot Nothing AndAlso Session(&quot;MyCulture&quot;) IsNot Nothing Then<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentUICulture = DirectCast(Session(&quot;MyUICulture&quot;), CultureInfo)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentCulture = DirectCast(Session(&quot;MyCulture&quot;), CultureInfo)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; End If<br> &nbsp;&nbsp;&nbsp; End Sub</p> <p><br> End Class</p> <p>&nbsp;and this is my master.vb code</p> <p>Imports System.Data<br> Imports System<br> Imports System.Collections<br> Imports System.Configuration</p> <p>Imports System.Linq<br> Imports System.Web<br> Imports System.Web.Security<br> Imports System.Web.UI<br> Imports System.Web.UI.HtmlControls<br> Imports System.Web.UI.WebControls<br> Imports System.Web.UI.WebControls.WebParts<br> Imports System.Xml.Linq</p> <p>Imports System.Threading<br> Imports System.Globalization<br> Imports System.Resources<br> Partial Class MasterPage<br> &nbsp;&nbsp;&nbsp; Inherits System.Web.UI.MasterPage</p> <p>&nbsp;&nbsp;&nbsp; Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; If Not IsPostBack Then<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; English()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;language&quot;) = &quot;English&quot;<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;PageDir&quot;) = &quot;ltr&quot;<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Response.Write(Session(&quot;language&quot;).ToString())<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; End If</p> <p>&nbsp;&nbsp;&nbsp; End Sub</p> <p>&nbsp;&nbsp;&nbsp; Protected Sub BtnArabic_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles BtnArabic.Click<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Arabic()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;language&quot;) = &quot;Arabic&quot;<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;PageDir&quot;) = &quot;rtl&quot;<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Response.Write(Session(&quot;language&quot;).ToString())<br> &nbsp;&nbsp;&nbsp; End Sub</p> <p>&nbsp;&nbsp;&nbsp; Protected Sub BtnEnglish_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles BtnEnglish.Click<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; English()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;language&quot;) = &quot;English&quot;<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;PageDir&quot;) = &quot;ltr&quot;<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Response.Write(Session(&quot;language&quot;).ToString())<br> &nbsp;&nbsp;&nbsp; End Sub<br> &nbsp;&nbsp;&nbsp; Private Sub English()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Dim obj As New BasePage()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; obj.Engilsh()</p> <p>&nbsp;&nbsp;&nbsp; End Sub<br> &nbsp;&nbsp;&nbsp; Private Sub Arabic()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Dim obj As New BasePage()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; obj.Arabic()</p> <p>&nbsp;&nbsp;&nbsp; End Sub</p> <p>End Class</p> <p>&nbsp;wat mistake i have dont </p> 2010-01-11T07:21:28-05:003609638http://forums.asp.net/p/1512319/3609638.aspx/1?Re+globalizationRe: globalization <p>hello,as u gave the site details&nbsp;i got an clear idea n i am thanx ful for it,n can u just let me know wheter where i&nbsp;have to writhe the initialize cultre()in my application as i am pasting the masterpage&nbsp;code&nbsp;just have a look in it&nbsp; n let me inform about it&nbsp;,this is my base calss code</p> <p>Imports System.Data<br> Imports System.Configuration<br> Imports System.Web<br> Imports System.Web.Security<br> Imports System.Web.UI<br> Imports System.Web.UI.WebControls<br> Imports System.Web.UI.WebControls.WebParts<br> Imports System.Web.UI.HtmlControls<br> Imports System.Threading<br> Imports System.Globalization<br> Imports Microsoft.VisualBasic<br> Imports System</p> <p><br> Public Class BasePage<br> &nbsp;&nbsp;&nbsp; Inherits Page</p> <p><br> &nbsp;&nbsp; </p> <p>&nbsp;&nbsp;&nbsp; Public Sub Arabic()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; SetCulture(&quot;ar-SA&quot;, &quot;ar-SA&quot;)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; If Session(&quot;MyUICulture&quot;) IsNot Nothing AndAlso Session(&quot;MyCulture&quot;) IsNot Nothing Then<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentUICulture = DirectCast(Session(&quot;MyUICulture&quot;), CultureInfo)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentCulture = DirectCast(Session(&quot;MyCulture&quot;), CultureInfo)</p> <p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; End If<br> &nbsp;&nbsp;&nbsp; End Sub<br> &nbsp;&nbsp;&nbsp; Public Sub Engilsh()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; SetCulture(&quot;en-US&quot;, &quot;en-US&quot;)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; If Session(&quot;MyUICulture&quot;) IsNot Nothing AndAlso Session(&quot;MyCulture&quot;) IsNot Nothing Then<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentUICulture = DirectCast(Session(&quot;MyUICulture&quot;), CultureInfo)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentCulture = DirectCast(Session(&quot;MyCulture&quot;), CultureInfo)</p> <p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; End If<br> &nbsp;&nbsp;&nbsp; End Sub</p> <p>&nbsp;</p> <p><br> &nbsp;&nbsp;&nbsp; Protected Sub SetCulture(ByVal name As String, ByVal locale As String)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Try</p> <p><br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentUICulture = New CultureInfo(name)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentCulture = New CultureInfo(locale)</p> <p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;MyUICulture&quot;) = Thread.CurrentThread.CurrentUICulture<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;MyCulture&quot;) = Thread.CurrentThread.CurrentCulture<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Catch ex As Exception<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; MsgBox(ex.ToString())<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; End Try<br> &nbsp;&nbsp;&nbsp; End Sub<br> &nbsp;&nbsp;&nbsp; <br> &nbsp;&nbsp; <br> &nbsp;&nbsp;&nbsp; <br> &nbsp;&nbsp;&nbsp; Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; If Session(&quot;MyUICulture&quot;) IsNot Nothing AndAlso Session(&quot;MyCulture&quot;) IsNot Nothing Then<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentUICulture = DirectCast(Session(&quot;MyUICulture&quot;), CultureInfo)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentCulture = DirectCast(Session(&quot;MyCulture&quot;), CultureInfo)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; End If<br> &nbsp;&nbsp;&nbsp; End Sub</p> <p><br> End Class</p> <p>&nbsp;and this is my master.vb code</p> <p>Imports System.Data<br> Imports System<br> Imports System.Collections<br> Imports System.Configuration</p> <p>Imports System.Linq<br> Imports System.Web<br> Imports System.Web.Security<br> Imports System.Web.UI<br> Imports System.Web.UI.HtmlControls<br> Imports System.Web.UI.WebControls<br> Imports System.Web.UI.WebControls.WebParts<br> Imports System.Xml.Linq</p> <p>Imports System.Threading<br> Imports System.Globalization<br> Imports System.Resources<br> Partial Class MasterPage<br> &nbsp;&nbsp;&nbsp; Inherits System.Web.UI.MasterPage</p> <p>&nbsp;&nbsp;&nbsp; Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; If Not IsPostBack Then<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; English()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;language&quot;) = &quot;English&quot;<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;PageDir&quot;) = &quot;ltr&quot;<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Response.Write(Session(&quot;language&quot;).ToString())<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; End If</p> <p>&nbsp;&nbsp;&nbsp; End Sub</p> <p>&nbsp;&nbsp;&nbsp; Protected Sub BtnArabic_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles BtnArabic.Click<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Arabic()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;language&quot;) = &quot;Arabic&quot;<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;PageDir&quot;) = &quot;rtl&quot;<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Response.Write(Session(&quot;language&quot;).ToString())<br> &nbsp;&nbsp;&nbsp; End Sub</p> <p>&nbsp;&nbsp;&nbsp; Protected Sub BtnEnglish_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles BtnEnglish.Click<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; English()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;language&quot;) = &quot;English&quot;<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;PageDir&quot;) = &quot;ltr&quot;<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Response.Write(Session(&quot;language&quot;).ToString())<br> &nbsp;&nbsp;&nbsp; End Sub<br> &nbsp;&nbsp;&nbsp; Private Sub English()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Dim obj As New BasePage()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; obj.Engilsh()</p> <p>&nbsp;&nbsp;&nbsp; End Sub<br> &nbsp;&nbsp;&nbsp; Private Sub Arabic()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Dim obj As New BasePage()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; obj.Arabic()</p> <p>&nbsp;&nbsp;&nbsp; End Sub</p> <p>End Class</p> <p>&nbsp;wat mistake i have done an </p> 2010-01-11T07:21:35-05:003609639http://forums.asp.net/p/1512319/3609639.aspx/1?Re+globalizationRe: globalization <p>hello,as u gave the site details&nbsp;i got an clear idea n i am thanx ful for it,n can u just let me know wheter where i&nbsp;have to writhe the initialize cultre()in my application as i am pasting the masterpage&nbsp;code&nbsp;just have a look in it&nbsp; n let me inform about it&nbsp;,this is my base calss code</p> <p>Imports System.Data<br> Imports System.Configuration<br> Imports System.Web<br> Imports System.Web.Security<br> Imports System.Web.UI<br> Imports System.Web.UI.WebControls<br> Imports System.Web.UI.WebControls.WebParts<br> Imports System.Web.UI.HtmlControls<br> Imports System.Threading<br> Imports System.Globalization<br> Imports Microsoft.VisualBasic<br> Imports System</p> <p><br> Public Class BasePage<br> &nbsp;&nbsp;&nbsp; Inherits Page</p> <p><br> &nbsp;&nbsp; </p> <p>&nbsp;&nbsp;&nbsp; Public Sub Arabic()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; SetCulture(&quot;ar-SA&quot;, &quot;ar-SA&quot;)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; If Session(&quot;MyUICulture&quot;) IsNot Nothing AndAlso Session(&quot;MyCulture&quot;) IsNot Nothing Then<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentUICulture = DirectCast(Session(&quot;MyUICulture&quot;), CultureInfo)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentCulture = DirectCast(Session(&quot;MyCulture&quot;), CultureInfo)</p> <p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; End If<br> &nbsp;&nbsp;&nbsp; End Sub<br> &nbsp;&nbsp;&nbsp; Public Sub Engilsh()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; SetCulture(&quot;en-US&quot;, &quot;en-US&quot;)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; If Session(&quot;MyUICulture&quot;) IsNot Nothing AndAlso Session(&quot;MyCulture&quot;) IsNot Nothing Then<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentUICulture = DirectCast(Session(&quot;MyUICulture&quot;), CultureInfo)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentCulture = DirectCast(Session(&quot;MyCulture&quot;), CultureInfo)</p> <p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; End If<br> &nbsp;&nbsp;&nbsp; End Sub</p> <p>&nbsp;</p> <p><br> &nbsp;&nbsp;&nbsp; Protected Sub SetCulture(ByVal name As String, ByVal locale As String)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Try</p> <p><br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentUICulture = New CultureInfo(name)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentCulture = New CultureInfo(locale)</p> <p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;MyUICulture&quot;) = Thread.CurrentThread.CurrentUICulture<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;MyCulture&quot;) = Thread.CurrentThread.CurrentCulture<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Catch ex As Exception<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; MsgBox(ex.ToString())<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; End Try<br> &nbsp;&nbsp;&nbsp; End Sub<br> &nbsp;&nbsp;&nbsp; <br> &nbsp;&nbsp; <br> &nbsp;&nbsp;&nbsp; <br> &nbsp;&nbsp;&nbsp; Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; If Session(&quot;MyUICulture&quot;) IsNot Nothing AndAlso Session(&quot;MyCulture&quot;) IsNot Nothing Then<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentUICulture = DirectCast(Session(&quot;MyUICulture&quot;), CultureInfo)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentCulture = DirectCast(Session(&quot;MyCulture&quot;), CultureInfo)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; End If<br> &nbsp;&nbsp;&nbsp; End Sub</p> <p><br> End Class</p> <p>&nbsp;and this is my master.vb code</p> <p>Imports System.Data<br> Imports System<br> Imports System.Collections<br> Imports System.Configuration</p> <p>Imports System.Linq<br> Imports System.Web<br> Imports System.Web.Security<br> Imports System.Web.UI<br> Imports System.Web.UI.HtmlControls<br> Imports System.Web.UI.WebControls<br> Imports System.Web.UI.WebControls.WebParts<br> Imports System.Xml.Linq</p> <p>Imports System.Threading<br> Imports System.Globalization<br> Imports System.Resources<br> Partial Class MasterPage<br> &nbsp;&nbsp;&nbsp; Inherits System.Web.UI.MasterPage</p> <p>&nbsp;&nbsp;&nbsp; Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; If Not IsPostBack Then<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; English()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;language&quot;) = &quot;English&quot;<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;PageDir&quot;) = &quot;ltr&quot;<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Response.Write(Session(&quot;language&quot;).ToString())<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; End If</p> <p>&nbsp;&nbsp;&nbsp; End Sub</p> <p>&nbsp;&nbsp;&nbsp; Protected Sub BtnArabic_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles BtnArabic.Click<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Arabic()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;language&quot;) = &quot;Arabic&quot;<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;PageDir&quot;) = &quot;rtl&quot;<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Response.Write(Session(&quot;language&quot;).ToString())<br> &nbsp;&nbsp;&nbsp; End Sub</p> <p>&nbsp;&nbsp;&nbsp; Protected Sub BtnEnglish_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles BtnEnglish.Click<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; English()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;language&quot;) = &quot;English&quot;<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;PageDir&quot;) = &quot;ltr&quot;<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Response.Write(Session(&quot;language&quot;).ToString())<br> &nbsp;&nbsp;&nbsp; End Sub<br> &nbsp;&nbsp;&nbsp; Private Sub English()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Dim obj As New BasePage()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; obj.Engilsh()</p> <p>&nbsp;&nbsp;&nbsp; End Sub<br> &nbsp;&nbsp;&nbsp; Private Sub Arabic()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Dim obj As New BasePage()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; obj.Arabic()</p> <p>&nbsp;&nbsp;&nbsp; End Sub</p> <p>End Class</p> <p>&nbsp;wat mistake i have </p> 2010-01-11T07:21:41-05:003609640http://forums.asp.net/p/1512319/3609640.aspx/1?Re+globalizationRe: globalization <p>hello,as u gave the site details&nbsp;i got an clear idea n i am thanx ful for it,n can u just let me know wheter where i&nbsp;have to writhe the initialize cultre()in my application as i am pasting the masterpage&nbsp;code&nbsp;just have a look in it&nbsp; n let me inform about it&nbsp;,this is my base calss code</p> <p>Imports System.Data<br> Imports System.Configuration<br> Imports System.Web<br> Imports System.Web.Security<br> Imports System.Web.UI<br> Imports System.Web.UI.WebControls<br> Imports System.Web.UI.WebControls.WebParts<br> Imports System.Web.UI.HtmlControls<br> Imports System.Threading<br> Imports System.Globalization<br> Imports Microsoft.VisualBasic<br> Imports System</p> <p><br> Public Class BasePage<br> &nbsp;&nbsp;&nbsp; Inherits Page</p> <p><br> &nbsp;&nbsp; </p> <p>&nbsp;&nbsp;&nbsp; Public Sub Arabic()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; SetCulture(&quot;ar-SA&quot;, &quot;ar-SA&quot;)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; If Session(&quot;MyUICulture&quot;) IsNot Nothing AndAlso Session(&quot;MyCulture&quot;) IsNot Nothing Then<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentUICulture = DirectCast(Session(&quot;MyUICulture&quot;), CultureInfo)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentCulture = DirectCast(Session(&quot;MyCulture&quot;), CultureInfo)</p> <p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; End If<br> &nbsp;&nbsp;&nbsp; End Sub<br> &nbsp;&nbsp;&nbsp; Public Sub Engilsh()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; SetCulture(&quot;en-US&quot;, &quot;en-US&quot;)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; If Session(&quot;MyUICulture&quot;) IsNot Nothing AndAlso Session(&quot;MyCulture&quot;) IsNot Nothing Then<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentUICulture = DirectCast(Session(&quot;MyUICulture&quot;), CultureInfo)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentCulture = DirectCast(Session(&quot;MyCulture&quot;), CultureInfo)</p> <p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; End If<br> &nbsp;&nbsp;&nbsp; End Sub</p> <p>&nbsp;</p> <p><br> &nbsp;&nbsp;&nbsp; Protected Sub SetCulture(ByVal name As String, ByVal locale As String)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Try</p> <p><br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentUICulture = New CultureInfo(name)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentCulture = New CultureInfo(locale)</p> <p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;MyUICulture&quot;) = Thread.CurrentThread.CurrentUICulture<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;MyCulture&quot;) = Thread.CurrentThread.CurrentCulture<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Catch ex As Exception<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; MsgBox(ex.ToString())<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; End Try<br> &nbsp;&nbsp;&nbsp; End Sub<br> &nbsp;&nbsp;&nbsp; <br> &nbsp;&nbsp; <br> &nbsp;&nbsp;&nbsp; <br> &nbsp;&nbsp;&nbsp; Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; If Session(&quot;MyUICulture&quot;) IsNot Nothing AndAlso Session(&quot;MyCulture&quot;) IsNot Nothing Then<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentUICulture = DirectCast(Session(&quot;MyUICulture&quot;), CultureInfo)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentCulture = DirectCast(Session(&quot;MyCulture&quot;), CultureInfo)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; End If<br> &nbsp;&nbsp;&nbsp; End Sub</p> <p><br> End Class</p> <p>&nbsp;and this is my master.vb code</p> <p>Imports System.Data<br> Imports System<br> Imports System.Collections<br> Imports System.Configuration</p> <p>Imports System.Linq<br> Imports System.Web<br> Imports System.Web.Security<br> Imports System.Web.UI<br> Imports System.Web.UI.HtmlControls<br> Imports System.Web.UI.WebControls<br> Imports System.Web.UI.WebControls.WebParts<br> Imports System.Xml.Linq</p> <p>Imports System.Threading<br> Imports System.Globalization<br> Imports System.Resources<br> Partial Class MasterPage<br> &nbsp;&nbsp;&nbsp; Inherits System.Web.UI.MasterPage</p> <p>&nbsp;&nbsp;&nbsp; Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; If Not IsPostBack Then<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; English()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;language&quot;) = &quot;English&quot;<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;PageDir&quot;) = &quot;ltr&quot;<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Response.Write(Session(&quot;language&quot;).ToString())<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; End If</p> <p>&nbsp;&nbsp;&nbsp; End Sub</p> <p>&nbsp;&nbsp;&nbsp; Protected Sub BtnArabic_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles BtnArabic.Click<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Arabic()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;language&quot;) = &quot;Arabic&quot;<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;PageDir&quot;) = &quot;rtl&quot;<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Response.Write(Session(&quot;language&quot;).ToString())<br> &nbsp;&nbsp;&nbsp; End Sub</p> <p>&nbsp;&nbsp;&nbsp; Protected Sub BtnEnglish_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles BtnEnglish.Click<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; English()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;language&quot;) = &quot;English&quot;<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;PageDir&quot;) = &quot;ltr&quot;<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Response.Write(Session(&quot;language&quot;).ToString())<br> &nbsp;&nbsp;&nbsp; End Sub<br> &nbsp;&nbsp;&nbsp; Private Sub English()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Dim obj As New BasePage()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; obj.Engilsh()</p> <p>&nbsp;&nbsp;&nbsp; End Sub<br> &nbsp;&nbsp;&nbsp; Private Sub Arabic()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Dim obj As New BasePage()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; obj.Arabic()</p> <p>&nbsp;&nbsp;&nbsp; End Sub</p> <p>End Class</p> <p>&nbsp;wat mistake i </p> 2010-01-11T07:21:47-05:003609641http://forums.asp.net/p/1512319/3609641.aspx/1?Re+globalizationRe: globalization <p>hello,as u gave the site details&nbsp;i got an clear idea n i am thanx ful for it,n can u just let me know wheter where i&nbsp;have to writhe the initialize cultre()in my application as i am pasting the masterpage&nbsp;code&nbsp;just have a look in it&nbsp; n let me inform about it&nbsp;,this is my base calss code</p> <p>Imports System.Data<br> Imports System.Configuration<br> Imports System.Web<br> Imports System.Web.Security<br> Imports System.Web.UI<br> Imports System.Web.UI.WebControls<br> Imports System.Web.UI.WebControls.WebParts<br> Imports System.Web.UI.HtmlControls<br> Imports System.Threading<br> Imports System.Globalization<br> Imports Microsoft.VisualBasic<br> Imports System</p> <p><br> Public Class BasePage<br> &nbsp;&nbsp;&nbsp; Inherits Page</p> <p><br> &nbsp;&nbsp; </p> <p>&nbsp;&nbsp;&nbsp; Public Sub Arabic()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; SetCulture(&quot;ar-SA&quot;, &quot;ar-SA&quot;)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; If Session(&quot;MyUICulture&quot;) IsNot Nothing AndAlso Session(&quot;MyCulture&quot;) IsNot Nothing Then<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentUICulture = DirectCast(Session(&quot;MyUICulture&quot;), CultureInfo)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentCulture = DirectCast(Session(&quot;MyCulture&quot;), CultureInfo)</p> <p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; End If<br> &nbsp;&nbsp;&nbsp; End Sub<br> &nbsp;&nbsp;&nbsp; Public Sub Engilsh()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; SetCulture(&quot;en-US&quot;, &quot;en-US&quot;)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; If Session(&quot;MyUICulture&quot;) IsNot Nothing AndAlso Session(&quot;MyCulture&quot;) IsNot Nothing Then<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentUICulture = DirectCast(Session(&quot;MyUICulture&quot;), CultureInfo)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentCulture = DirectCast(Session(&quot;MyCulture&quot;), CultureInfo)</p> <p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; End If<br> &nbsp;&nbsp;&nbsp; End Sub</p> <p>&nbsp;</p> <p><br> &nbsp;&nbsp;&nbsp; Protected Sub SetCulture(ByVal name As String, ByVal locale As String)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Try</p> <p><br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentUICulture = New CultureInfo(name)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentCulture = New CultureInfo(locale)</p> <p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;MyUICulture&quot;) = Thread.CurrentThread.CurrentUICulture<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;MyCulture&quot;) = Thread.CurrentThread.CurrentCulture<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Catch ex As Exception<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; MsgBox(ex.ToString())<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; End Try<br> &nbsp;&nbsp;&nbsp; End Sub<br> &nbsp;&nbsp;&nbsp; <br> &nbsp;&nbsp; <br> &nbsp;&nbsp;&nbsp; <br> &nbsp;&nbsp;&nbsp; Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; If Session(&quot;MyUICulture&quot;) IsNot Nothing AndAlso Session(&quot;MyCulture&quot;) IsNot Nothing Then<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentUICulture = DirectCast(Session(&quot;MyUICulture&quot;), CultureInfo)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentCulture = DirectCast(Session(&quot;MyCulture&quot;), CultureInfo)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; End If<br> &nbsp;&nbsp;&nbsp; End Sub</p> <p><br> End Class</p> <p>&nbsp;and this is my master.vb code</p> <p>Imports System.Data<br> Imports System<br> Imports System.Collections<br> Imports System.Configuration</p> <p>Imports System.Linq<br> Imports System.Web<br> Imports System.Web.Security<br> Imports System.Web.UI<br> Imports System.Web.UI.HtmlControls<br> Imports System.Web.UI.WebControls<br> Imports System.Web.UI.WebControls.WebParts<br> Imports System.Xml.Linq</p> <p>Imports System.Threading<br> Imports System.Globalization<br> Imports System.Resources<br> Partial Class MasterPage<br> &nbsp;&nbsp;&nbsp; Inherits System.Web.UI.MasterPage</p> <p>&nbsp;&nbsp;&nbsp; Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; If Not IsPostBack Then<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; English()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;language&quot;) = &quot;English&quot;<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;PageDir&quot;) = &quot;ltr&quot;<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Response.Write(Session(&quot;language&quot;).ToString())<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; End If</p> <p>&nbsp;&nbsp;&nbsp; End Sub</p> <p>&nbsp;&nbsp;&nbsp; Protected Sub BtnArabic_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles BtnArabic.Click<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Arabic()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;language&quot;) = &quot;Arabic&quot;<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;PageDir&quot;) = &quot;rtl&quot;<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Response.Write(Session(&quot;language&quot;).ToString())<br> &nbsp;&nbsp;&nbsp; End Sub</p> <p>&nbsp;&nbsp;&nbsp; Protected Sub BtnEnglish_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles BtnEnglish.Click<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; English()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;language&quot;) = &quot;English&quot;<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;PageDir&quot;) = &quot;ltr&quot;<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Response.Write(Session(&quot;language&quot;).ToString())<br> &nbsp;&nbsp;&nbsp; End Sub<br> &nbsp;&nbsp;&nbsp; Private Sub English()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Dim obj As New BasePage()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; obj.Engilsh()</p> <p>&nbsp;&nbsp;&nbsp; End Sub<br> &nbsp;&nbsp;&nbsp; Private Sub Arabic()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Dim obj As New BasePage()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; obj.Arabic()</p> <p>&nbsp;&nbsp;&nbsp; End Sub</p> <p>End Class</p> <p>&nbsp;wat mistake i have done n y&nbsp;&nbsp;&nbsp; </p> 2010-01-11T07:21:49-05:003609642http://forums.asp.net/p/1512319/3609642.aspx/1?Re+globalizationRe: globalization <p>hello,as u gave the site details&nbsp;i got an clear idea n i am thanx ful for it,n can u just let me know wheter where i&nbsp;have to writhe the initialize cultre()in my application as i am pasting the masterpage&nbsp;code&nbsp;just have a look in it&nbsp; n let me inform about it&nbsp;,this is my base calss code</p> <p>Imports System.Data<br> Imports System.Configuration<br> Imports System.Web<br> Imports System.Web.Security<br> Imports System.Web.UI<br> Imports System.Web.UI.WebControls<br> Imports System.Web.UI.WebControls.WebParts<br> Imports System.Web.UI.HtmlControls<br> Imports System.Threading<br> Imports System.Globalization<br> Imports Microsoft.VisualBasic<br> Imports System</p> <p><br> Public Class BasePage<br> &nbsp;&nbsp;&nbsp; Inherits Page</p> <p><br> &nbsp;&nbsp; </p> <p>&nbsp;&nbsp;&nbsp; Public Sub Arabic()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; SetCulture(&quot;ar-SA&quot;, &quot;ar-SA&quot;)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; If Session(&quot;MyUICulture&quot;) IsNot Nothing AndAlso Session(&quot;MyCulture&quot;) IsNot Nothing Then<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentUICulture = DirectCast(Session(&quot;MyUICulture&quot;), CultureInfo)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentCulture = DirectCast(Session(&quot;MyCulture&quot;), CultureInfo)</p> <p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; End If<br> &nbsp;&nbsp;&nbsp; End Sub<br> &nbsp;&nbsp;&nbsp; Public Sub Engilsh()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; SetCulture(&quot;en-US&quot;, &quot;en-US&quot;)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; If Session(&quot;MyUICulture&quot;) IsNot Nothing AndAlso Session(&quot;MyCulture&quot;) IsNot Nothing Then<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentUICulture = DirectCast(Session(&quot;MyUICulture&quot;), CultureInfo)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentCulture = DirectCast(Session(&quot;MyCulture&quot;), CultureInfo)</p> <p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; End If<br> &nbsp;&nbsp;&nbsp; End Sub</p> <p>&nbsp;</p> <p><br> &nbsp;&nbsp;&nbsp; Protected Sub SetCulture(ByVal name As String, ByVal locale As String)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Try</p> <p><br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentUICulture = New CultureInfo(name)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentCulture = New CultureInfo(locale)</p> <p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;MyUICulture&quot;) = Thread.CurrentThread.CurrentUICulture<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;MyCulture&quot;) = Thread.CurrentThread.CurrentCulture<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Catch ex As Exception<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; MsgBox(ex.ToString())<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; End Try<br> &nbsp;&nbsp;&nbsp; End Sub<br> &nbsp;&nbsp;&nbsp; <br> &nbsp;&nbsp; <br> &nbsp;&nbsp;&nbsp; <br> &nbsp;&nbsp;&nbsp; Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; If Session(&quot;MyUICulture&quot;) IsNot Nothing AndAlso Session(&quot;MyCulture&quot;) IsNot Nothing Then<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentUICulture = DirectCast(Session(&quot;MyUICulture&quot;), CultureInfo)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentCulture = DirectCast(Session(&quot;MyCulture&quot;), CultureInfo)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; End If<br> &nbsp;&nbsp;&nbsp; End Sub</p> <p><br> End Class</p> <p>&nbsp;and this is my master.vb code</p> <p>Imports System.Data<br> Imports System<br> Imports System.Collections<br> Imports System.Configuration</p> <p>Imports System.Linq<br> Imports System.Web<br> Imports System.Web.Security<br> Imports System.Web.UI<br> Imports System.Web.UI.HtmlControls<br> Imports System.Web.UI.WebControls<br> Imports System.Web.UI.WebControls.WebParts<br> Imports System.Xml.Linq</p> <p>Imports System.Threading<br> Imports System.Globalization<br> Imports System.Resources<br> Partial Class MasterPage<br> &nbsp;&nbsp;&nbsp; Inherits System.Web.UI.MasterPage</p> <p>&nbsp;&nbsp;&nbsp; Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; If Not IsPostBack Then<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; English()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;language&quot;) = &quot;English&quot;<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;PageDir&quot;) = &quot;ltr&quot;<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Response.Write(Session(&quot;language&quot;).ToString())<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; End If</p> <p>&nbsp;&nbsp;&nbsp; End Sub</p> <p>&nbsp;&nbsp;&nbsp; Protected Sub BtnArabic_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles BtnArabic.Click<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Arabic()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;language&quot;) = &quot;Arabic&quot;<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;PageDir&quot;) = &quot;rtl&quot;<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Response.Write(Session(&quot;language&quot;).ToString())<br> &nbsp;&nbsp;&nbsp; End Sub</p> <p>&nbsp;&nbsp;&nbsp; Protected Sub BtnEnglish_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles BtnEnglish.Click<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; English()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;language&quot;) = &quot;English&quot;<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;PageDir&quot;) = &quot;ltr&quot;<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Response.Write(Session(&quot;language&quot;).ToString())<br> &nbsp;&nbsp;&nbsp; End Sub<br> &nbsp;&nbsp;&nbsp; Private Sub English()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Dim obj As New BasePage()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; obj.Engilsh()</p> <p>&nbsp;&nbsp;&nbsp; End Sub<br> &nbsp;&nbsp;&nbsp; Private Sub Arabic()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Dim obj As New BasePage()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; obj.Arabic()</p> <p>&nbsp;&nbsp;&nbsp; End Sub</p> <p>End Class</p> <p>&nbsp;wat mistake i have done any </p> 2010-01-11T07:21:51-05:003609643http://forums.asp.net/p/1512319/3609643.aspx/1?Re+globalizationRe: globalization <p>hello,as u gave the site details&nbsp;i got an clear idea n i am thanx ful for it,n can u just let me know wheter where i&nbsp;have to writhe the initialize cultre()in my application as i am pasting the masterpage&nbsp;code&nbsp;just have a look in it&nbsp; n let me inform about it&nbsp;,this is my base calss code</p> <p>Imports System.Data<br> Imports System.Configuration<br> Imports System.Web<br> Imports System.Web.Security<br> Imports System.Web.UI<br> Imports System.Web.UI.WebControls<br> Imports System.Web.UI.WebControls.WebParts<br> Imports System.Web.UI.HtmlControls<br> Imports System.Threading<br> Imports System.Globalization<br> Imports Microsoft.VisualBasic<br> Imports System</p> <p><br> Public Class BasePage<br> &nbsp;&nbsp;&nbsp; Inherits Page</p> <p><br> &nbsp;&nbsp; </p> <p>&nbsp;&nbsp;&nbsp; Public Sub Arabic()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; SetCulture(&quot;ar-SA&quot;, &quot;ar-SA&quot;)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; If Session(&quot;MyUICulture&quot;) IsNot Nothing AndAlso Session(&quot;MyCulture&quot;) IsNot Nothing Then<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentUICulture = DirectCast(Session(&quot;MyUICulture&quot;), CultureInfo)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentCulture = DirectCast(Session(&quot;MyCulture&quot;), CultureInfo)</p> <p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; End If<br> &nbsp;&nbsp;&nbsp; End Sub<br> &nbsp;&nbsp;&nbsp; Public Sub Engilsh()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; SetCulture(&quot;en-US&quot;, &quot;en-US&quot;)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; If Session(&quot;MyUICulture&quot;) IsNot Nothing AndAlso Session(&quot;MyCulture&quot;) IsNot Nothing Then<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentUICulture = DirectCast(Session(&quot;MyUICulture&quot;), CultureInfo)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentCulture = DirectCast(Session(&quot;MyCulture&quot;), CultureInfo)</p> <p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; End If<br> &nbsp;&nbsp;&nbsp; End Sub</p> <p>&nbsp;</p> <p><br> &nbsp;&nbsp;&nbsp; Protected Sub SetCulture(ByVal name As String, ByVal locale As String)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Try</p> <p><br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentUICulture = New CultureInfo(name)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentCulture = New CultureInfo(locale)</p> <p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;MyUICulture&quot;) = Thread.CurrentThread.CurrentUICulture<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;MyCulture&quot;) = Thread.CurrentThread.CurrentCulture<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Catch ex As Exception<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; MsgBox(ex.ToString())<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; End Try<br> &nbsp;&nbsp;&nbsp; End Sub<br> &nbsp;&nbsp;&nbsp; <br> &nbsp;&nbsp; <br> &nbsp;&nbsp;&nbsp; <br> &nbsp;&nbsp;&nbsp; Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; If Session(&quot;MyUICulture&quot;) IsNot Nothing AndAlso Session(&quot;MyCulture&quot;) IsNot Nothing Then<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentUICulture = DirectCast(Session(&quot;MyUICulture&quot;), CultureInfo)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentCulture = DirectCast(Session(&quot;MyCulture&quot;), CultureInfo)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; End If<br> &nbsp;&nbsp;&nbsp; End Sub</p> <p><br> End Class</p> <p>&nbsp;and this is my master.vb code</p> <p>Imports System.Data<br> Imports System<br> Imports System.Collections<br> Imports System.Configuration</p> <p>Imports System.Linq<br> Imports System.Web<br> Imports System.Web.Security<br> Imports System.Web.UI<br> Imports System.Web.UI.HtmlControls<br> Imports System.Web.UI.WebControls<br> Imports System.Web.UI.WebControls.WebParts<br> Imports System.Xml.Linq</p> <p>Imports System.Threading<br> Imports System.Globalization<br> Imports System.Resources<br> Partial Class MasterPage<br> &nbsp;&nbsp;&nbsp; Inherits System.Web.UI.MasterPage</p> <p>&nbsp;&nbsp;&nbsp; Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; If Not IsPostBack Then<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; English()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;language&quot;) = &quot;English&quot;<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;PageDir&quot;) = &quot;ltr&quot;<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Response.Write(Session(&quot;language&quot;).ToString())<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; End If</p> <p>&nbsp;&nbsp;&nbsp; End Sub</p> <p>&nbsp;&nbsp;&nbsp; Protected Sub BtnArabic_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles BtnArabic.Click<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Arabic()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;language&quot;) = &quot;Arabic&quot;<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;PageDir&quot;) = &quot;rtl&quot;<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Response.Write(Session(&quot;language&quot;).ToString())<br> &nbsp;&nbsp;&nbsp; End Sub</p> <p>&nbsp;&nbsp;&nbsp; Protected Sub BtnEnglish_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles BtnEnglish.Click<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; English()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;language&quot;) = &quot;English&quot;<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;PageDir&quot;) = &quot;ltr&quot;<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Response.Write(Session(&quot;language&quot;).ToString())<br> &nbsp;&nbsp;&nbsp; End Sub<br> &nbsp;&nbsp;&nbsp; Private Sub English()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Dim obj As New BasePage()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; obj.Engilsh()</p> <p>&nbsp;&nbsp;&nbsp; End Sub<br> &nbsp;&nbsp;&nbsp; Private Sub Arabic()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Dim obj As New BasePage()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; obj.Arabic()</p> <p>&nbsp;&nbsp;&nbsp; End Sub</p> <p>End Class</p> <p>&nbsp;wat mistake i have done </p> 2010-01-11T07:21:55-05:003609645http://forums.asp.net/p/1512319/3609645.aspx/1?Re+globalizationRe: globalization <p>hello,as u gave the site details&nbsp;i got an clear idea n i am thanx ful for it,n can u just let me know wheter where i&nbsp;have to writhe the initialize cultre()in my application as i am pasting the masterpage&nbsp;code&nbsp;just have a look in it&nbsp; n let me inform about it&nbsp;,this is my base calss code</p> <p>Imports System.Data<br> Imports System.Configuration<br> Imports System.Web<br> Imports System.Web.Security<br> Imports System.Web.UI<br> Imports System.Web.UI.WebControls<br> Imports System.Web.UI.WebControls.WebParts<br> Imports System.Web.UI.HtmlControls<br> Imports System.Threading<br> Imports System.Globalization<br> Imports Microsoft.VisualBasic<br> Imports System</p> <p><br> Public Class BasePage<br> &nbsp;&nbsp;&nbsp; Inherits Page</p> <p><br> &nbsp;&nbsp; </p> <p>&nbsp;&nbsp;&nbsp; Public Sub Arabic()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; SetCulture(&quot;ar-SA&quot;, &quot;ar-SA&quot;)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; If Session(&quot;MyUICulture&quot;) IsNot Nothing AndAlso Session(&quot;MyCulture&quot;) IsNot Nothing Then<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentUICulture = DirectCast(Session(&quot;MyUICulture&quot;), CultureInfo)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentCulture = DirectCast(Session(&quot;MyCulture&quot;), CultureInfo)</p> <p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; End If<br> &nbsp;&nbsp;&nbsp; End Sub<br> &nbsp;&nbsp;&nbsp; Public Sub Engilsh()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; SetCulture(&quot;en-US&quot;, &quot;en-US&quot;)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; If Session(&quot;MyUICulture&quot;) IsNot Nothing AndAlso Session(&quot;MyCulture&quot;) IsNot Nothing Then<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentUICulture = DirectCast(Session(&quot;MyUICulture&quot;), CultureInfo)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentCulture = DirectCast(Session(&quot;MyCulture&quot;), CultureInfo)</p> <p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; End If<br> &nbsp;&nbsp;&nbsp; End Sub</p> <p>&nbsp;</p> <p><br> &nbsp;&nbsp;&nbsp; Protected Sub SetCulture(ByVal name As String, ByVal locale As String)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Try</p> <p><br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentUICulture = New CultureInfo(name)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentCulture = New CultureInfo(locale)</p> <p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;MyUICulture&quot;) = Thread.CurrentThread.CurrentUICulture<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;MyCulture&quot;) = Thread.CurrentThread.CurrentCulture<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Catch ex As Exception<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; MsgBox(ex.ToString())<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; End Try<br> &nbsp;&nbsp;&nbsp; End Sub<br> &nbsp;&nbsp;&nbsp; <br> &nbsp;&nbsp; <br> &nbsp;&nbsp;&nbsp; <br> &nbsp;&nbsp;&nbsp; Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; If Session(&quot;MyUICulture&quot;) IsNot Nothing AndAlso Session(&quot;MyCulture&quot;) IsNot Nothing Then<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentUICulture = DirectCast(Session(&quot;MyUICulture&quot;), CultureInfo)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentCulture = DirectCast(Session(&quot;MyCulture&quot;), CultureInfo)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; End If<br> &nbsp;&nbsp;&nbsp; End Sub</p> <p><br> End Class</p> <p>&nbsp;and this is my master.vb code</p> <p>Imports System.Data<br> Imports System<br> Imports System.Collections<br> Imports System.Configuration</p> <p>Imports System.Linq<br> Imports System.Web<br> Imports System.Web.Security<br> Imports System.Web.UI<br> Imports System.Web.UI.HtmlControls<br> Imports System.Web.UI.WebControls<br> Imports System.Web.UI.WebControls.WebParts<br> Imports System.Xml.Linq</p> <p>Imports System.Threading<br> Imports System.Globalization<br> Imports System.Resources<br> Partial Class MasterPage<br> &nbsp;&nbsp;&nbsp; Inherits System.Web.UI.MasterPage</p> <p>&nbsp;&nbsp;&nbsp; Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; If Not IsPostBack Then<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; English()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;language&quot;) = &quot;English&quot;<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;PageDir&quot;) = &quot;ltr&quot;<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Response.Write(Session(&quot;language&quot;).ToString())<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; End If</p> <p>&nbsp;&nbsp;&nbsp; End Sub</p> <p>&nbsp;&nbsp;&nbsp; Protected Sub BtnArabic_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles BtnArabic.Click<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Arabic()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;language&quot;) = &quot;Arabic&quot;<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;PageDir&quot;) = &quot;rtl&quot;<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Response.Write(Session(&quot;language&quot;).ToString())<br> &nbsp;&nbsp;&nbsp; End Sub</p> <p>&nbsp;&nbsp;&nbsp; Protected Sub BtnEnglish_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles BtnEnglish.Click<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; English()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;language&quot;) = &quot;English&quot;<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;PageDir&quot;) = &quot;ltr&quot;<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Response.Write(Session(&quot;language&quot;).ToString())<br> &nbsp;&nbsp;&nbsp; End Sub<br> &nbsp;&nbsp;&nbsp; Private Sub English()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Dim obj As New BasePage()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; obj.Engilsh()</p> <p>&nbsp;&nbsp;&nbsp; End Sub<br> &nbsp;&nbsp;&nbsp; Private Sub Arabic()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Dim obj As New BasePage()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; obj.Arabic()</p> <p>&nbsp;&nbsp;&nbsp; End Sub</p> <p>End Class</p> <p>&nbsp;wat mistake i have done n y </p> 2010-01-11T07:22:02-05:003609646http://forums.asp.net/p/1512319/3609646.aspx/1?Re+globalizationRe: globalization <p>hello,as u gave the site details&nbsp;i got an clear idea n i am thanx ful for it,n can u just let me know wheter where i&nbsp;have to writhe the initialize cultre()in my application as i am pasting the masterpage&nbsp;code&nbsp;just have a look in it&nbsp; n let me inform about it&nbsp;,this is my base calss code</p> <p>Imports System.Data<br> Imports System.Configuration<br> Imports System.Web<br> Imports System.Web.Security<br> Imports System.Web.UI<br> Imports System.Web.UI.WebControls<br> Imports System.Web.UI.WebControls.WebParts<br> Imports System.Web.UI.HtmlControls<br> Imports System.Threading<br> Imports System.Globalization<br> Imports Microsoft.VisualBasic<br> Imports System</p> <p><br> Public Class BasePage<br> &nbsp;&nbsp;&nbsp; Inherits Page</p> <p><br> &nbsp;&nbsp; </p> <p>&nbsp;&nbsp;&nbsp; Public Sub Arabic()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; SetCulture(&quot;ar-SA&quot;, &quot;ar-SA&quot;)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; If Session(&quot;MyUICulture&quot;) IsNot Nothing AndAlso Session(&quot;MyCulture&quot;) IsNot Nothing Then<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentUICulture = DirectCast(Session(&quot;MyUICulture&quot;), CultureInfo)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentCulture = DirectCast(Session(&quot;MyCulture&quot;), CultureInfo)</p> <p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; End If<br> &nbsp;&nbsp;&nbsp; End Sub<br> &nbsp;&nbsp;&nbsp; Public Sub Engilsh()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; SetCulture(&quot;en-US&quot;, &quot;en-US&quot;)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; If Session(&quot;MyUICulture&quot;) IsNot Nothing AndAlso Session(&quot;MyCulture&quot;) IsNot Nothing Then<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentUICulture = DirectCast(Session(&quot;MyUICulture&quot;), CultureInfo)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentCulture = DirectCast(Session(&quot;MyCulture&quot;), CultureInfo)</p> <p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; End If<br> &nbsp;&nbsp;&nbsp; End Sub</p> <p>&nbsp;</p> <p><br> &nbsp;&nbsp;&nbsp; Protected Sub SetCulture(ByVal name As String, ByVal locale As String)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Try</p> <p><br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentUICulture = New CultureInfo(name)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentCulture = New CultureInfo(locale)</p> <p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;MyUICulture&quot;) = Thread.CurrentThread.CurrentUICulture<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;MyCulture&quot;) = Thread.CurrentThread.CurrentCulture<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Catch ex As Exception<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; MsgBox(ex.ToString())<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; End Try<br> &nbsp;&nbsp;&nbsp; End Sub<br> &nbsp;&nbsp;&nbsp; <br> &nbsp;&nbsp; <br> &nbsp;&nbsp;&nbsp; <br> &nbsp;&nbsp;&nbsp; Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; If Session(&quot;MyUICulture&quot;) IsNot Nothing AndAlso Session(&quot;MyCulture&quot;) IsNot Nothing Then<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentUICulture = DirectCast(Session(&quot;MyUICulture&quot;), CultureInfo)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentCulture = DirectCast(Session(&quot;MyCulture&quot;), CultureInfo)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; End If<br> &nbsp;&nbsp;&nbsp; End Sub</p> <p><br> End Class</p> <p>&nbsp;and this is my master.vb code</p> <p>Imports System.Data<br> Imports System<br> Imports System.Collections<br> Imports System.Configuration</p> <p>Imports System.Linq<br> Imports System.Web<br> Imports System.Web.Security<br> Imports System.Web.UI<br> Imports System.Web.UI.HtmlControls<br> Imports System.Web.UI.WebControls<br> Imports System.Web.UI.WebControls.WebParts<br> Imports System.Xml.Linq</p> <p>Imports System.Threading<br> Imports System.Globalization<br> Imports System.Resources<br> Partial Class MasterPage<br> &nbsp;&nbsp;&nbsp; Inherits System.Web.UI.MasterPage</p> <p>&nbsp;&nbsp;&nbsp; Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; If Not IsPostBack Then<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; English()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;language&quot;) = &quot;English&quot;<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;PageDir&quot;) = &quot;ltr&quot;<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Response.Write(Session(&quot;language&quot;).ToString())<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; End If</p> <p>&nbsp;&nbsp;&nbsp; End Sub</p> <p>&nbsp;&nbsp;&nbsp; Protected Sub BtnArabic_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles BtnArabic.Click<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Arabic()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;language&quot;) = &quot;Arabic&quot;<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;PageDir&quot;) = &quot;rtl&quot;<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Response.Write(Session(&quot;language&quot;).ToString())<br> &nbsp;&nbsp;&nbsp; End Sub</p> <p>&nbsp;&nbsp;&nbsp; Protected Sub BtnEnglish_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles BtnEnglish.Click<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; English()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;language&quot;) = &quot;English&quot;<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;PageDir&quot;) = &quot;ltr&quot;<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Response.Write(Session(&quot;language&quot;).ToString())<br> &nbsp;&nbsp;&nbsp; End Sub<br> &nbsp;&nbsp;&nbsp; Private Sub English()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Dim obj As New BasePage()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; obj.Engilsh()</p> <p>&nbsp;&nbsp;&nbsp; End Sub<br> &nbsp;&nbsp;&nbsp; Private Sub Arabic()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Dim obj As New BasePage()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; obj.Arabic()</p> <p>&nbsp;&nbsp;&nbsp; End Sub</p> <p>End Class</p> <p>&nbsp;wat mistake i have done n y&nbsp; </p> 2010-01-11T07:22:07-05:003609647http://forums.asp.net/p/1512319/3609647.aspx/1?Re+globalizationRe: globalization <p>hello,as u gave the site details&nbsp;i got an clear idea n i am thanx ful for it,n can u just let me know wheter where i&nbsp;have to writhe the initialize cultre()in my application as i am pasting the masterpage&nbsp;code&nbsp;just have a look in it&nbsp; n let me inform about it&nbsp;,this is my base calss code</p> <p>Imports System.Data<br> Imports System.Configuration<br> Imports System.Web<br> Imports System.Web.Security<br> Imports System.Web.UI<br> Imports System.Web.UI.WebControls<br> Imports System.Web.UI.WebControls.WebParts<br> Imports System.Web.UI.HtmlControls<br> Imports System.Threading<br> Imports System.Globalization<br> Imports Microsoft.VisualBasic<br> Imports System</p> <p><br> Public Class BasePage<br> &nbsp;&nbsp;&nbsp; Inherits Page</p> <p><br> &nbsp;&nbsp; </p> <p>&nbsp;&nbsp;&nbsp; Public Sub Arabic()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; SetCulture(&quot;ar-SA&quot;, &quot;ar-SA&quot;)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; If Session(&quot;MyUICulture&quot;) IsNot Nothing AndAlso Session(&quot;MyCulture&quot;) IsNot Nothing Then<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentUICulture = DirectCast(Session(&quot;MyUICulture&quot;), CultureInfo)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentCulture = DirectCast(Session(&quot;MyCulture&quot;), CultureInfo)</p> <p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; End If<br> &nbsp;&nbsp;&nbsp; End Sub<br> &nbsp;&nbsp;&nbsp; Public Sub Engilsh()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; SetCulture(&quot;en-US&quot;, &quot;en-US&quot;)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; If Session(&quot;MyUICulture&quot;) IsNot Nothing AndAlso Session(&quot;MyCulture&quot;) IsNot Nothing Then<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentUICulture = DirectCast(Session(&quot;MyUICulture&quot;), CultureInfo)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentCulture = DirectCast(Session(&quot;MyCulture&quot;), CultureInfo)</p> <p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; End If<br> &nbsp;&nbsp;&nbsp; End Sub</p> <p>&nbsp;</p> <p><br> &nbsp;&nbsp;&nbsp; Protected Sub SetCulture(ByVal name As String, ByVal locale As String)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Try</p> <p><br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentUICulture = New CultureInfo(name)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentCulture = New CultureInfo(locale)</p> <p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;MyUICulture&quot;) = Thread.CurrentThread.CurrentUICulture<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;MyCulture&quot;) = Thread.CurrentThread.CurrentCulture<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Catch ex As Exception<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; MsgBox(ex.ToString())<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; End Try<br> &nbsp;&nbsp;&nbsp; End Sub<br> &nbsp;&nbsp;&nbsp; <br> &nbsp;&nbsp; <br> &nbsp;&nbsp;&nbsp; <br> &nbsp;&nbsp;&nbsp; Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; If Session(&quot;MyUICulture&quot;) IsNot Nothing AndAlso Session(&quot;MyCulture&quot;) IsNot Nothing Then<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentUICulture = DirectCast(Session(&quot;MyUICulture&quot;), CultureInfo)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Thread.CurrentThread.CurrentCulture = DirectCast(Session(&quot;MyCulture&quot;), CultureInfo)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; End If<br> &nbsp;&nbsp;&nbsp; End Sub</p> <p><br> End Class</p> <p>&nbsp;and this is my master.vb code</p> <p>Imports System.Data<br> Imports System<br> Imports System.Collections<br> Imports System.Configuration</p> <p>Imports System.Linq<br> Imports System.Web<br> Imports System.Web.Security<br> Imports System.Web.UI<br> Imports System.Web.UI.HtmlControls<br> Imports System.Web.UI.WebControls<br> Imports System.Web.UI.WebControls.WebParts<br> Imports System.Xml.Linq</p> <p>Imports System.Threading<br> Imports System.Globalization<br> Imports System.Resources<br> Partial Class MasterPage<br> &nbsp;&nbsp;&nbsp; Inherits System.Web.UI.MasterPage</p> <p>&nbsp;&nbsp;&nbsp; Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; If Not IsPostBack Then<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; English()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;language&quot;) = &quot;English&quot;<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;PageDir&quot;) = &quot;ltr&quot;<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Response.Write(Session(&quot;language&quot;).ToString())<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; End If</p> <p>&nbsp;&nbsp;&nbsp; End Sub</p> <p>&nbsp;&nbsp;&nbsp; Protected Sub BtnArabic_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles BtnArabic.Click<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Arabic()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;language&quot;) = &quot;Arabic&quot;<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;PageDir&quot;) = &quot;rtl&quot;<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Response.Write(Session(&quot;language&quot;).ToString())<br> &nbsp;&nbsp;&nbsp; End Sub</p> <p>&nbsp;&nbsp;&nbsp; Protected Sub BtnEnglish_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles BtnEnglish.Click<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; English()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;language&quot;) = &quot;English&quot;<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Session(&quot;PageDir&quot;) = &quot;ltr&quot;<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Response.Write(Session(&quot;language&quot;).ToString())<br> &nbsp;&nbsp;&nbsp; End Sub<br> &nbsp;&nbsp;&nbsp; Private Sub English()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Dim obj As New BasePage()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; obj.Engilsh()</p> <p>&nbsp;&nbsp;&nbsp; End Sub<br> &nbsp;&nbsp;&nbsp; Private Sub Arabic()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Dim obj As New BasePage()<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; obj.Arabic()</p> <p>&nbsp;&nbsp;&nbsp; End Sub</p> <p>End Class</p> <p>&nbsp;wat mistake i have done n </p> 2010-01-11T07:22:11-05:00