ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Macro & runtime problem (https://www.excelbanter.com/excel-programming/323269-macro-runtime-problem.html)

Peter[_53_]

Macro & runtime problem
 
Hi,

I have a macro as shown below:

Dim x As Long

x = Application.WorksheetFunction.Match(ActiveSheet.Ra nge("AT1") _
, Worksheets("Wall data").Range("B:B"), 0)
Worksheets("Wall data").Cells(x, 17).Value = ActiveSheet.Cells(1,
47).Value

Worksheets("Wall data").Cells(x, 18).Value = ActiveSheet.Cells(2,
47).Value

Worksheets("Wall data").Cells(x, 19).Value = ActiveSheet.Cells(3,
47).Value

Worksheets("Wall data").Cells(x, 20).Value = ActiveSheet.Cells(4,
47).Value

Worksheets("Wall data").Cells(x, 21).Value = ActiveSheet.Cells(5,
47).Value

Worksheets("Wall data").Cells(x, 22).Value = ActiveSheet.Cells(6,
47).Value

Worksheets("Wall data").Cells(x, 24).Value = ActiveSheet.Cells(8,
47).Value

Worksheets("Wall data").Cells(x, 23).Value = ActiveSheet.Cells(7,
47).Value

Worksheets("Wall data").Cells(x, 25).Value = ActiveSheet.Cells(10,
47).Value

Worksheets("Wall data").Cells(x, 26).Value = ActiveSheet.Cells(9,
47).Value

Worksheets("Wall data").Cells(x, 27).Value = ActiveSheet.Cells(11,
47).Value


End Sub


I can run it OK from my PC, but one of my colleagues gets the
following message when he tries to run it:

Run Time error 1004
Unable to get MatchProperty of the worksheet function class

Can anyone please advise what this message means and/or what isn't
happening?

Cheers

Peter


All times are GMT +1. The time now is 03:04 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com