Digital Workshop

Welcome to the Digital Workshop Message Boards
It is currently December 23rd, 2024, 1:33 am

All times are UTC [ DST ]




Post new topic Reply to topic  [ 10 posts ] 
Author Message
 Post subject: Read the OS Language
PostPosted: June 5th, 2007, 11:02 am 
Offline

Joined: December 14th, 2004, 5:08 pm
Posts: 55
Location: Holland
Opus: version 8.0
OS: XP, Vista, Windows7, Windows8
System: Intel Corei7-2600 CPU 3.400GHz
I need to know what OS Language is installed on the user his computer. Is there a way to do this , maybe to read a certain DLL?

Cheers

Jim


Top
 Profile  
 
 Post subject:
PostPosted: June 5th, 2007, 12:48 pm 
Offline

Joined: January 10th, 2005, 11:08 am
Posts: 63
Location: Birmingham, United Kingdom
Opus: All between ver Pro XE 4.5 and Ver 9.62
OS: Windows XP Pro SP3
System: Intel Core2 Duo 2.67Ghz, Matrox Millennium G550 dual head graphics card
Why not use the variable SYSTEM_OPERATING_SYS, which is a system default variable in the General properties of a production?
Regards

_________________
Andy Thompson
Opus Pro XE 4.5, Pro 5.5, Ver 6, Ver 7, Ver 8.6, Ver 9.62
Windows XP Pro on an Intel Core2 Duo 2.67Ghz with a Matrox Millennium G550 LP PCIe dual-head card.


Top
 Profile Visit website  
 
 Post subject:
PostPosted: June 5th, 2007, 7:28 pm 
Offline

Joined: December 14th, 2004, 5:08 pm
Posts: 55
Location: Holland
Opus: version 8.0
OS: XP, Vista, Windows7, Windows8
System: Intel Corei7-2600 CPU 3.400GHz
Don't think that's working, var S_O_S shows only XP or WIN98 and so on, so would that be XP the American language version or the Italian or the UK version?

Anyone nows if something could be read from the user32.dll?

Cheers

Jim


Top
 Profile  
 
 Post subject:
PostPosted: June 5th, 2007, 9:39 pm 
Offline

Joined: November 25th, 2004, 1:24 pm
Posts: 512
Location: Scotland
Opus: 9.75
OS: Win 10
System: Asus i7-7700K 16Gb
Perhaps its held in the registry somewhere????

_________________
Whoever designed this, never actually used it!


Top
 Profile  
 
 Post subject:
PostPosted: June 5th, 2007, 11:27 pm 
Offline
Godlike
Godlike
User avatar

Joined: March 21st, 2007, 10:44 am
Posts: 3188
Location: UK
Opus: Evolution
If you use the language bar, then this creates a registry entry, but the locale set in the regional settings doesn't appear to be.

I've modified the DLL that I'm working on to call the locale using a the C++ command GetThreadLocale(). Use the attached zip file to see how it works. Note this command gets the locale for the current thread and therefore, you'd need to restart the publication / Opus to see any changes that you make in the R&L Options.

The DLL returns the LCID Decimal value and compares it with a list of known values taken from this site: http://www.science.co.il/Language/Locale-Codes.asp

Hope this helps,

Mack


You do not have the required permissions to view the files attached to this post.

_________________
When you have explored all avenues of possibilities, what ever remains, how ever improbable, must be the answer.

Interactive Solutions for Business & Education
Learn Anywhere. Learn Anytime.

www.interaktiv.co.uk
+44 (0) 1395 548057


Top
 Profile Visit website  
 
 Post subject:
PostPosted: June 6th, 2007, 12:08 am 
Offline

Joined: October 26th, 2004, 10:23 am
Posts: 666
Location: Digital Workshop
If you're using Opus 6 you could just use the GetLocale() script function. The help details the possible return values.

_________________
ddww Opus Developer


Top
 Profile Visit website  
 
 Post subject:
PostPosted: June 6th, 2007, 11:42 am 
Offline

Joined: December 14th, 2004, 5:08 pm
Posts: 55
Location: Holland
Opus: version 8.0
OS: XP, Vista, Windows7, Windows8
System: Intel Corei7-2600 CPU 3.400GHz
Thanks Duncan this was just what I was looking for....

Cheers

Jim


Top
 Profile  
 
 Post subject:
PostPosted: June 6th, 2007, 1:36 pm 
Offline

Joined: October 26th, 2004, 10:23 am
Posts: 666
Location: Digital Workshop
I have just seen that the help includes the wrong table for the return codes from GetLocale() - it actually returns the three letter abbreviation for the country based on ISO Standard 3166.

Please see this page for a list of codes (note that Windows does not necessarily support all these languages). The help will be updated to match.

I will also update the GetLocale() function to allow you to retrieve the two character language and country information, should you need it. This change will be included in the upcoming public release of Opus 6.

_________________
ddww Opus Developer


Top
 Profile Visit website  
 
 Post subject:
PostPosted: June 6th, 2007, 9:01 pm 
Offline
Godlike
Godlike

Joined: November 12th, 2005, 1:56 am
Posts: 1474
Location: SFBay Area
Opus: OpusPro v9.0x, & Evol.
OS: Vista32
System: Core 2 duo 2Ghz, RAM 3GB, Nvidia Go 7700 - laptop
Jim

You might noodle around on MSDN links...
http://tinyurl.com/3xzup6 = http: // msdn2 .microsoft . com/en-us/library/ms775232 ....... ( opens on "Display" or monitor info page )

http://tinyurl.com/2vl3fa searches on MSDN for: determine windows version
http://support.microsoft.com/kb/304283 one search result article


I will hope you can find some parameter easily accessed by Opus reading the Registry or other.

_________________
_good things come to those who wait(0)_


Top
 Profile  
 
 Post subject:
PostPosted: June 3rd, 2008, 1:01 pm 
Offline

Joined: May 25th, 2008, 4:57 pm
Posts: 355
Location: Ireland
Opus: Pro 9.75
OS: Windows 10
System: MacBook Pro (Intel 2020)
Excellent feature, I didn't even know it was in there, thanks DW.


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 10 posts ] 

All times are UTC [ DST ]


Who is online

Users browsing this forum: No registered users and 8 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group