AddDrawingFile メソッド(ActiveX/ATO)

図面ファイルを転送セットに追加します。

サポートされているプラットフォーム: Windows のみ

名前空間: TRANSMITTALLib

アセンブリ: AcETransmit19.tlb

構文と要素

VBA/VB.NET:

RetVal = object.addDrawingFile(fullpathname, ppIAddedFile)

C#:

RetVal = object.addDrawingFile(fullpathname, out ppIAddedFile);
object

タイプ: TransmittalOperation オブジェクト

このメソッドが適用されるオブジェクト。

fullpathname

アクセス: 入力のみ

タイプ: 文字列

転送セットに追加する図面ファイルのパスと名前。

ppIAddedFile

アクセス: 出力のみ

タイプ: TransmittalFile オブジェクト

転送セットに追加された図面ファイルを表す TransmittalFile オブジェクト。

戻り値(RetVal)

タイプ: AddFileReturnVal 列挙型

図面ファイルが転送セットに正常に追加されたかどうかを表す定数値。

注意

追加の注意はありません。

バージョン情報

バージョン: AutoCAD 2005 以降

VB.NET:

' Custom command to create a transmittal package with a drawing file
<CommandMethod("eTransmitDWGFile")> _
Public Shared Sub eTransmitDWGFile()

    ' Create a transmittal operation
    Dim tro As TransmittalOperation = New TransmittalOperation()

    ' Setup the transmittal behavior
    Dim ti As TransmittalInfo = _
        TransInfo(tro.getTransmittalInfoInterface(), "C:\Users\Public\TransmittalAPITest\")

    ' Add a DWG file
    Dim tf As TransmittalFile = Nothing
    tro.addDrawingFile("C:\AutoCAD\Sample\Sheet Sets\Architectural\A-02.dwg", tf)

    ' Reclaculate the sub path for all files in the transmittal package
    tro.recalcTargetSubPath()

    ' Create the transmittal package
    ' Files are copied and resaved to the path specified by the destinationRoot property
    ' and the other settings of the TransmittalInfo object.
    tro.createTransmittalPackage()
End Sub

C#:

// Custom command to create a transmittal package with a drawing file
[CommandMethod("eTransmitDWGFile")]
public static void eTransmitDWGFile()
{
    // Create a transmittal operation
    TransmittalOperation tro = new TransmittalOperation();

    // Setup the transmittal behavior
    TransmittalInfo ti =
        TransInfo(tro.getTransmittalInfoInterface(), "C:\\Users\\Public\\TransmittalAPITest\\");

    // Add a DWG file
    TransmittalFile tf = null;
    tro.addDrawingFile("C:\\AutoCAD\\Sample\\Sheet Sets\\Architectural\\A-02.dwg", out tf);

    // Reclaculate the sub path for all files in the transmittal package
    tro.recalcTargetSubPath();

    // Create the transmittal package
    // Files are copied and resaved to the path specified by the destinationRoot property
    // and the other settings of the TransmittalInfo object.
    tro.createTransmittalPackage();
}