-
Notifications
You must be signed in to change notification settings - Fork 0
/
Surface.cs
42 lines (39 loc) · 1.1 KB
/
Surface.cs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
using Autodesk.Revit.DB;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Text.RegularExpressions;
using System.Threading.Tasks;
namespace WorkApp
{
public class Surface
{
public Element el {get;set;}
public int room_id { get; set; }
public string typeName { get; set; }
public string sostav { get; set; }
public double Area { get; set; }
public string sur_func { get; set; }
public Surface(Element el)
{
this.el = el;
typeName= el.GetType().Name;
try
{
room_id = el.LookupParameter("Room_ID").AsInteger();
}
catch (Exception)
{
var msg = new Autodesk.Revit.UI.TaskDialog("Info");
msg.MainInstruction = "Добавьте параметр Room_ID";
msg.Show();
throw;
}
Area = el.get_Parameter(BuiltInParameter.HOST_AREA_COMPUTED).AsDouble();
}
public void setParams()
{
}
}
}