Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.newusers
|
|||
|
|||
![]()
Hi,
I use Excel 2010 on a Windows 7 Home 64-bit system with the Russian language pack installed (my wife is Russian and also uses this computer). When I create a new spreadsheet from Windows Explorer using File New Excel spreadsheet (or from the context menu), the spreadsheet has the tabs named in Russia, so instead of "Sheet", it uses "List". I have UK English, US English and Russian installed according to the File Options Languages settings, with UK English set as the default language and keyboard (the US English and Russian keyboards aren't enabled, just the spelling and grammar rules for these). Windows is set to use United Kingdom as its location in the Region and Language applet in the Control Panel. Does anyone know how I can correct this behaviour please? Best regards, Richard Watt |
#2
![]() |
|||
|
|||
![]()
Sub SetLanguageFormat()
'Declarations Dim cell As Range Dim f As String Const LCID As String = "[$-0409]" Dim reg 'As RegExp 'Removed for late binding 'Setup regular expression Set reg = CreateObject("vbscript.regexp") reg.Global = True reg.IgnoreCase = True reg.Pattern = "\[\$\-+[\w]*[\w]\]" 'Loop through all cells and change the date formate For Each cell In ActiveSheet.UsedRange.Cells If IsDate(cell.Value) Then f = cell.NumberFormat If reg.Execute(f).Count 0 Then 'Language is set so replace it f = reg.Replace(f, LCID) Else 'Langauge is not set so add it f = LCID & f End If cell.NumberFormat = f End If Next End Sub Let me know if this was useful. Regards, Jerry |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Add "paste values" to right-click shortcut menu-how do? Excel 2010 | Excel Programming | |||
Visual Studio 2010 (Creating Excel DLL) "warning" no build | Excel Programming | |||
Excel - Golf - how to display "-2" as "2 Under" or "4"as "+4" or "4 Over" in a calculation cell | Excel Discussion (Misc queries) | |||
Excel "Move or Copy" and "Delete" sheet functions | Excel Worksheet Functions | |||
Excel 2003 VBA - "Maximizing" Window & "Calculating" Workbook | Excel Programming |