Home |
Search |
Today's Posts |
#1
|
|||
|
|||
runtime error 1004
I'm having this problem with this code when i try to run this in
spanish version but no in english version: Public Function gf_CopyPasteData(s_range As String, s_range2 As String, i_start_sheet_index As Integer, i_end_sheet_index As Integer) As Integer 'copies data from sheet one sheet to another sheet If CInt(Range(s_range).Count) = CInt(Range(s_range2).Count) Then Sheets(i_start_sheet_index).Range(s_range).Copy _ Destination:=Sheets(i_end_sheet_index).Range(s_ran ge2) 'validation passed, both ranges are of the same size gf_CopyPasteData = 0 Else 'validation failed, both ranges are a different size gf_CopyPasteData = 1 End If End Function somebody said that the problem is because tha row in english is R and in spanish is L i want to know how can i solve this thanks |
#2
|
|||
|
|||
I'm not that au fait with international variations, but perhaps you could try passing the ranges as 'Range' type rather than as 'String' type, so instead of ---Range(s_range).--- and ---Range(s_Range2).--- you would simply use ---s_range.--- and --s_Range2.---
This should mean it won't matter how the address of the ranges turn out to be notated in a 'foreign' version. BizMark |
#3
|
|||
|
|||
You may want to try the Spanish newsgroups:
microsoft.public.es.excel And when you post there, you may want to include your function call that fails. valdesd wrote: I'm having this problem with this code when i try to run this in spanish version but no in english version: Public Function gf_CopyPasteData(s_range As String, s_range2 As String, i_start_sheet_index As Integer, i_end_sheet_index As Integer) As Integer 'copies data from sheet one sheet to another sheet If CInt(Range(s_range).Count) = CInt(Range(s_range2).Count) Then Sheets(i_start_sheet_index).Range(s_range).Copy _ Destination:=Sheets(i_end_sheet_index).Range(s_ran ge2) 'validation passed, both ranges are of the same size gf_CopyPasteData = 0 Else 'validation failed, both ranges are a different size gf_CopyPasteData = 1 End If End Function somebody said that the problem is because tha row in english is R and in spanish is L i want to know how can i solve this thanks -- Dave Peterson |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Runtime error '1004' General ODBC error | New Users to Excel | |||
runtime error '6' overflow | Setting up and Configuration of Excel | |||
Help: runtime error - Method seriescollection object_chart failed | Charts and Charting in Excel | |||
Runtime error for macro that works in workbook created in | Excel Discussion (Misc queries) | |||
Excel 2003 Help Runtime Error | Excel Discussion (Misc queries) |