View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
michael.beckinsale michael.beckinsale is offline
external usenet poster
 
Posts: 274
Default setting LinkedCell using VBA

Hi All,

Can anybody tell me why this doesn't work? Excel 2003

Sub testcbx()
Dim cb As Shape
Dim RowNo As Integer
On Error Resume Next
RowNo = 12
For Each cb In ActiveSheet.Shapes
If cb.Name Like "ComboBox*" Then
cb.LinkedCell = "Petty Cash Expenses!H" & RowNo
End If
RowNo = RowNo + 1
Next

TIA

Regards