Community
Navisworks API
Welcome to Autodesk’s Navisworks API Forums. Share your knowledge, ask questions, and explore popular Navisworks API topics.
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Localizing Navisworks plugin ribbon interface and forms

1 REPLY 1
Reply
Message 1 of 2
Anonymous
496 Views, 1 Reply

Localizing Navisworks plugin ribbon interface and forms

Hello Sirs,

I had fall into problem with localizing Navisworks plugin. I need to translate c# plugin string resources into Russian language. I got Russian strings in ribbon buttons, but I can't get it in simple windows form that created after pressing the ribbon button. I tried several ways: put, for example, button identifier "button1.Text" into Form1.ru.resx and plugin_ru-RU.name without any success. Form is appeared with english text although ribbon button text is Russian string that comes from *.name file. Also I tried standard c# way:

 

CultureInfo ci = new CultureInfo("ru-RU");
Thread.CurrentThread.CurrentUICulture = ci;
ResourceManager rm = new ResourceManager("Plugin1.Localization", Assembly.GetExecutingAssembly());
MessageBox.Show(rm.GetString("String1"));
MessageBox.Show(rm.GetString("String1",ci));

without success too...
Would you be so kind to explain how to make localization in Naviswoks plugin in the right way?

With regards, Sergey.

1 REPLY 1
Message 2 of 2
xiaodong_liang
in reply to: Anonymous

Hi,

the *.name file is for the text of custom ribbon only.

As to your own form/dialog, I think it is a common usage. When I googled by "C# localization", it returns many articles. Or you meant the same code in pure .NET project (no related with Navisworks API) cannot work in a Navisworks plugin? If yes, could you provide a sample and necessary snapshots of the failure you got? Thank you.

Can't find what you're looking for? Ask the community or share your knowledge.

Post to forums  

Rail Community


 

Autodesk Design & Make Report