I am having trouble defining a range.

I am writing in word vba referencing an excel spreadsheet
Have included the relevant parts to my code

Dim MaxNo As Long
Dim xlApp As New Excel.Application
Dim xlWB As New Excel.Workbook
Dim MyRange1 As Range
Set xlWB = xlApp.Workbooks("Job Data Base NEW.xls")
Set MyRange1 = xlWB.Sheets("F09").Range("P:P")
MaxNo = xlApp.Application.WorksheetFunction.Max(MyRange1)
MsgBox (MaxNo)
I am having trouble with the line set myrange1 =

Hope someone can help