Create Sheets

I’m trying to create sheets in Revit from sheet name and number data from an excel file that has been preformatted. Here’s the code I’m trying to use (after RiR boilerplate), but it is not working:

doc = RhinoInside.Revit.Revit.ActiveDBDocument
sheets = []

if RUN:
    t = Autodesk.Revit.DB.Transaction(doc, 'Add Sheets')
    t.Start()
    for i in range(len(sheetNumbers)):
        newSheet = Autodesk.Revit.DB.ViewSheet.Create(doc, titleblock.Id)
        newSheet.SheetNumber = sheetNumbers[i]
        newSheet.Name = sheetNames[i]
        sheets.append(newsheet)
    t.Commit()

a = sheets

The error that I am seeing is: "Runtime error (InternalException): A managed exception was thrown by Revit or by one of its external applications.

Traceback:
line 23, in script"

(line 23 is the line where the sheet is being initially created – newSheet = Autodesk.Revit.DB.ViewSheet.Create(doc, titleblock.Id))

I have confirmed multiple times that the family that I am giving the ViewSheet.Create is in fact a Titleblock Family.