G
Giulio
I have an excel macro under microsoft excel 2003 sp2 in spanish version that
have a strange behaviour.
the macro is this:
Sub Macro1()
Dim keyinizio As String
keyinizio = "START"
Dim myExcel As Object
Set myExcel = CreateObject("Excel.Application")
myExcel.Visible = True
myExcel.WindowState = -4143
myExcel.Workbooks.Add
myExcel.ActiveWorkbook.Names.Add Name:=keyinizio,
RefersToR1C1:="=Hoja1!R1C1:R1C1"
MsgBox myExcel.ActiveWorkbook.Names(1)
myExcel.Goto (keyinizio)
End Sub
The message box return this value: =Hoja1!'R1C1':Hoja1!'R1C1'
So the GoTo instruction rise an error "Run-time error 1004: not valid
reference"
The correct value that expect in ActiveWorkbook.Names should be =Hoja1!'$A$1'
This behaviour happend only spanish version, with the italin and english
version all works fine
Thanks
Giulio
have a strange behaviour.
the macro is this:
Sub Macro1()
Dim keyinizio As String
keyinizio = "START"
Dim myExcel As Object
Set myExcel = CreateObject("Excel.Application")
myExcel.Visible = True
myExcel.WindowState = -4143
myExcel.Workbooks.Add
myExcel.ActiveWorkbook.Names.Add Name:=keyinizio,
RefersToR1C1:="=Hoja1!R1C1:R1C1"
MsgBox myExcel.ActiveWorkbook.Names(1)
myExcel.Goto (keyinizio)
End Sub
The message box return this value: =Hoja1!'R1C1':Hoja1!'R1C1'
So the GoTo instruction rise an error "Run-time error 1004: not valid
reference"
The correct value that expect in ActiveWorkbook.Names should be =Hoja1!'$A$1'
This behaviour happend only spanish version, with the italin and english
version all works fine
Thanks
Giulio