In Revit 2013, view types can be copied and edited as new types. ViewFamilyType class is added for this change.
You need to use ViewPlan.Create method instead of Create.NewViewPlan method which is now obsolete . You can find a view type in very similar ways to find types of other families.
Here is an code snippet creating a plan view called “Level Test”. It finds a view type called “Floor Plan” using an element filter and LINQ query and passing its element Id.
// Using a filter and LINQ clause to find a view type called "Floor Plan"
IEnumerable<ViewFamilyType> viewFamilyTypes = from elem in new
let type = elem as ViewFamilyType
where type.ViewFamily == ViewFamily.FloorPlan
ViewFamilyType viewFamilyType = null;
foreach(ViewFamilyType familyType in viewFamilyTypes)
if (familyType.Name == "Floor Plan")
viewFamilyType = familyType;
// Creates a plan view for the view type found
Autodesk.Revit.DB.ViewPlan viewPlan =
Autodesk.Revit.DB.ViewPlan.Create(activeDoc, viewFamilyType.Id, level.Id);
viewPlan.Name = "Level Test";