Ureader.com  
Microsoft software help and Community
   home   |   control panel login   |   archive   |  
 
Word
application.errors
conversions
docmanagement
drawing.graphics
formatting.longdocs
international
internet.assistant
mail
mailmerge.fields
menustoolbars
newusers
numbering
oleinterop
pagelayout
printingfonts
setup.networking
spelling.grammar
tables
vba.addins
vba.beginners
vba.customization
vba.general
vba.userforms
web.authoring
word6-7macros
word97vba
  
 
date: Thu, 16 Aug 2007 17:03:14 +0200,    group: microsoft.public.word.vba.customization        back       


Macro that worked well in Word XP, but does not in Word 2007   
Good morning,
I am using WIN XP SP2, Word  XP and Word 2007 fully updated, all in french 
versions.
French Windows uses normally the comma as decimal separator and you need it 
if you want to calculate. Entering numbers with decimals in a Word table is 
easier if the decimal point key translates your command in the comma.
I used this macro in Word XP, stored in Normal.dot :
------------------
Public Sub PointOuVirgule()
CustomizationContext = NormalTemplate
If KeyBindings(1).command = Chr(46) Then
KeyBindings.Add KeyCategory:=wdKeyCategorySymbol, 
KeyCode:=BuildKeyCode(wdKeyNumericDecimal), command:=Chr(44)
StatusBar = "Tu as la virgule"
Else
KeyBindings.Add KeyCategory:=wdKeyCategorySymbol, 
KeyCode:=BuildKeyCode(wdKeyNumericDecimal), command:=Chr(46)
StatusBar = "Tu as le point"
End If
End Sub
------------------
Char(46) is the decimal point, Chr(44) is the comma.
It worked very well in Word XP but if I try to use it in Word 2007 I always 
get  the character 255, that is ÿ , and I am stuck to it. To get back to the 
normal behaviour and retrieve the decimal point I am obliged to go the 
customization of the keyboard and hit "Reset" .
Has anybody a cure for that ?
Thanks
-- 
Aeronav
date: Thu, 16 Aug 2007 17:03:14 +0200   author:   Aeronav

Re: Macro that worked well in Word XP, but does not in Word 2007   
La réponse m'a été fournie dans le groupe microsoft.public.fr.word
Merci
date: Wed, 22 Aug 2007 18:02:39 +0200   author:   Aeronav

Google
 
Web ureader.com


    COPYRIGHT 2007, YARDI TECHNOLOGY LIMITED, ALL RIGHT RESERVE  |   contact us