1
Answer

Language translation in windows application with using net and resex files

saisagar nalla

saisagar nalla

12y
1.9k
1
i want change English language to Arabic language for windows application(winforms) with out using .resex and globalization concept. and one more thing net also not using. now is there any way to change language translation.
i thing with out using net and .resex files one more thing is there i.e adding corresponding .dll to our project. can u send that .dll (for any language). and how can i access it and implementing in my windows application
Answers (1)
0
Rams

Rams

NA 44 36.3k 13y
this also didnot work. Thanks for your fast reply. iam stuck up with the following error :

"system.net.webexception:the remote server returned an error 417 expectation failed
 at MBS.SmsMgr.SendSMS(Object stringPost)
   at MBS.Dispatcher.CommonProcedures.SendSMS(CommonProcedures objparams)".

Please do find the code below :




Public Function SendSMS(ByVal stringPost As System.Object) As String Implements ISmsMgr.sendSMSDim strReturnValue As String = String.EmptyDim objWebRequest As HttpWebRequest = Nothing


Dim objWebResponse As HttpWebResponse = Nothing


Dim objStreamWriter As StreamWriter = Nothing


Dim objStreamReader As StreamReader = Nothing


Try




Dim strProxyURL As String = String.EmptyDim iProxyPort As Integer = 0If Not ConfigurationManager.AppSettings.Item("ProxyURL") Is Nothing Then

strProxyURL = ConfigurationManager.AppSettings.Item(



"ProxyURL").ToString.TrimEnd If


If Not ConfigurationManager.AppSettings.Item("ProxyPort") Is Nothing Then

iProxyPort =


CInt(ConfigurationManager.AppSettings.Item("ProxyPort").ToString.Trim)End If




Dim strSMSDialerConnectionName As String = ConfigurationManager.AppSettings("SMSDialerConnectionName")Dim iAvailConType As Integer = DetectConnection()If iAvailConType = enmConnectionType.NOTCONNECTED Then ' If not connected,


'Then detect the Modem connection and Dialp up.


If Not String.IsNullOrEmpty(strSMSDialerConnectionName) Then




Dim chSplit() As Char = {";"}Dim strDialeConnections() As String = strSMSDialerConnectionName.Split(chSplit)If strDialeConnections.Length > 0 Then



For i = 0 To strDialeConnections.Length - 1If DialupConnection(strDialeConnections(i)) Then

iAvailConType = enmConnectionType.MODEM

strProxyURL =

iProxyPort = 0


String.EmptyIf Not ConfigurationManager.AppSettings.Item("DailUpProxyURL") Is Nothing Then

strProxyURL = ConfigurationManager.AppSettings.Item(


"DailUpProxyURL").ToString.TrimEnd If


If Not ConfigurationManager.AppSettings.Item("DailUpProxyPort") Is Nothing Then

iProxyPort =


CInt(ConfigurationManager.AppSettings.Item("DailUpProxyPort").ToString.Trim)End If


Exit For


End If


Next


End If


End If


End If


If iAvailConType <> enmConnectionType.NOTCONNECTED Then



objWebRequest =


Dim bytesToSend As Byte() = Encoding.UTF8.GetBytes(stringPost)Dim strSMSApi As String = ConfigurationManager.AppSettings.Item("SMSApi").ToStringDirectCast(WebRequest.Create((strSMSApi & "?") + stringPost.ToString()), HttpWebRequest)'add eventvwr : laxman

EventLog.WriteEntry(


"SENDSMS.strSMSApi ", (strSMSApi & "?") + stringPost.ToString())'(strSMSApi & "?") + stringPost.ToString()

objWebRequest.Method =

"POST"


If (Not String.IsNullOrEmpty(strProxyURL.Trim)) Then

objProxy =

objProxy.Credentials = CredentialCache.DefaultNetworkCredentials

objWebRequest.Proxy = objProxy


New WebProxy(strProxyURL, iProxyPort)End If

objWebRequest.ContentLength = bytesToSend.Length

objWebRequest.ContentType =

"application/x-www-form-urlencoded"

objStreamWriter =

objStreamWriter.Write(stringPost)

objStreamWriter.Flush()

objStreamWriter.Close()

objWebResponse =

objStreamReader =

strReturnValue = objStreamReader.ReadToEnd()

objStreamReader.Close()

New StreamWriter(objWebRequest.GetRequestStream())DirectCast(objWebRequest.GetResponse(), HttpWebResponse)New StreamReader(objWebResponse.GetResponseStream())

0
Priya Linge

Priya Linge

NA 5k 708.3k 13y
Hi Ram,

Please see below link.

http://code.google.com/p/duplicati/issues/detail?id=378.

Hope it will help you to solve the error.

Thanks.
0
Rams

Rams

NA 44 36.3k 13y
Hi,

Thanks for the reply.. we tested the same service in our network..it is showing succesfull..but the client is using a proxy server which i think is creating a problem..
0
Zoran Horvat

Zoran Horvat

NA 5.7k 516.3k 13y
Can you read HttpWebRequest's Expect property and paste it here? That should be the root cause of the problem - web request is sending something in the Expect HTTP header and remote Web server is unable to comply so it responds with 417 error.

Give us precise Expect value you're sending.

Zoran