Autodesk 256B1-05A761-1301 - AutoCAD Revit Structure Suite 2010 User Manual page 1486

User guide
Table of Contents

Advertisement

4 In the IDE, add existing files to the macro project.
Update the SDK Samples Code
In the Revit VSTA IDE, the
sample code, you must update the class that inherits from this interface:
Remove the method parameters and the return of the
Update other code related to
Code Example Before Edits
The following code snippet is from a program that uses the standard Revit API:
Code Example After Edits
In the Revit VSTA IDE, we need to update the code as follows. This example shows an application-level
macro. The method
pointer to replace
Additional Migration Notes for SDK Standard API Samples
By default, the SDK sample namespace is:
code that came from the SDK standard API samples, be sure to change the namespace for Revit VSTA.
For example, in ThisApplication.cs:
namespace AppCSharp.csproj
The default project references in Revit VSTA projects only consist of basic references, such as
Remember to add other required references. For example, you have to add
System.Drawing
1444 | Chapter 26 Creating Macros with Revit VSTA
IExternalCommand
ExternalCommandData
is the entry for this VSTA sample. Notice that we used the
RunSampleRooms()
commandData.Application
references when running samples that present a user interface.
interface is not available or used. In the SDK standard API
method.
Execute
.
.
Revit.SDK.Samples.<SampleName>.CS
this
. As you edit the sample
Revit.Proxy
and
System.Windows.Forms
.

Advertisement

Table of Contents
loading
Need help?

Need help?

Do you have a question about the 256B1-05A761-1301 - AutoCAD Revit Structure Suite 2010 and is the answer not in the manual?

Questions and answers

Table of Contents