Could someone please tell me why this Macro wont work?

asked 2017-07-13 01:42:47 +0200

OfficeGuy87 gravatar image

Every time I click on this "Read" Macro, I receive a error. This is the error:

col_predefinito = ThisComponent.Sheets.getByName("edit").getCellRangeByName(trovato).String

It also mentions something about FullReadCode. Please help. Thanks so much.

edit retag flag offensive close merge delete


Hello @OfficeGuy87,

getCellRangeByName() expects either a string address in the form "A1:B2" or "$A$1", or a predefined cell range name such as "My_Named_CellRange_2".

Please inspect the value of <trovato>.

And calling String for a CellRange is only valid if the range contains 1 cell only, but not if the range contains multiple cells.

librebel gravatar imagelibrebel ( 2017-07-13 01:56:11 +0200 )edit