Files
2024-12-12 09:51:40 +01:00

84 lines
6.6 KiB
Plaintext

{\rtf1\fbidis\ansi\ansicpg936\deff0\deflang1033\deflangfe2052{\fonttbl{\f0\fswiss\fprq2\fcharset0 Arial;}{\f1\froman\fprq2\fcharset0 Times New Roman;}{\f2\fswiss\fprq2\fcharset0 Verdana;}{\f3\fnil\fprq1\fcharset134 Fixedsys;}{\f4\fmodern\fprq1\fcharset0 Courier New;}}
{\colortbl ;\red0\green128\blue128;\red0\green0\blue255;}
\viewkind4\uc1\pard\ltrpar\b\f0\fs20 Application:\b0 GridCreation\line\b Revit Platform:\b0 All\line\b Revit Version:\b0 2010.0\line\b First Released For:\b0 2009.0\line\b Last Modified:\b0 02/26/2008\line\b Modified By:\b0 LL Autodesk\line\b Programming Language:\b0 C#\line\b Skill Level:\b0 High\line\b Category:\b0 Elements\line\b Type:\b0 ExternalCommand\line\line\b Subject:\b0 Create Grid.\line\b Summary:\b0 \line This sample shows how to create grids and modify grids\rquote properties through Revit API.\i\f1\par
\i0\par
\b\f0 Classes:\b0 \par
\pard\ltrpar\fi180\li180\lang1036 Autodesk.Revit.IExternalCommand\f1\par
\f0 Autodesk.Revit.Document\par
Autodesk.Revit.Elements\f1\par
\f0 Autodesk.Revit.Geometry\f1\par
\par
\pard\ltrpar\lang1033\b\f0 Project Files:\b0 \i\par
\i0 Command.cs\f1\par
\pard\ltrpar\li360\lang1036\f0 It contains the class Command which inherits from interface IExternalCommand and implements the Execute method.\f1\par
\pard\ltrpar\par
\lang1033\f0 CreateGridsData\par
\pard\ltrpar\li360\lang1036 Base class of grid creation data classes which contains common data and operations.\par
\pard\ltrpar\f1\par
\lang1033\f0 GridCreationOptionData.cs\f1\par
\pard\ltrpar\li360\lang1036\f0 Data\lang1033 class \lang1036 which stores the information of the way to create grids.\lang1033\f1\par
\pard\ltrpar\par
\f0 GridCreationOptionForm.cs\f1\par
\pard\ltrpar\li360\lang1036\f0 It contains a dialog which lets user choose the way to create grids.\lang1033\f1\par
\pard\ltrpar\par
\f0 CreateWithSeletedCurvesData.cs\f1\par
\pard\ltrpar\li360\lang1036\f0 Data\lang1033 class \lang1036 which stores the information for creating grids with selected lines/arcs.\lang1033\f1\par
\pard\ltrpar\par
\f0 CreateWithSelectedCurvesForm.cs\f1\par
\pard\ltrpar\li360\lang1036\f0 It contains a dialog which provides the options of creating grids with selected lines/arcs.\lang1033\f1\par
\pard\ltrpar\par
\f0 CreateOrthogonalGridsData.cs\f1\par
\pard\ltrpar\li360\lang1036\f0 Data\lang1033 class \lang1036 which stores information for creating orthogonal grids.\lang1033\f1\par
\pard\ltrpar\par
\f0 CreateOrthogonalGridsForm.cs\f1\par
\pard\ltrpar\li360\lang1036\f0 It contains a dialog which provides the options of creating orthogonal grids.\lang1033\f1\par
\pard\ltrpar\par
\f0 CreateRadialAndArcGridsData.cs\f1\par
\pard\ltrpar\li360\lang1036\f0 Data\lang1033 class\lang1036 which stores information for creating radial and arc grids.\f1\par
\lang1033\par
\pard\ltrpar\f0 CreateRadialAndArcGridsForm.cs\f1\par
\pard\ltrpar\li360\lang1036\f0 It contains a dialog which provides the options of creating radial and arc grids.\lang1033\f1\par
\pard\ltrpar\par
\f0 Unit.cs\f1\par
\pard\ltrpar\li360\f0 It defines a static class Unit to convert unit from display unit type to Revit API\rquote s internal unit.\f1\par
\pard\ltrpar\par
\f0 EnumsAndValues.cs\f1\par
\pard\ltrpar\li360\tx720\f0 This file contains two Enumerations and one class.\f1\par
\pard\ltrpar\fi-420\li1200\tx720\tx1200\f2 -\tab\f0 CreateMode\cf1\lang1024\f3\fs18 \cf0\lang1033\f0\fs20 enumeration lists the ways to create grids.\f1\par
\pard\ltrpar\fi-420\li1200\f2 -\tab\f0 BubbleLocation enumeration lists bubble locations of grids.\f1\par
\f2 -\tab\f0 Class Values contains common const values used in transforming between degrees and radians.\f1\par
\pard\ltrpar\par
\f0 Validation.cs\lang1036\f1\par
\pard\ltrpar\li360\f0 This file contains static functions to validate input data before creating grids.\f1\par
\pard\ltrpar\lang1033\b\par
\f0 Description:\b0 \f1\par
\f0 This sample provides following functionalities.\f1\par
\pard\ltrpar\fi-360\li360\tx360\f0 -\tab Let user create grids on the base of the selected lines/arcs.\f1\par
\f0 -\tab Let user generate orthogonal linear grids with specified origin, spacing of X and Y directions, numbers of X and Y direction grids. \f1\par
\f0 -\tab Let user generate radial and arc grids with specified center, span of grids, spacing between concentric arcs and number of rays in the specified span. Even the user can specify radius of the first arc grid and distance from center to the start points of radial grids. \par
\pard\ltrpar\fi-360\li360 -\tab Let user set the label for the first grid like A or 1 and set the location of the bubble for grids to be created.\par
-\tab The length units within UI should accord with current project unit setting.\f1\par
\pard\ltrpar\par
\b\f0 Instructions:\cf2\b0 \f1\par
\cf0\f0 Open Revit application and execute the command.\par
\pard\ltrpar\fi-360\li360\tx360 1.\tab Create grids with selected lines/arcs.\par
\pard\ltrpar\li765 a. Select some lines/arcs in current project.\f1\par
\f0 b. Execute the command.\f1\par
\pard\ltrpar\fi-400\li1166\f0 c. Check the option \ldblquote Create grids with selected lines or arcs\rdblquote .\f1\par
\pard\ltrpar\fi-360\li1125\tx1125\f0 d.\tab In the next \ldblquote Create Grids with Selected Lines/Arcs\rdblquote dialog specify the values and click button \ldblquote Create Grids\rdblquote .\par
\pard\ltrpar\li765 Expected result: Grids are created on the base of selected lines/arcs.\f4 \f0 If an arc is a circle, two girds will be created separately for the upper and lower parts of the circle.\f1\par
\par
\pard\ltrpar\fi-360\li360\tx360\f0 2.\tab Create orthogonal grids.\par
\pard\ltrpar\fi-360\li1080\tx1080 a.\tab Execute the command.\par
\pard\ltrpar\fi-360\li1080 b.\tab Check the option \ldblquote Create a batch of orthogonal grids\rdblquote .\f1\par
\pard\ltrpar\fi-360\li1080\tx1080\f0 c.\tab In the next \ldblquote Create Orthogonal Grids\rdblquote dialog specify the values and click button \ldblquote Create Grids\rdblquote .\f1\par
\pard\ltrpar\li720\f0 Expected result: Orthogonal grids are created according to specified values.\par
\pard\ltrpar\li360\par
\pard\ltrpar\fi-360\li360\tx360 3.\tab Create radial and arc grids.\par
\pard\ltrpar\fi-360\li1080\tx1080 a.\tab Execute the command.\par
\pard\ltrpar\fi-360\li1080 b.\tab Check the option \ldblquote Create a batch of radial and arc grids\rdblquote .\par
c.\tab In the next \ldblquote Create Radial and Arc Grids\rdblquote dialog specify the values and click button \ldblquote Create Grids\rdblquote .\f1\par
\pard\ltrpar\li720\f0 Expected result: Radial and arc grids are created according to specified values. \par
\pard\ltrpar\f1\par
}