So I made a project with two languages. I set Localizable to true, then chose the language I wanted (Arabic), translated everything, saved, then to English, and did the same.
When I debug, the program works fine and transfers between the two languages correctly. The only problem is that after publishing, it doesn't do that, and stays on the Default which is mostly in Arabic.
Can any body tell me what to do?
Of coarse there is some code, please tell me if it is necessary so I could post it.
14 Replies - 926 Views - Last Post: 27 February 2016 - 03:48 AM
#1
Localizable Project stays on default after publishing
Posted 25 February 2016 - 02:22 AM
Replies To: Localizable Project stays on default after publishing
#2
Re: Localizable Project stays on default after publishing
Posted 25 February 2016 - 05:15 AM
Hi
I have had similar problems with other systems like this
Do you have resource files for each language and are these set to be localcopy = true???
Sounds like its defaulting as it cannot find the other language resource file
Hope this helps
I have had similar problems with other systems like this
Do you have resource files for each language and are these set to be localcopy = true???
Sounds like its defaulting as it cannot find the other language resource file
Hope this helps
#3
Re: Localizable Project stays on default after publishing
Posted 25 February 2016 - 05:43 AM
Ummmmmmmmmmmmm ... I have .resx files for each form per each language if that's what you mean?
But I don't know where to find 'localcopy'.
When I publish, I use this way ... Then I got a problem that the program can't find my MS Access DataBase, so I went to the setup project -> Right click -> add -> File, And I navigated to my original project's folder and added everything in there. So it's like I manually added them? or not?
This is my first program and I'm honestly confused.
All help appreciated.
Thanks
/>/>
But I don't know where to find 'localcopy'.
When I publish, I use this way ... Then I got a problem that the program can't find my MS Access DataBase, so I went to the setup project -> Right click -> add -> File, And I navigated to my original project's folder and added everything in there. So it's like I manually added them? or not?
This is my first program and I'm honestly confused.
All help appreciated.
Thanks
This post has been edited by ZeeSam: 25 February 2016 - 05:44 AM
#4
Re: Localizable Project stays on default after publishing
Posted 25 February 2016 - 06:00 AM
Localization is a fairly big thing for a first project, colour me impressed.
The files will show in the Solution Explorer window (usually docked to the right it shows all the project files). View the Properties of each file and make sure that the "Copy to Output Directory" property is set to "copy if newer" or "copy always" depending on your requirements
The files will show in the Solution Explorer window (usually docked to the right it shows all the project files). View the Properties of each file and make sure that the "Copy to Output Directory" property is set to "copy if newer" or "copy always" depending on your requirements
#5
Re: Localizable Project stays on default after publishing
Posted 25 February 2016 - 06:08 AM
Hhhhhhhhhhhhhhhhhh, Thanks! You'd probably shoot me if you saw what I got myself tangled into on this project for it being a first.
They are all set to copy always. Any other suggestions?
They are all set to copy always. Any other suggestions?
#6
Re: Localizable Project stays on default after publishing
Posted 25 February 2016 - 06:27 AM
where is code looking for files? where have you put them?
#7
Re: Localizable Project stays on default after publishing
Posted 25 February 2016 - 06:35 AM
Okay, I had a variable in Module1 named language as Integer.
If its value=1 then the language is Arabic. if language=2 then English.
So whenever I want to open a form, I use this:
The variable changes when I open LanguageForm and choose the language I want and click OkayButton
This is the way that was in the tutorial I followed. Remember that it works while debugging, but doesn't after publish.
If its value=1 then the language is Arabic. if language=2 then English.
So whenever I want to open a form, I use this:
If Module1.language = 1 Then
Panel1.Controls.Clear()
CurrentThread.CurrentUICulture = New CultureInfo("ar")
Dim frmArabic As New LanguagesForm
frmArabic.ShowDialog()
ElseIf Module1.language = 2 Then
Panel1.Controls.Clear()
CurrentThread.CurrentUICulture = New CultureInfo("en")
Dim frmEnglish As New LanguagesForm
frmEnglish.ShowDialog()
End If
The variable changes when I open LanguageForm and choose the language I want and click OkayButton
This is the way that was in the tutorial I followed. Remember that it works while debugging, but doesn't after publish.
This post has been edited by ZeeSam: 25 February 2016 - 06:37 AM
#8
Re: Localizable Project stays on default after publishing
Posted 25 February 2016 - 06:38 AM
where are the resx files located in your project?
#9
Re: Localizable Project stays on default after publishing
Posted 25 February 2016 - 06:54 AM
Two locations:
1. ..\FamilyTreeBuilder\FamilyTreeBuilder\ All the files that are resx
2. ..\FamilyTreeBuilder\FamilyTreeBuilder\bin\Debug\ All the files that are resx
Also .. This is how they show in the project .. since I'm not sure which one you're asking about:
1. ..\FamilyTreeBuilder\FamilyTreeBuilder\ All the files that are resx
2. ..\FamilyTreeBuilder\FamilyTreeBuilder\bin\Debug\ All the files that are resx
Also .. This is how they show in the project .. since I'm not sure which one you're asking about:
#10
Re: Localizable Project stays on default after publishing
Posted 25 February 2016 - 07:27 AM
I'm not positive with WinForms but I know for a fact that in ASP.Net there is a particular folder that the resx files have to go into. I'll do a little research and get back to you...
Edit: It seems as though you need to set the Localization Property of each control and the the resx are auto generated so you shouldn't need to reference paths... is this how you have done this?
Edit: It seems as though you need to set the Localization Property of each control and the the resx are auto generated so you shouldn't need to reference paths... is this how you have done this?
This post has been edited by TechnoBear: 25 February 2016 - 07:30 AM
#11
Re: Localizable Project stays on default after publishing
Posted 25 February 2016 - 07:30 AM
I appreciate it... Thanks 😉
#12
Re: Localizable Project stays on default after publishing
Posted 25 February 2016 - 11:17 AM
Yes .. That's right .. That's how I did it
#13
Re: Localizable Project stays on default after publishing
Posted 25 February 2016 - 11:26 AM
Then I'm afraid I'm out of my depth here, sorry.
#14
Re: Localizable Project stays on default after publishing
Posted 25 February 2016 - 11:54 AM
It's okay .. thanks though.
Anybody else?
Anybody else?
#15
Re: Localizable Project stays on default after publishing
Posted 27 February 2016 - 03:48 AM
Is anybody even reading this anymore?
Page 1 of 1

New Topic/Question
Reply


MultiQuote



|