日韩av黄I国产麻豆传媒I国产91av视频在线观看I日韩一区二区三区在线看I美女国产在线I麻豆视频国产在线观看I成人黄色短片

歡迎訪問 生活随笔!

生活随笔

當前位置: 首頁 > 编程资源 > 编程问答 >内容正文

编程问答

IDrawingDoc Interface 学习笔记

發(fā)布時間:2023/12/18 编程问答 35 豆豆
生活随笔 收集整理的這篇文章主要介紹了 IDrawingDoc Interface 学习笔记 小編覺得挺不錯的,現(xiàn)在分享給大家,幫大家做個參考.

Solidworks學(xué)習(xí)筆記-鏈接Solidworks

在此基礎(chǔ)上

允許訪問執(zhí)行繪圖操作的函數(shù)。

屬性

NameDescription備注
ActiveDrawingViewGets the currently active drawing view. ?獲取當前活動的圖紙視圖。
AutomaticViewUpdateGets or sets whether the drawing views in this drawing are automatically updated if the underlying model in that drawing view changes. ?獲取或設(shè)置該工程圖中的工程視圖是否在該工程視圖中的基礎(chǔ)模型發(fā)生更改時自動更新。
BackgroundProcessingOptionGets or sets the background processing option for this drawing. ?獲取或設(shè)置此繪圖的后臺處理選項。
HiddenViewsVisibleShows or hides all of the hidden drawing views. ?顯示或隱藏所有隱藏的圖紙視圖。
IActiveDrawingViewGets the currently active drawing view. ?獲取當前活動的圖紙視圖。
SheetGets the specified sheet. ?獲取指定的工作表。

System.int BackgroundProcessingOption {get; set;}

This example shows how to fire notifications when background processing events occur.//---------------------------------------------------------------------------- // Preconditions: // 1. Create a VSTA C# macro. // a. Copy and paste SolidWorksMacro.cs code in the macro. // b. Create a form, Form1, that contains the following // controls: // * CheckBox1 with caption Enable background processing and open // drawing. // * button1 with caption Close after background processing end event // fires". // c. Copy and paste Form1.cs code in your form's code window. // d. Modify the path in Form1.cs to open a huge drawing document that // contains many parts. // 2. Press F5 to start and close the debugger. // 3. Click Build > Build macro_name to build a DLL for the macro. // 4. Save and close the macro. // // Postconditions: // 1. Open the Windows Task manager, click the Processes tab, and click the CPU column // header to sort the processes in descending order. // 2. In SOLIDWORKS, click Tools > Macro > Run. // a. Locate your macro's \SwMacro\bin\Debug folder. // b. Select macro_name.dll. // c. Click Open to open the form. // 3. Select the Enable background processing and open drawing checkbox on the form. // 4. Displays a checkmark in the check box. // 5. Click OK to close the Background processing enabled message box. // 6. Opens the specified drawing. // 7. Fires the background processing start events. // 8. Click OK to close the Background processing start event fired message box. // 9. In the Windows Task Manager, observe that several sldbgproc.exe processes are // occupying most of the CPU. // 10. Click OK to close the Background processing stop event fired message box. // 11. Click Close after background processing end event fired button on the form. // 12. Unloads Form1. //----------------------------------------------------------------------------------//SolidWorksMacro.csusing SolidWorks.Interop.sldworks; using System.Runtime.InteropServices; using System; using System.Windows.Forms;namespace BackgroundProcessingEventsCSharp.csproj {public partial class SolidWorksMacro{public SldWorks swApp;public void Main(){//Create and show an instance of the formForm1 myForm = new Form1();myForm.Show();}} }//Form1using SolidWorks.Interop.sldworks; using SolidWorks.Interop.swconst; using System.Windows.Forms; using System.Diagnostics; using System.Collections; using System.Runtime.InteropServices; using System; using System.ComponentModel; using System.Data; using System.Drawing; using System.Text;namespace BackgroundProcessingEventsCSharp.csproj {public partial class Form1 : Form{public Form1(){InitializeComponent();}public SldWorks swApp;public bool checkBoxClicked;private void checkBox1_CheckedChanged(object sender, EventArgs e){try{swApp = (SldWorks)System.Runtime.InteropServices.Marshal.GetActiveObject("SldWorks.Application");}catch (Exception ex){MessageBox.Show(ex.Message);return;}ModelDoc2 swModelDoc = default(ModelDoc2);DrawingDoc swDrawingDoc = default(DrawingDoc);string filePath = null;filePath = "path_and_filename_of_huge_drawing";DocumentSpecification docSpecification = default(DocumentSpecification);// Set up eventsAttachEventHandlers();// Enable background processingswApp.EnableBackgroundProcessing = true;MessageBox.Show("Background processing enabled");// Open huge drawingdocSpecification = (DocumentSpecification)swApp.GetOpenDocSpec(filePath);docSpecification.Silent = true;swModelDoc = (ModelDoc2)swApp.OpenDoc7(docSpecification);swDrawingDoc = (DrawingDoc)swModelDoc;// Set document background processing to application settingswDrawingDoc.BackgroundProcessingOption = (int)swBackgroundProcessOption_e.swBackgroundProcessing_DeferToApplication;}public void AttachEventHandlers(){AttachSWEvents();}public void AttachSWEvents(){swApp.BackgroundProcessingStartNotify += this.mySwApp_BackgroundProcessingStartNotify;swApp.BackgroundProcessingEndNotify += this.mySwApp_BackgroundProcessingEndNotify;}private int mySwApp_BackgroundProcessingStartNotify(string filename){MessageBox.Show("Background processing start event fired");return 1;}private int mySwApp_BackgroundProcessingEndNotify(string filename){MessageBox.Show("Background processing end event fired");swApp.EnableBackgroundProcessing = false;return 1;}public void CheckBox1_Click(object sender, System.EventArgs e){checkBoxClicked = true;}private void button1_Click(object sender, EventArgs e){this.Close();}} }

Sheet Sheet( System.string Name) {get;}

This example shows how to get each sheet in a multi-sheet drawing document regardless whether the sheet is loaded.//---------------------------------------------------------------------- // Preconditions: // 1. Click File > Open. // 2. Open public_documents\samples\tutorial\advdrawings\foodprocessor.sldrw. // 3. Click Select sheets to open > Selected > Sheet1* (load) > OK >Open. // 4. Open the Immediate window. // // Postconditions: // 1. Loads Sheet1 only. // 2. Mouse over Sheet2, Sheet3, and Sheet4 tabs and examine the // Immediate window. // // NOTE: Because this drawing is used elsewhere, do not save changes. //--------------------------------------------------------------------- using SolidWorks.Interop.sldworks; using SolidWorks.Interop.swconst; using System; using System.Diagnostics;namespace SheetDrawingDocCSharp.csproj {partial class SolidWorksMacro{public void Main(){ModelDoc2 swModel = default(ModelDoc2);DrawingDoc swDraw = default(DrawingDoc);string[] vSheetName = null;int i = 0;bool bRet = false;string sheetName; swModel = (ModelDoc2)swApp.ActiveDoc;swDraw = (DrawingDoc)swModel; // Get the sheets in the drawing document vSheetName = (string[])swDraw.GetSheetNames();// Traverse the sheets and determine whether // they're loaded for (i = 0; i < vSheetName.Length; i++){sheetName = (string)vSheetName[i];bRet = swDraw.ActivateSheet(sheetName);Sheet swSheet = default(Sheet);swSheet = (Sheet)swDraw.get_Sheet(vSheetName[i]);if ((swSheet.IsLoaded())){Debug.Print(vSheetName[i] + " is loaded.");}else{Debug.Print(vSheetName[i] + " is not loaded.");}}}/// <summary> /// The SldWorks swApp variable is pre-assigned for you. /// </summary> public SldWorks swApp;} }

方法

NameDescription備注
ActivateSheetActivates the specified drawing sheet. ?激活指定的圖紙。
ActivateViewActivates the specified drawing view. ?激活指定的圖紙視圖。
AddChamferDimAdds a chamfer dimension. ?添加倒角尺寸。
AddHoleCallout2Adds a?hole callout at the specified position to the hole whose edge is selected. ?將指定位置的孔標注添加到其邊緣被選中的孔中。
AddLineStyleAdds a line style to the current drawing. ?向當前圖形添加線型。
AlignHorzUses the selected edge to align the current drawing view. ?使用選定邊對齊當前工程視圖。
AlignOrdinateAligns the ordinate dimension. ?對齊縱坐標尺寸。
AlignVertUses the selected edge to align the current drawing view. ?使用選定邊對齊當前工程視圖。
AttachAnnotationAttaches an existing annotation to a drawing sheet or view. ?將現(xiàn)有注釋附加到工程圖圖紙或視圖。
AttachDimensionsAttaches unattached dimensions. ?附加未附加的尺寸。
AutoBalloon5Automatically inserts BOM balloons in selected drawing views. ?在選定的工程視圖中自動插入 BOM 球標。
AutoDimensionAutomatically dimensions the selected drawing view. ?自動標注選定的工程視圖。
BreakViewBreaks the drawing view along the existing break lines. ?沿現(xiàn)有斷開線斷開工程視圖。
ChangeComponentLayerPuts the selected components on the specified layer. ?將選定的組件放在指定的層上。
ChangeOrdDirChanges the ordinate direction. ?改變縱坐標方向。
ChangeRefConfigurationOfFlatPatternViewChanges the referenced configuration of the flat-pattern view. ?更改平面模式視圖的參考配置。
Create1stAngleViews2Creates standard three orthographic views (first angle projection) for the specified model. ?為指定模型創(chuàng)建標準的三個正交視圖(第一角度投影)。
Create3rdAngleViews2Creates standard three orthographic views (third angle projection) for the specified model. ?為指定模型創(chuàng)建標準的三個正交視圖(第三角度投影)。
CreateAngDim4Creates a non-associative angular dimension. ?創(chuàng)建非關(guān)聯(lián)角度尺寸。
CreateAutoBalloonOptionsCreates an object that stores auto balloon options. ?創(chuàng)建一個存儲自動氣球選項的對象。
CreateAuxiliaryViewAt2Creates an auxiliary view based on a selected edge in a drawing view. ?基于工程視圖中的選定邊創(chuàng)建輔助視圖。
CreateBreakOutSectionCreates a broken-out section in a drawing document. ?在工程圖文檔中創(chuàng)建斷開的部分。
CreateConstructionGeometrySets?the selected sketch segments to?be construction geometry instead of sketch geometry. ?將選定的草圖段設(shè)置為構(gòu)造幾何體而不是草圖幾何體。
CreateDetailViewAt4Creates a detail view in a drawing document. ?在工程圖文檔中創(chuàng)建局部視圖。
CreateDiamDim4Creates a non-associative diameter dimension. ?創(chuàng)建非關(guān)聯(lián)直徑尺寸。
CreateDrawViewFromModelView3Creates a drawing view on the current drawing sheet using the specified model view. ?使用指定的模型視圖在當前工程圖紙上創(chuàng)建工程視圖。
CreateFlatPatternViewFromModelView3Creates a flat-pattern view from a model view. ?從模型視圖創(chuàng)建平面圖案視圖。
CreateLayer2Creates a layer for this document. ?為此文檔創(chuàng)建一個圖層。
CreateLinearDim4Creates a non-associative linear dimension. ?創(chuàng)建非關(guān)聯(lián)線性標注。
CreateOrdinateDim4Creates a non-associative ordinate dimension. ?創(chuàng)建非關(guān)聯(lián)的縱坐標標注。
CreateRelativeViewCreates a relative drawing?view. ?創(chuàng)建相對繪圖視圖。
CreateSectionViewCreates a section view in the drawing using the selected section line. ?使用選定的剖面線在工程圖中創(chuàng)建剖面視圖。
CreateSectionViewAt5Creates the specified section view. ?創(chuàng)建指定的剖面視圖。
CreateText2Creates a?note?containing the specified text at a given location. ?在給定位置創(chuàng)建包含指定文本的注釋。
CreateUnfoldedViewAt3Creates an unfolded drawing view from the selected drawing view and places it in the drawing at the specified location. ?從選定的圖紙視圖創(chuàng)建展開的圖紙視圖,并將其放置在圖紙中的指定位置。
CreateViewport3Creates a an empty view in a drawing. ?在工程圖中創(chuàng)建一個空視圖。
DeleteAllCosmeticThreadsDeletes all cosmetic threads, which do not have callouts,?in a drawing of an assembly only. ?僅在裝配體的工程圖中刪除所有沒有標注的裝飾螺紋。
DeleteLineStyleDeletes the specified line style from the current drawing. ?從當前圖形中刪除指定的線型。
DimensionsAdds dimensions to the drawing from model. ?從模型向工程圖中添加尺寸。
DragModelDimensionCopies or moves dimensions to a different drawing view. ?將尺寸復(fù)制或移動到不同的工程視圖。
DrawingViewRotateRotates the selected drawing view. ?旋轉(zhuǎn)選定的工程視圖。
DropDrawingViewFromPalette2Moves the specified drawing view from the View Palette to the current drawing sheet. ?將指定的工程視圖從視圖調(diào)色板移動到當前工程圖紙。
EditCenterMarkPropertiesEdits center mark properties. ?編輯中心標記屬性。
EditOrdinateEdits an ordinate dimension. ?編輯縱坐標尺寸。
EditSelectedGtolGets the?selected GTol to edit. ?獲取要編輯的選定 GTol。
EditSheetPuts the current drawing sheet in edit mode. ?將當前圖紙置于編輯模式。
EditSketchAllows editing of?a sketch?in?the selected drawing view or sheet. ?允許在選定的圖紙視圖或圖紙中編輯草圖。
EditTemplatePuts the template of the current drawing sheet in edit mode. ?將當前圖紙的模板置于編輯模式。
EndDrawingProvides faster creation of entities in a drawing when used with?IDrawingDoc::StartDrawing. ?與 IDrawingDoc::StartDrawing 一起使用時,可以更快地在繪圖中創(chuàng)建實體。
FeatureByNameGets?the specified feature in the drawing. ?獲取繪圖中的指定特征。
FlipSectionLineFlips the cut direction of the selected section line. ?翻轉(zhuǎn)選定剖面線的切割方向。
GenerateViewPaletteViewsAdds the specified document's predefined drawing views to the View Palette. ?將指定文檔的預(yù)定義工程視圖添加到視圖調(diào)色板。
GetCurrentSheetGets the currently active drawing sheet. ?獲取當前活動的圖紙。
GetDrawingPaletteViewNamesGets the names of drawing views in the View Palette for the active drawing sheet. ?獲取活動圖紙的視圖調(diào)色板中圖紙視圖的名稱。
GetEditSheetGets whether the current drawing is in edit sheet mode or edit template mode. ?獲取當前圖形是處于編輯圖紙模式還是編輯模板模式。
GetFirstViewGets the first drawing?view?on the current sheet. ?獲取當前圖紙上的第一個繪圖視圖。
GetInsertionPointGets the current insertion (pick) point in a drawing. ?獲取繪圖中的當前插入(拾取)點。
GetLineFontCount2Gets the a number line fonts supported by this drawing. ?獲取此繪圖支持的數(shù)字線字體。
GetLineFontIdGets the associated line font ID. ?獲取關(guān)聯(lián)的行字體 ID。
GetLineFontInfo2Gets the detailed information about the specified line font. ?獲取指定線條字體的詳細信息。
GetLineFontName2Gets the name of the specified line font. ?獲取指定線條字體的名稱。
GetLineStylesGets all of the line styles used in the current document. ?獲取當前文檔中使用的所有線條樣式。
GetPenCountGets the number of pens currently defined in SOLIDWORKS. ?獲取當前在 SOLIDWORKS 中定義的筆數(shù)。
GetPenInfoGets information about the pens used in SOLIDWORKS. ?獲取有關(guān) SOLIDWORKS 中使用的筆的信息。
GetSheetCountGets the number of drawing sheets in this drawing. ?獲取此繪圖中的繪圖頁數(shù)。
GetSheetNamesGets a list of the names of the drawing sheets in this drawing. ?獲取此圖紙中圖紙名稱的列表。
GetViewCountGets all of the number of all of?views, including the number of?sheets, in this drawing document. ?獲取此繪圖文檔中所有視圖的所有數(shù)量,包括圖紙數(shù)量。
GetViewsGets the all of the views, including the?sheets, in this drawing document. ?獲取此繪圖文檔中的所有視圖,包括圖紙。
HideEdgeHides selected visible edges in a drawing document. ?在工程圖文檔中隱藏選定的可見邊。
HideShowDimensionsSets whether to display?suppressed dimensions as dimmed and hide them. ?設(shè)置是否將抑制的尺寸顯示為灰色并隱藏它們。
HideShowDrawingViewsSets whether to hide or show hidden drawing views. ?設(shè)置是隱藏還是顯示隱藏的工程視圖。
IAddChamferDimAdds a chamfer dimension. ?添加倒角尺寸。
IAddHoleCallout2Adds a?hole callout at the specified position to the hole whose edge is selected. ?將指定位置的孔標注添加到其邊緣被選中的孔中。
ICreateAngDim4Creates a non-associative angular dimension. ?創(chuàng)建非關(guān)聯(lián)角度尺寸。
ICreateAuxiliaryViewAt2Creates an auxiliary view based on a selected edge in a drawing view. ?基于工程視圖中的選定邊創(chuàng)建輔助視圖。
ICreateDiamDim4Creates a non-associative diameter dimension. ?創(chuàng)建非關(guān)聯(lián)直徑尺寸。
ICreateLinearDim4Creates a non-associative linear dimension. ?創(chuàng)建非關(guān)聯(lián)線性標注。
ICreateOrdinateDim4Creates a non-associative ordinate dimension. ?創(chuàng)建非關(guān)聯(lián)的縱坐標標注。
ICreateSectionViewAt5Creates a section view from the section line?up to the specified distance at the specified distance. ?在指定距離處創(chuàng)建從剖面線到指定距離的剖面視圖。
ICreateText2Creates a?note?containing the specified text at a given location. ?在給定位置創(chuàng)建包含指定文本的注釋。
IEditSelectedGtolGets the?selected GTol to edit. ?獲取要編輯的選定 GTol。
IFeatureByNameGets?the specified feature in the drawing. ?獲取繪圖中的指定特征。
IGetCurrentSheetGets the currently active drawing sheet. ?獲取當前活動的圖紙。
IGetFirstViewGets the first drawing?view?on the current sheet. ?獲取當前圖紙上的第一個繪圖視圖。
IGetInsertionPointGets the current insertion (pick) point in a drawing. ?獲取繪圖中的當前插入(拾取)點。
IGetPenInfoGets information about the pens used in SOLIDWORKS. ?獲取有關(guān) SOLIDWORKS 中使用的筆的信息。
IGetSheetNamesGets a list of the names of the drawing sheets in this drawing. ?獲取此圖紙中圖紙名稱的列表。
IInsertDowelSymbolInserts a dowel pin symbol on the currently selected edge or edges. ?在當前選定的一條或多條邊上插入定位銷符號。
IInsertMultiJogLeader3Inserts a multi-jog leader. ?插入多轉(zhuǎn)折引線。
IInsertRevisionCloudInserts a revision cloud annotation with the specified shape into a view or sheet. ?將具有指定形狀的修訂云線注釋插入到視圖或圖紙中。
INewGtolCreates a new GTol. ?創(chuàng)建一個新的幾何公差。
InsertAngularRunningDimInserts an angular running dimension into this drawing. ?在此工程圖中插入角度運行尺寸。
InsertBaseDimInserts the base model dimensions into this drawing. ?將基礎(chǔ)模型尺寸插入此工程圖中。
InsertBreakHorizontalInserts a horizontal break in the drawing view. ?在工程視圖中插入水平中斷。
InsertBreakVerticalInserts a vertical break in this drawing. ?在此圖形中插入垂直中斷。
InsertCenterLine2Inserts a centerline on the selected entities. ?在選定實體上插入中心線。
InsertCenterMark3Inserts a center mark in a drawing document. ?在工程圖文檔中插入中心標記。
InsertCircularNotePatternInserts a circular note pattern using the selected?note. ?使用所選筆記插入圓形筆記模式。
InsertDowelSymbolInserts a dowel pin symbol on the currently selected edge or edges in this drawing. ?在此圖形中當前選定的一條或多條邊上插入定位銷符號。
InsertGroupInserts the currently selected items into a group (or view). ?將當前選定的項目插入到一個組(或視圖)中。
InsertHorizontalOrdinateInserts a horizontal ordinate dimension into this drawing. ?在此圖形中插入水平坐標尺寸。
InsertLinearNotePatternInserts a linear note pattern using the selected?note. ?使用選定的音符插入線性音符模式。
InsertModelAnnotations3Inserts model annotations into this drawing document in the currently selected drawing view. ?在當前選定的工程圖視圖中將模型注釋插入到此工程圖文檔中。
InsertModelDimensionsInserts model dimensions into the selected drawing view according to the option specified. ?根據(jù)指定的選項將模型尺寸插入選定的工程視圖中。
InsertModelInPredefinedViewInserts the model into the predefined drawing views in the active drawing sheet. ?將模型插入到活動圖紙中的預(yù)定義圖紙視圖中。
InsertMultiJogLeader3Inserts a multi-jog leader. ?插入多轉(zhuǎn)折引線。
InsertNewNote2Creates a new note in this drawing. ?在此繪圖中創(chuàng)建一個新注釋。
InsertOrdinateInserts an ordinate dimension into this drawing. ?在此工程圖中插入縱坐標尺寸。
InsertRefDimInserts reference dimensions in this drawing. ?在此工程圖中插入?yún)⒖汲叽纭?/span>
InsertRevisionCloudInserts a revision cloud annotation with the specified shape into a view or sheet. ?將具有指定形狀的修訂云線注釋插入到視圖或圖紙中。
InsertRevisionSymbolInserts a revision symbol note in this drawing. ?在此工程圖中插入修訂符號注釋。
InsertTableAnnotation2Inserts a table annotation in this drawing. ?在此圖形中插入表格注釋。
InsertThreadCalloutInserts a thread callout into this drawing. ?在此圖形中插入螺紋標注。
InsertVerticalOrdinateInserts a vertical ordinate dimension in this drawing. ?在此圖形中插入垂直縱坐標尺寸。
InsertWeldSymbolCreates a weld symbol located at the last edge selection. ?在最后一個邊選擇處創(chuàng)建一個焊接符號。
IReorderSheetsReorders the drawing sheets per their positions in the input array. ?根據(jù)它們在輸入數(shù)組中的位置對圖紙重新排序。
IsolateChangedDimensionsIsolates changed dimensions. ?隔離更改的尺寸。
LoadLineStylesLoads the specified line styles into the current drawing. ?將指定的線型加載到當前圖形中。
MakeSectionLineMakes a section line from a set of connected sketch lines. ?從一組連接的草圖線制作剖面線。
ModifySurfaceFinishSymbolModifies the selected surface finish symbol. ?修改選定的表面粗糙度符號。
NewGtolCreates a new GTol object and returns the pointer to that object. ?創(chuàng)建一個新的 GTol 對象并返回指向該對象的指針。
NewNoteCreates a new note at the selected location. ?在選定位置創(chuàng)建新筆記。
NewSheet4Creates a new drawing sheet in this drawing document. ?在此工程圖文檔中創(chuàng)建新的工程圖圖紙。
OnComponentPropertiesDisplays the?Component Properties?dialog for the selected view. ?顯示所選視圖的組件屬性對話框。
PasteSheetCopies and pastes a drawing sheet?to the specified location of the drawing document, optionally renaming whenever duplicate names occur. ?將工程圖復(fù)制并粘貼到工程圖文檔的指定位置,可以在出現(xiàn)重復(fù)名稱時選擇重命名。
ReorderSheetsReorders the drawing sheets per their positions in the input array. ?根據(jù)它們在輸入數(shù)組中的位置對圖紙重新排序。
ReplaceViewModelReplaces the specified instances of a model in the specified drawing views. ?替換指定工程視圖中模型的指定實例。
ResolveOutOfDateLightWeightComponentsResolves out-of-date lightweight components in the selected drawing view or drawing sheet. ?解決選定工程視圖或工程圖紙中過時的輕化零部件。
RestoreRotationRestores rotation for the selected drawing view. ?恢復(fù)選定工程視圖的旋轉(zhuǎn)。
SaveLineStylesExports to a file the specified line styles in the current drawing. ?將當前圖形中指定的線型導(dǎo)出到文件。
SetCurrentLayerSets the current layer used by this document. ?設(shè)置此文檔使用的當前層。
SetLineColorSets the line color for a selected edge or sketch entity. ?設(shè)置選定邊線或草圖實體的線條顏色。
SetLineStyleSets the style or font for the line for a selected edge or sketch entity. ?為選定邊線或草圖實體設(shè)置線條的樣式或字體。
SetLineWidthSets the line thickness for a selected edge or sketch entity to a SOLIDWORKS-supplied weight (width). ?將選定邊線或草圖實體的線寬設(shè)置為 SOLIDWORKS 提供的粗細(寬度)。
SetLineWidthCustomSets the line thickness to the specified custom width for a selected edge or sketch entity. ?將線條粗細設(shè)置為選定邊線或草圖實體的指定自定義寬度。
SetSheetsSelectedSets the specified drawing sheets whose setups to modify. ?設(shè)置要修改其設(shè)置的指定圖紙。
SetupSheet6Sets up?the specified?drawing sheet. ?設(shè)置指定的圖紙。
SheetNextMoves to the next sheet in the drawing. ?移動到工程圖中的下一張圖紙。
SheetPreviousReturns to the previous sheet in a drawing. ?返回到工程圖中的上一張圖紙。
ShowEdgeShows the selected hidden edges in a drawing document. ?顯示工程圖文檔中選定的隱藏邊。
SketchDimInserts a sketch dimension in this drawing. ?在此工程圖中插入草圖尺寸。
StartDrawingProvides faster creation of entities within a drawing. ?提供在繪圖中更快地創(chuàng)建實體。
SuppressViewHides the selected drawing view. ?隱藏選定的工程視圖。
TranslateDrawingTranslates the entire drawing. ?翻譯整個繪圖。
UnBreakViewRemoves a break in the selected drawing view. ?刪除選定工程視圖中的中斷。
UnsuppressViewHides the selected drawing view. ?隱藏選定的工程視圖。
ViewDisplayHiddenSets the current display mode?to?Hidden Lines Removed. ?將當前顯示模式設(shè)置為隱藏線已刪除。
ViewDisplayHiddengreyedSets the current display mode to?Hidden Lines Visible. ?將當前顯示模式設(shè)置為隱藏線可見。
ViewDisplayShadedSets the current display mode to?Shaded. ?將當前顯示模式設(shè)置為陰影。
ViewDisplayWireframeSets the current display mode to?Wireframe. ?將當前顯示模式設(shè)置為線框。
ViewFullPageFits the drawing to the full page. ?使繪圖適合整頁。
ViewHlrQualityToggles the?Hidden Lines Removed?mode for the drawing view. ?切換繪圖視圖的隱藏線刪除模式。
ViewModelEdgesToggles the mode for viewing model edges when in shaded mode. ?在著色模式下切換查看模型邊緣的模式。
ViewTangentEdgesToggles display of tangent edges in the selected drawing view. ?在選定工程視圖中切換相切邊的顯示。

System.bool ActivateSheet( System.string Name)

This example shows how to copy and paste drawing sheets. //---------------------------------------------------------- // Preconditions: // 1. Open a drawing document containing one sheet // named Sheet1. // 2. Open the Immediate window. // // Postconditions: // 1. Activates Sheet1. // 2. Copy and pastes Sheet1 as Sheet1(2) and activates Sheet1(2). // 3. Copy and pastes Sheet1 as Sheet1(3) and activates Sheet1(3). // 4. Examine the FeatureManager design tree and Immediate window. //---------------------------------------------------------- using SolidWorks.Interop.sldworks; using SolidWorks.Interop.swconst; using System.Runtime.InteropServices; using System; using System.Diagnostics;namespace Macro1CSharp.csproj {public partial class SolidWorksMacro{public void Main(){DrawingDoc Part = default(DrawingDoc);ModelDoc2 swModel = default(ModelDoc2);bool boolstatus = false;swModel = (ModelDoc2)swApp.ActiveDoc;Part = (DrawingDoc)swModel;if ((Part == null)){Debug.Print(" Please open a drawing document. ");return;}Sheet currentsheet = default(Sheet);currentsheet = (Sheet)Part.GetCurrentSheet();Part.ActivateSheet(currentsheet.GetName());Debug.Print("Active sheet: " + currentsheet.GetName());boolstatus = swModel.Extension.SelectByID2("Sheet1", "SHEET", 0.09205356547875, 0.10872368523, 0, false, 0, null, 0);swModel.EditCopy();boolstatus = Part.PasteSheet((int)swInsertOptions_e.swInsertOption_BeforeSelectedSheet, (int)swRenameOptions_e.swRenameOption_No);currentsheet = (Sheet)Part.GetCurrentSheet();Part.ActivateSheet(currentsheet.GetName());Debug.Print("Active sheet: " + currentsheet.GetName());boolstatus = swModel.Extension.SelectByID2("Sheet1", "SHEET", 0.09205356547875, 0.10872368523, 0, false, 0, null, 0);swModel.EditCopy();boolstatus = Part.PasteSheet((int)swInsertOptions_e.swInsertOption_AfterSelectedSheet, (int)swRenameOptions_e.swRenameOption_No);currentsheet = (Sheet)Part.GetCurrentSheet();Part.ActivateSheet(currentsheet.GetName());Debug.Print("Active sheet: " + currentsheet.GetName());}/// <summary>/// The SldWorks swApp variable is pre-assigned for you./// </summary>public SldWorks swApp;} } This example shows how to determine which sheets in a drawing are loaded.//---------------------------------------------- // Preconditions: // 1. Click File > Open. // 2. Browse to public_documents\samples\tutorial\advdrawings. // 3. Select foodprocessor.slddrw. // 4. Click Select sheets to open > Selected > Sheet1* (Load) > OK > Open. // 5. Open the Immediate window. // // Postconditions: // 1. Loads Sheet1 only. // 2. Mouse over the Sheet2, Sheet3, and Sheet4 tabs and // examine the Immediate window to verify step 1. // // NOTE: Because this drawing is used elsewhere, do not save // changes. //----------------------------------------------using SolidWorks.Interop.sldworks; using SolidWorks.Interop.swconst; using System; using System.Diagnostics; namespace IsLoadedSheetCSharp.csproj {partial class SolidWorksMacro{public void Main(){ModelDoc2 swModel = default(ModelDoc2);DrawingDoc swDraw = default(DrawingDoc);object[] vSheetName = null;int i = 0;bool bRet = false;string sheetName;swModel = (ModelDoc2)swApp.ActiveDoc;swDraw = (DrawingDoc)swModel;// Get the sheets in the drawing document vSheetName = (object[])swDraw.GetSheetNames(); // Traverse the sheets and determine whether // they're loaded for (i = 0; i < vSheetName.Length; i++){sheetName = (string)vSheetName[i];bRet = swDraw.ActivateSheet(sheetName);Sheet swSheet = default(Sheet);swSheet = (Sheet)swDraw.GetCurrentSheet();if ((swSheet.IsLoaded())){Debug.Print(vSheetName[i] + " is loaded.");}else{Debug.Print(vSheetName[i] + " is not loaded.");}}}/// <summary> /// The SldWorks swApp variable is pre-assigned for you. /// </summary> public SldWorks swApp;} }

System.bool ActivateView( System.string ViewName)

This example demonstrates firing Undo pre- and post-notification events in a drawing document.//--------------------------------------------------------------------------- // Preconditions: Open public_documents\samples\tutorial\AutoCAD\7550-021.slddrw. // // Postconditions: // 1. Selects and deletes the note in Drawing View1. // 2. Undoes the deleted note. // 3. Fires pre-notification event indicating that an undo action is about to // occur and fires post-notification event indicating that an undo // action occurred. // 4. Click OK to close each message box. // // NOTE: Because the drawing is used elsewhere, do not save changes. //---------------------------------------------------------------------------using SolidWorks.Interop.sldworks; using SolidWorks.Interop.swconst; using System; using System.Collections; using System.Windows.Forms;namespace UndoPostNotifyDrawingCSharp.csproj { partial class SolidWorksMacro {public DrawingDoc swDrawing;public void Main(){ModelDoc2 swModel = default(ModelDoc2);ModelDocExtension swModelDocExt = default(ModelDocExtension);bool boolstatus = false;Hashtable openDrawing = default(Hashtable);swModel = (ModelDoc2)swApp.ActiveDoc;swModelDocExt = (ModelDocExtension)swModel.Extension; // Event notification swDrawing = (DrawingDoc)swModel;openDrawing = new Hashtable();AttachEventHandlers(); // Activate the drawing view that contains // the note you want to delete boolstatus = swDrawing.ActivateView("Drawing View3");boolstatus = swModelDocExt.SelectByID2("DetailItem77@Drawing View3", "NOTE", 0.3058741216774, 0.1870419466786, 0, false, 0, null, 0); // Delete the selected note swModel.EditDelete(); // Undo deletion of note swModel.EditUndo2(1); // Post-notification is fired // Rebuild the drawing swModel.ForceRebuild3(true);} public void AttachEventHandlers(){AttachSWEvents();}public void AttachSWEvents(){swDrawing.UndoPostNotify += this.swDrawing_UndoPostNotify;swDrawing.UndoPreNotify += this.swDrawing_UndoPreNotify;} private int swDrawing_UndoPostNotify(){// Display message after Undo// NOTE: Because the message box may be displayed // behind an opened window, you might not see it. // If so, then check the Taskbar. MessageBox.Show("An undo post-notification event has been fired.");return 1;} private int b(){// Display message after Undo// NOTE: Because the message box may be displayed // behind an opened window, you might not see it. // If so, then check the Taskbar. MessageBox.Show("An Undo pre-notification event has been fired.");return 1;} /// <summary> /// The SldWorks swApp variable is pre-assigned for you. /// </summary> public SldWorks swApp; } } //This example shows how to automatically insert a model's dimensions marked for drawings //into a drawing.//--------------------------------------------------------------------------- // Preconditions: // 1. Assembly document to open exists. // 2. Run the macro. // // Postconditions: // 1. A new drawing document is opened. // 2. A drawing view of the assembly document is created. // 3. The dimensions in the assembly document that are marked for drawings, // including any duplicate dimensions, appear in the drawing view. // 4. The dimensions in the drawing, which are annotations, // are selected and marked. //--------------------------------------------------------------------------- using SolidWorks.Interop.sldworks; using SolidWorks.Interop.swconst; using System.Runtime.InteropServices; using System;namespace SelectAnnotationsCSharp.csproj {public partial class SolidWorksMacro{public void Main(){ModelDoc2 swModel;ModelDocExtension swModelDocExt;DrawingDoc swDrawing;SelectionMgr swSelmgr;View swView;object[] annotations;object selAnnot;Annotation swAnnotation;SelectData swSelData;int mark;string retval;bool status;retval = swApp.GetUserPreferenceStringValue((int)swUserPreferenceStringValue_e.swDefaultTemplateDrawing);swModel = (ModelDoc2)swApp.NewDocument(retval, 0, 0, 0);swDrawing = (DrawingDoc)swModel;swModelDocExt = (ModelDocExtension)swModel.Extension;swSelmgr = (SelectionMgr)swModel.SelectionManager;// Create drawing from assemblyswView = (View)swDrawing.CreateDrawViewFromModelView3("C:\\Users\\Public\\Documents\\SOLIDWORKS\\SOLIDWORKS 2018\\samples\\tutorial\\api\\wrench.sldasm", "*Front", 0.1314541543147, 0.1407887187817, 0);// Select and activate the viewstatus = swModelDocExt.SelectByID2("Drawing View1", "DRAWINGVIEW", 0, 0, 0, false, 0, null, 0);status = swDrawing.ActivateView("Drawing View1");swModel.ClearSelection2(true);// Insert the annotations marked for the drawingannotations = (object[])swDrawing.InsertModelAnnotations3((int)swImportModelItemsSource_e.swImportModelItemsFromEntireModel, (int)swInsertAnnotation_e.swInsertDimensionsMarkedForDrawing, true, false, false, false);// Select and mark each annotationswSelData = swSelmgr.CreateSelectData();mark = 0;foreach (object annot in annotations){selAnnot = annot;swAnnotation = (Annotation)selAnnot;status = swAnnotation.Select3(true, swSelData);swSelData.Mark = mark;mark = mark + 1;}}/// <summary>/// The SldWorks swApp variable is pre-assigned for you./// </summary>public SldWorks swApp;} }

System.bool AttachAnnotation( System.int Option)

//This example shows how to attach an existing annotation to a drawing view.//---------------------------------------------------------------------------- // Preconditions: Open public_documents\samples\tutorial\api\replaceview.slddrw. // // Postconditions: // 1. Inserts a note annotation n the drawing. // 2. Selects the annotation. // 3. Appends a face in a drawing view to the selection list. // 4. Attaches the annotation to the selected face. // 5. Examine the drawing. // 6. Close the drawing without saving it. // --------------------------------------------------------------------------- using SolidWorks.Interop.sldworks; using SolidWorks.Interop.swconst; using System.Runtime.InteropServices; using System; namespace AttachAnnotation_CSharp.csproj {partial class SolidWorksMacro{ModelDoc2 part;DrawingDoc draw;Note aNote;Annotation anAnnot;SelectData selectData = null;int ret;bool boolstatus;public void Main(){part = (ModelDoc2)swApp.ActiveDoc;draw = (DrawingDoc)part;boolstatus = draw.ActivateSheet("Sheet1");aNote = (Note)draw.CreateText2("This is a note.", 0.21, 0.12, 0, 0.005, 0);anAnnot = (Annotation)aNote.GetAnnotation();ret = anAnnot.SetLeader3(swLeaderStyle_e.swBENT, swLeaderSide_e.swLS_SMART, true, false, false, false);anAnnot.Select3(false, selectData);boolstatus = draw.ActivateView("Drawing View1");boolstatus = part.Extension.SelectByID2("", "FACE", 0.0783563575357558, 0.17448024010205, -499.965138294658, true, 0, null, 0);draw.AttachAnnotation(swAttachAnnotationOption_e.swAttachAnnotationOption_View);}public SldWorks swApp;} }

System.object AutoBalloon5( AutoBalloonOptions BalloonOptions)

//This example shows how to automatically add BOM balloons to a drawing view.//------------------------------------------------------------------------------ // Preconditions: Open a drawing with a bill of materials (BOM) table. // // Postconditions: BOM balloons are added to the view. //------------------------------------------------------------------------------ using Microsoft.VisualBasic; using System; using System.Collections; using System.Collections.Generic; using System.Data; using System.Diagnostics; using SolidWorks.Interop.sldworks; using SolidWorks.Interop.swconst; using System.Runtime.InteropServices; namespace AutoBalloon_CSharp.csproj {partial class SolidWorksMacro{ModelDoc2 Part;DrawingDoc Draw;object vNotes;AutoBalloonOptions autoballoonParams;bool boolstatus;public void Main(){Part = (ModelDoc2)swApp.ActiveDoc;Draw = (DrawingDoc)Part;boolstatus = Draw.ActivateView("Drawing View1");boolstatus = Part.Extension.SelectByID2("Drawing View1", "DRAWINGVIEW", 0, 0, 0, false, 0, null, 0);autoballoonParams = Draw.CreateAutoBalloonOptions();autoballoonParams.Layout = (int)swBalloonLayoutType_e.swDetailingBalloonLayout_Square;autoballoonParams.ReverseDirection = false;autoballoonParams.IgnoreMultiple = true;autoballoonParams.InsertMagneticLine = true;autoballoonParams.LeaderAttachmentToFaces = true;autoballoonParams.Style = (int)swBalloonStyle_e.swBS_Circular;autoballoonParams.Size = (int)swBalloonFit_e.swBF_5Chars;autoballoonParams.UpperTextContent = (int)swBalloonTextContent_e.swBalloonTextItemNumber;autoballoonParams.Layername = "-None-";autoballoonParams.ItemNumberStart = 1;autoballoonParams.ItemNumberIncrement = 1;autoballoonParams.ItemOrder = (int)swBalloonItemNumbersOrder_e.swBalloonItemNumbers_DoNotChangeItemNumbers;autoballoonParams.EditBalloons = true;autoballoonParams.EditBalloonOption = (int)swEditBalloonOption_e.swEditBalloonOption_Resequence;vNotes = Draw.AutoBalloon5(autoballoonParams);}public SldWorks swApp;} }

System.int AutoDimension(?
? ?System.int EntitiesToDimension,
? ?System.int HorizontalScheme,
? ?System.int HorizontalPlacement,
? ?System.int VerticalScheme,
? ?System.int VerticalPlacement)

//This example shows how to autodimension a selected drawing view.//----------------------------------------------------------------- // Preconditions: Verify that the specified drawing document to // open exists. // // Postconditions: // 1. Opens the specified drawing document. // 2. Activates Drawing View1. // 3. Selects a vertex. // 4. Autodimensions the drawing view based on the // selected vertex. // 5. Examine the drawing. // // NOTE: Because the drawing is used elsewhere, do not save changes. //------------------------------------------------------------------ using SolidWorks.Interop.sldworks; using SolidWorks.Interop.swconst; using System.Runtime.InteropServices; using System;namespace AutodimensionCSharp.csproj {public partial class SolidWorksMacro{public void Main(){ModelDoc2 swModel = default(ModelDoc2);DrawingDoc swDrawing = default(DrawingDoc);ModelDocExtension swModelDocExt = default(ModelDocExtension);bool status = false;string fileName = null;int errors = 0;int warnings = 0;int selmark = 0;int ret = 0;// Open drawing document of partfileName = "C:\\Users\\Public\\Documents\\SOLIDWORKS\\SOLIDWORKS 2018\\samples\\tutorial\\advdrawings\\foodprocessor.slddrw";swModel = (ModelDoc2)swApp.OpenDoc6(fileName, (int)swDocumentTypes_e.swDocDRAWING, (int)swOpenDocOptions_e.swOpenDocOptions_Silent, "", ref errors, ref warnings);swDrawing = (DrawingDoc)swModel;status = swDrawing.ActivateView("Drawing View1");swModelDocExt = (ModelDocExtension)swModel.Extension;// Select drawing viewstatus = swModelDocExt.SelectByID2("Drawing View1", "DRAWINGVIEW", 0, 0, 0, false, 0, null, 0);// Horizontal and vertical datum, or a vertex datum, baselines for// dimension creation// These are optional; if not selected, autodimension uses default datums,// the leftmost and bottommost edgesselmark = (int)swAutodimMark_e.swAutodimMarkHorizontalDatum;selmark = (int)swAutodimMark_e.swAutodimMarkVerticalDatum;selmark = (int)swAutodimMark_e.swAutodimMarkOriginDatum;// Select a vertexstatus = swModelDocExt.SelectByID2("", "VERTEX", 0.20215546544586, 0.2496899375, 0.00479999999998881, true, selmark, null, 0);// Autodimensions the drawing view based on the selected vertexret = swDrawing.AutoDimension((int)swAutodimEntities_e.swAutodimEntitiesBasedOnPreselect, (int)swAutodimScheme_e.swAutodimSchemeBaseline, (int)swAutodimHorizontalPlacement_e.swAutodimHorizontalPlacementAbove, (int)swAutodimScheme_e.swAutodimSchemeBaseline, (int)swAutodimVerticalPlacement_e.swAutodimVerticalPlacementRight);}/// <summary>/// The SldWorks swApp variable is pre-assigned for you./// </summary>public SldWorks swApp;} }

void BreakView()

//This example shows how to create and remove a broken view.//---------------------------------------------------------------------------- // Preconditions: // 1. Verify that the specified file to open exists. // 2. Open the Immediate window. // // Postconditions: // 1. Opens the specified drawing and selects Drawing View1. // 2. Examine the drawing, then press F5. // 3. Inserts break lines in Drawing View1. // 4. Examine the drawing, then press F5. // 5. Modifies the positions of the break lines and breaks the view. // 6. Examine the drawing, then press F5. // 7. Removes the break from Drawing View1. // 8. Examine the drawing and the Immediate window. // // NOTE: Because this drawing document is used elsewhere, // do not save changes. //---------------------------------------------------------------------------- using SolidWorks.Interop.sldworks; using SolidWorks.Interop.swconst; using System.Runtime.InteropServices; using System; using System.Diagnostics;namespace BreakViewDrawingDocCSharp.csproj {public partial class SolidWorksMacro{public void Main(){ModelDoc2 swModel;DrawingDoc swDrawingDoc;ModelDocExtension swModelDocExt;SelectionMgr swSelectionManager;SelectData swSelectData;View swView;BreakLine swBreakLine;string fileName;bool status;int errors = 0;int warnings = 0;fileName = "C:\\Users\\Public\\Documents\\SOLIDWORKS\\SOLIDWORKS 2018\\samples\\tutorial\\api\\box.slddrw";swApp.OpenDoc6(fileName, (int)swDocumentTypes_e.swDocDRAWING, (int)swOpenDocOptions_e.swOpenDocOptions_Silent, "", ref errors, ref warnings);swModel = (ModelDoc2)swApp.ActiveDoc;swDrawingDoc = (DrawingDoc)swModel;swModelDocExt = (ModelDocExtension)swModel.Extension;// Activate and select the view to breakstatus = swDrawingDoc.ActivateView("Drawing View1");status = swModelDocExt.SelectByID2("Drawing View1", "DRAWINGVIEW", 0, 0, 0, false, 0, null, 0);swSelectionManager = (SelectionMgr)swModel.SelectionManager; swSelectData = (SelectData)swSelectionManager.CreateSelectData();swView = (View)swSelectionManager.GetSelectedObject6(1, -1);System.Diagnostics.Debugger.Break();// Examine the drawing; press F5// Insert the break linesswBreakLine = (BreakLine)swView.InsertBreak(0, -0.0291950859897372, 0.0198236302285804, 1);System.Diagnostics.Debugger.Break();// Break lines inserted; press F5// Reset position of break linesstatus = swBreakLine.SetPosition(-0.03, 0.05);swModel.EditRebuild3Debug.Print("Break line: ");Debug.Print(" Selected: " + swBreakLine.Select(true, null));Debug.Print(" Style: " + swBreakLine.Style);Debug.Print(" Orientation: " + swBreakLine.Orientation);Debug.Print(" Position: " + swBreakLine.GetPosition(0));swDrawingDoc.BreakView();System.Diagnostics.Debugger.Break();// Positions of the break lines are modified, and view is broken// Press F5status = swModelDocExt.SelectByID2("Drawing View1", "DRAWINGVIEW", 0, 0, 0, false, 0, null, 0);swDrawingDoc.UnBreakView();// Break is removed}/// <summary>/// The SldWorks swApp variable is pre-assigned for you./// </summary>public SldWorks swApp;} }

void ChangeComponentLayer(?
? ?System.string Layername,
? ?System.bool AllViews)

This example shows how to create a layer for the part in the selected drawing view.'---------------------------------------------------------------------------- ' Preconditions: ' 1. Open a drawing of a part. ' 2. Select a drawing view in the FeatureManager design tree. ' 3. Open the Immediate window. ' ' Postconditions: ' 1. Creates a layer for the part in the selected drawing view. ' 2. Click the Layer Properties tool on the Line Format toolbar to verify ' that the newly created layer is selected in the Layers dialog box. ' 3. Examine the Immediate window. '---------------------------------------------------------------------------- Option ExplicitPrivate Sub ChangeComponentLayer _ ( _swApp As SldWorks.SldWorks, _swDraw As SldWorks.DrawingDoc, _sLayerName As String _ )Dim bRet As Boolean' Form a valid layer namesLayerName = Replace(sLayerName, "/", "_")sLayerName = Replace(sLayerName, "@", "_")bRet = swDraw.CreateLayer2( _sLayerName, _"Layer for part in " & sLayerName, _0, swLineCONTINUOUS, swLW_NORMAL, True, True)' Change in all drawing viewsswDraw.ChangeComponentLayer sLayerName, TrueEnd SubSub main()Dim swApp As SldWorks.SldWorksDim swModel As SldWorks.ModelDoc2Dim swDraw As SldWorks.DrawingDocDim swSelMgr As SldWorks.SelectionMgrDim swView As SldWorks.ViewDim swDrawModel As SldWorks.ModelDoc2Dim swDrawPart As SldWorks.PartDocDim vBody As VariantDim swBody As SldWorks.Body2Dim swFace As SldWorks.Face2Dim swEnt As SldWorks.EntityDim nErrors As LongDim nWarnings As LongDim bRet As BooleanSet swApp = Application.SldWorksSet swModel = swApp.ActiveDocSet swDraw = swModelSet swSelMgr = swModel.SelectionManagerSet swView = swSelMgr.GetSelectedObject6(1, -1)Set swDrawModel = swApp.OpenDoc6(swView.GetReferencedModelName, swDocPART, swOpenDocOptions_Silent, "", nErrors, nWarnings)Set swDrawPart = swDrawModelDebug.Print "File = " & swModel.GetPathNameDebug.Print " View = " & swView.NameDebug.Print " View Model = " & swView.GetReferencedModelNamevBody = swDrawPart.GetBodies2(swSolidBody, True)Set swBody = vBody(0)Set swFace = swBody.GetFirstFaceSet swEnt = swFacebRet = swView.SelectEntity(swEnt, False)ChangeComponentLayer swApp, swDraw, swView.NameEnd Sub

System.object CreateDetailViewAt4(?
? ?System.double X,
? ?System.double Y,
? ?System.double Z,
? ?System.int Style,
? ?System.double Scale1,
? ?System.double Scale2,
? ?System.string LabelIn,
? ?System.int Showtype,
? ?System.bool FullOutline,
? ?System.bool JaggedOutline,
? ?System.bool NoOutline,
? ?System.int ShapeIntensity)

//This example shows how to create a detail circle and a detail view.//--------------------------------------------------------------------------- // Preconditions: // 1. Verify that the drawing to open exists. // 2. Open the Immediate window. // // Postconditions: // 1. Opens the specified drawing. // 2. Activates Drawing View4. // 3. Creates a detail circle and a detail view using the visible // corner of Drawing View4. // 4. Activates the detail view. // 5. Gets and sets some properties of the detail circle and detail view. // 6. Examine the drawing document and Immediate window. // // NOTE: Because the drawing is used elsewhere, do not save changes. //------------------------------------------------------------------------------ using SolidWorks.Interop.sldworks; using SolidWorks.Interop.swconst; using System.Runtime.InteropServices; using System; using System.Diagnostics;namespace Macro1CSharp.csproj {partial class SolidWorksMacro{public void Main(){ModelDoc2 swModel = default(ModelDoc2);DrawingDoc swDrawing = default(DrawingDoc);SketchManager swSketchManager = default(SketchManager);SketchSegment swSketchSegment = default(SketchSegment);View swView = default(View);DetailCircle swDetailCircle = default(DetailCircle);SelectionMgr swSelMgr = default(SelectionMgr);SelectData swSelData = default(SelectData);string fileName = null;bool status = false;int errors = 0;int warnings = 0;// Open drawingfileName = "C:\\Users\\Public\\Documents\\SOLIDWORKS\\SOLIDWORKS 2018\\samples\\tutorial\\api\\replaceview.slddrw";swModel = (ModelDoc2)swApp.OpenDoc6(fileName, (int)swDocumentTypes_e.swDocDRAWING, (int)swOpenDocOptions_e.swOpenDocOptions_Silent, "", ref errors, ref warnings);swDrawing = (DrawingDoc)swModel;swSelMgr = (SelectionMgr)swModel.SelectionManager;swSelData = (SelectData)swSelMgr.CreateSelectData();swApp.ActivateDoc3("replaceview - Sheet1", false, (int)swRebuildOnActivation_e.swDontRebuildActiveDoc, ref errors);// Activate Drawing View4 and create detail circle and detail viewstatus = swDrawing.ActivateView("Drawing View4");swSketchManager = (SketchManager)swModel.SketchManager;swSketchSegment = (SketchSegment)swSketchManager.CreateCircle(0.007581, 0.053509, 0.0, 0.013533, 0.016475, 0.0);swView = (View)swDrawing.CreateDetailViewAt4(0.22305342706156, 0.0762140266484527, 0, (int)swDetViewStyle_e.swDetViewSTANDARD, 1, 1, "A", (int)swDetCircleShowType_e.swDetCircleCIRCLE, true, true, false, 5);swModel.ClearSelection2(true);// Activate detail viewstatus = swDrawing.ActivateView("Drawing View5");// Get and set some properties of detail circle and detail viewswDetailCircle = (DetailCircle)swView.GetDetail();Debug.Print("Detail circle:");Debug.Print(" Selected: " + swDetailCircle.Select(true, null));Debug.Print(" Label: " + swDetailCircle.GetLabel());Double xpos;Double ypos;swDetailCircle.GetLabelPosition(out xpos, out ypos);Debug.Print(" Label X position: " + xpos);Debug.Print(" Label Y position: " + ypos);Debug.Print(" Type of circle: " + swDetailCircle.GetDisplay());Debug.Print(" Name: " + swDetailCircle.GetName());Debug.Print(" Style: " + swDetailCircle.GetStyle());Debug.Print(" Default document text formatting? " + swDetailCircle.GetUseDocTextFormat());if (swDetailCircle.NoOutline == false){Debug.Print(" No outline? False");if (swDetailCircle.JaggedOutline == true){swDetailCircle.ShapeIntensity = 2;Debug.Print(" Jagged outline and shape intensity? True and 2");} } }/// <summary>/// The SldWorks swApp variable is pre-assigned for you./// </summary>public SldWorks swApp;} }

System.bool CreateBreakOutSection(?
? ?System.double Depth)

//This example shows how to create a broken-out section in a drawing view.//---------------------------------------------------------------------------- // Preconditions: // 1. Open a drawing. // 2. Select Drawing View1. // // Postconditions: A broken-out section is created in Drawing View1 // using the specified closed spline. // --------------------------------------------------------------------------- using Microsoft.VisualBasic; using System; using System.Collections; using System.Collections.Generic; using System.Data; using System.Diagnostics; using SolidWorks.Interop.sldworks; using SolidWorks.Interop.swconst; using System.Runtime.InteropServices; namespace CreateBreakOutSection_CSharp.csproj {partial class SolidWorksMacro{ModelDoc2 Part;object pointArray;double[] points = new double[12];SketchSegment skSegment;SelectData selectData = null;DrawingDoc dDoc;public void Main(){Part = (ModelDoc2)swApp.ActiveDoc;points[0] = -0.0544316967839374;points[1] = 0.0413619530906299;points[2] = 0;points[3] = 0.0530556603589196;points[4] = 0.0413619530906299;points[5] = 0;points[6] = 0.00783232107320536;points[7] = 0.00720299635749822;points[8] = 0;points[9] = -0.0544316967839374;points[10] = 0.0413619530906299;points[11] = 0;pointArray = points;skSegment = Part.SketchManager.CreateSpline((pointArray));skSegment.Select4(true, selectData);dDoc = (DrawingDoc)Part;dDoc.CreateBreakOutSection(0.00254);Part.ClearSelection2(true);}public SldWorks swApp;}}

View CreateRelativeView(?
? ?System.string ModelName,
? ?System.double XPos,
? ?System.double YPos,
? ?System.int ViewDirFront,
? ?System.int ViewDirRight)

//This example shows how to create a relative drawing view.// ****************************************************************************** // Preconditions: // 1. Open public_documents\samples\tutorial\api\maingrip.sldprt. // 2. Select File > Make Drawing from Part. // 3. Run the macro. // // Postconditions: // 1. Iterates through the drawing views // in the View Palette and drops // *Current drawing view in the drawing. // 2. Activates the part. // 3. Selects two faces for the relative drawing view. // 4. Activates the drawing. // 5. Creates and inserts a relative drawing // view using the selected faces. // // NOTE: Because the part document is used elsewhere, do not // save any changes when closing it. // ******************************************************************************using SolidWorks.Interop.sldworks; using SolidWorks.Interop.swconst; using System.Runtime.InteropServices; using System;namespace CreateRelativeViewCSharp.csproj {partial class SolidWorksMacro{ModelDoc2 swModel;DrawingDoc swDrawing;View swView;ModelDocExtension swModelDocExt;string fileName;bool status;int errors;int warnings;int numViews;object[] viewNames;string viewName;string viewPaletteName;int i;public void Main(){swDrawing = (DrawingDoc)swApp.ActiveDoc;// Get number of views on View PalettenumViews = 0;viewNames = (object[])swDrawing.GetDrawingPaletteViewNames();// Iterate through views on View Palette// When view name equals *Current, drop// that view in drawingif (!((viewNames == null))){numViews = (viewNames.GetUpperBound(0) - viewNames.GetLowerBound(0));for (i = 0; i <= numViews; i++){viewPaletteName = (string)viewNames[i];if ((viewPaletteName == "*Current")){swView = (View)swDrawing.DropDrawingViewFromPalette2(viewPaletteName, 0.0, 0.0, 0.0);}}}// Activate the part document and// select two faces for the relative drawing viewswApp.ActivateDoc3("maingrip.sldprt", false, (int)swRebuildOnActivation_e.swUserDecision, ref errors);swModel = (ModelDoc2)swApp.ActiveDoc;swModelDocExt = (ModelDocExtension)swModel.Extension;swModel.ClearSelection2(true);status = swModelDocExt.SelectByID2("", "FACE", 0.0466263268498324, 0.00558799999987514, -0.00617351393179888, false, 1, null, 0);status = swModelDocExt.SelectByID2("", "FACE", 0.0504738910727269, 0.00167315253537481, -0.00496149996774875, true, 2, null, 0);// Activate the drawing document// Create and insert the relative drawing view using// the selected faces// Activate the relative drawing viewswApp.ActivateDoc3("maingrip - Sheet1", false, (int)swRebuildOnActivation_e.swUserDecision, ref errors);swDrawing = (DrawingDoc)swApp.ActiveDoc;fileName = "C:\\Users\\Public\\Documents\\SOLIDWORKS\\SOLIDWORKS 2018\\samples\\tutorial\\api\\maingrip.sldprt";swView = (View)swDrawing.CreateRelativeView(fileName, 0.203608914116486, 0.493530187561698, (int)swRelativeViewCreationDirection_e.swRelativeViewCreationDirection_FRONT, (int)swRelativeViewCreationDirection_e.swRelativeViewCreationDirection_RIGHT);status = swDrawing.ActivateView("Drawing View2");}/// <summary>/// The SldWorks swApp variable is pre-assigned for you./// </summary>public SldWorks swApp;} }

View CreateSectionViewAt5(?
? ?System.double X,
? ?System.double Y,
? ?System.double Z,
? ?System.string SectionLabel,
? ?System.int Options,
? ?System.object ExcludedComponents,
? ?System.double SectionDepth)

//This example creates a section view and sets and gets some of the section view's data.//-------------------------------------------------------------------------- // Preconditions: // 1. Open public_documents\samples\tutorial\driveworksxpress\mobile gantry.slddrw // 2. Open the Immediate window. // // Postconditions: // 1. Creates a section view of Drawing View4. // 2. Sets and gets some section view settings. // 3. Examine the drawing and the Immediate window. // // NOTE: Because this drawing is used elsewhere, do not save changes. //-------------------------------------------------------------------------- using System; using System.Diagnostics; using SolidWorks.Interop.sldworks; using SolidWorks.Interop.swconst; using System.Runtime.InteropServices;namespace CreateSectionView_CSharp.csproj {partial class SolidWorksMacro{ModelDoc2 swModel;DrawingDoc swDrawing;SketchManager swSketchMgr;SketchSegment swSketchSegment;object excludedComponents;View swView;DrSection swSectionView;bool boolstatus;public void Main(){swModel = (ModelDoc2)swApp.ActiveDoc;swDrawing = (DrawingDoc)swModel;// Activate the view for which you want to create a section viewboolstatus = swDrawing.ActivateView("Drawing View4");swModel.ClearSelection2(true);// Create section-view lineswSketchMgr = swModel.SketchManager;swSketchSegment = swSketchMgr.CreateLine(-1.383705, 2.078706, 0.0, 2.747162, 0.0441, 0.0);// Create the section view at the specified coordinates// and up to the specified distance from the section-view lineexcludedComponents = null;swView = swDrawing.CreateSectionViewAt5(0.1604082711061, 0.2048687170364, 0, "D", 32, (excludedComponents), 0.00835);Debug.Print("View data: ");Debug.Print(" Emphasize outlines of section views? " + swView.EmphasizeOutline);swSectionView = (DrSection)swView.GetSection();// Set some section-view settingsswSectionView.SetAutoHatch(true);swSectionView.SetLabel2("ABCD");swSectionView.SetDisplayOnlySurfaceCut(false);swSectionView.SetPartialSection(false);swSectionView.SetReversedCutDirection(false);swSectionView.SetScaleWithModelChanges(true);swSectionView.CutSurfaceBodies = true;swSectionView.DisplaySurfaceBodies = true;swSectionView.ExcludeSliceSectionBodies = false;// Get some section-view settingsDebug.Print("Section view data: ");Debug.Print(" Label: " + swSectionView.GetLabel());Debug.Print(" Name of section line: " + swSectionView.GetName());Debug.Print(" Depth: " + swSectionView.SectionDepth * 1000.0 + " mm");Debug.Print(" Cut direction reversed from default direction? " + swSectionView.GetReversedCutDirection());Debug.Print(" Partial section cut? " + swSectionView.GetPartialSection());Debug.Print(" Display only the surface cut by the section line? " + swSectionView.GetDisplayOnlySurfaceCut());Debug.Print(" Display surface bodies? " + swSectionView.DisplaySurfaceBodies);Debug.Print(" Exclude slice section bodies? " + swSectionView.ExcludeSliceSectionBodies);swSectionView.SetDisplayOnlySpeedPakBodies(true);Debug.Print(" Display only SpeedPak bodies? " + swSectionView.GetDisplayOnlySpeedPakBodies());Debug.Print(" Scale with model changes? " + swSectionView.GetScaleWithModelChanges());Debug.Print(" Auto-hatch enabled? " + swSectionView.GetAutoHatch());Debug.Print(" Hide cut surface bodies? " + swSectionView.CutSurfaceBodies);swModel.EditRebuild3();}public SldWorks swApp;} }

View CreateUnfoldedViewAt3(?
? ?System.double X,
? ?System.double Y,
? ?System.double Z,
? ?System.bool NotAligned)

//This example shows how to create an unfolded view from an existing view.//---------------------------------------------------------------------------- // Preconditions: Open: // public_documents\samples\tutorial\advdrawings\foodprocessor.slddrw // // Postconditions: A new unfolded view is created from Drawing View1. // // NOTE: Because the model is used elsewhere, // do not save changes when closing it. // --------------------------------------------------------------------------- using Microsoft.VisualBasic; using System; using System.Collections; using System.Collections.Generic; using System.Data; using System.Diagnostics; using SolidWorks.Interop.sldworks; using SolidWorks.Interop.swconst; using System.Runtime.InteropServices; namespace InsertUnfoldedView_CSharp.csproj {partial class SolidWorksMacro{ModelDoc2 Part;DrawingDoc ddoc;View myView;bool boolstatus;public void Main(){Part = (ModelDoc2)swApp.ActiveDoc;ddoc = (DrawingDoc)Part;boolstatus = Part.Extension.SelectByID2("Drawing View1", "DRAWINGVIEW", 0, 0, 0, false, 0, null, 0);myView = ddoc.CreateUnfoldedViewAt3(0.379074752406062, 0.276482735105582, 0, false);}public SldWorks swApp;} }

System.bool DrawingViewRotate(?
? ?System.double NewAngle)

This example shows how to rotate the selected drawing view 45o.//--------------------------------------------------------------- // Preconditions: Verify that the specified file to open exists. // // Postconditions: Rotates the selected drawing view 45o. //---------------------------------------- ----------------------using SolidWorks.Interop.sldworks; using SolidWorks.Interop.swconst; using System;namespace DrawingViewRotateCSharp.csproj {partial class SolidWorksMacro{public void Main(){ModelDoc2 swModel = default(ModelDoc2);ModelDocExtension swModelDocExt = default(ModelDocExtension);DrawingDoc swDrawing = default(DrawingDoc);bool status = false;int errors = 0;int warnings = 0;swModel = (ModelDoc2)swApp.OpenDoc6("C:\\Users\\Public\\Documents\\SOLIDWORKS\\SOLIDWORKS 2018\\samples\\tutorial\\driveworksxpress\\mobile gantry.slddrw", (int)swDocumentTypes_e.swDocDRAWING, (int)swOpenDocOptions_e.swOpenDocOptions_Silent, "", ref errors, ref warnings);swModelDocExt = (ModelDocExtension)swModel.Extension;swModel.ViewZoomtofit2();swDrawing = (DrawingDoc)swModel;status = swDrawing.ActivateView("Drawing View4");status = swModelDocExt.SelectByID2("Drawing View4", "DRAWINGVIEW", 0.1122300799499, 0.1471819585104, 0, false, 0, null, 0);//Convert degrees to radians, the default system unit // 1 radian = 180o/p = 57.295779513o or approximately 57.3o status = swDrawing.DrawingViewRotate(45 / 57.3);}/// <summary> /// The SldWorks swApp variable is pre-assigned for you. /// </summary> public SldWorks swApp;}}

View DropDrawingViewFromPalette2(?
? ?System.string PaletteViewName,
? ?System.double X,
? ?System.double Y,
? ?System.double Z)

//This example shows how to get the number of lines in a flat-pattern drawing view's //boundary-box sketch.//---------------------------------------------------------- // Preconditions: // 1. Open public_documents\samples\tutorial\api\SMGussetAPI.SLDPRT. // 2. Create a new drawing document. // 3. Select SMGussetAPI.SLDPRT in the View // Palette's dropdown list box. // 4. Open the Immediate window. // // Postconditions: // 1. Examine the Immediate window and the drawing. // 2. If necessary, drag the drawing onto the drawing sheet // and zoom in on the drawing view. // // NOTE: Because the part is used elsewhere, do not save // changes. //--------------------------------------------------------- using SolidWorks.Interop.sldworks; using SolidWorks.Interop.swconst; using System; using System.Diagnostics;namespace GetSMBoundaryBoxDisplayDataViewCSharp.csproj {partial class SolidWorksMacro{public void Main(){ModelDoc2 swModel;DrawingDoc swDrawing;View swView;Sheet swSheet;DisplayData swDisplayData;double[] sheetProperties = null;double sheetScale = 0;swDwgPaperSizes_e paperSize;double width = 0;double height = 0;long numViews = 0;object[] viewNames = null;string viewPaletteName = "";string drawingViewName = "";int i = 0;bool status = false;swModel = (ModelDoc2)swApp.ActiveDoc;swDrawing = (DrawingDoc)swModel;// Get current sheet swSheet = (Sheet)swDrawing.GetCurrentSheet();sheetProperties = (double[])swSheet.GetProperties();sheetScale = (double)sheetProperties[2] / sheetProperties[3];paperSize = (swDwgPaperSizes_e)swSheet.GetSize(ref width, ref height);// Get number of views on View Palette numViews = 0;viewNames = (object[])swDrawing.GetDrawingPaletteViewNames();// Iterate through views on View Palette // When view name equals "Flat pattern", drop // that view in drawing if (!((viewNames == null))){numViews = viewNames.GetUpperBound(0) - viewNames.GetLowerBound(0);for (i = 0; i <= numViews; i++){viewPaletteName = (string)viewNames[i];if ((viewPaletteName == "Flat pattern")){Debug.Print("Dropping View Palette view named: " + viewPaletteName);swView = (View)swDrawing.DropDrawingViewFromPalette2(viewPaletteName, 0.0, 0.0, 0.0);drawingViewName = swView.GetName2();Debug.Print("Dropped View Palette view into drawing view named: " + drawingViewName);}}}// Activate view and get number of lines in // its boundary box sketch status = swDrawing.ActivateView(drawingViewName);swView = (View)swDrawing.ActiveDrawingView;swDisplayData = (DisplayData)swView.GetSMBoundaryBoxDisplayData();Debug.Print("Number of lines in boundary box of flat-pattern drawing view: " + swDisplayData.GetLineCount());}/// <summary> /// The SldWorks swApp variable is pre-assigned for you. /// </summary> public SldWorks swApp;}}

void EditSheet()

This example shows how to place a note behind a drawing sheet.//---------------------------------------------------------- // Preconditions: // 1. Verify that the specified drawing file to open exists. // 2. Open the Immediate window. // // Postconditions: // 1. Places the selected note, 2012-sm in the drawing template, // behind the drawing sheet. // 2. To verify: // a. Examine the Immediate window. // b. Right-click the drawing and click // Edit Sheet Format. // c. Right-click 2012-sm and examine the // the short-cut menu to verify that Display // Note Behind Sheet is selected. // d. Exit drawing sheet edit mode. // // NOTE: Because this drawing is used elsewhere, do not // save changes. //-----------------------------------------------------------using SolidWorks.Interop.sldworks; using SolidWorks.Interop.swconst; using System.Runtime.InteropServices; using System; using System.Diagnostics;namespace NoteBehindSheetCSharp.csproj { partial class SolidWorksMacro{ public void Main(){ModelDoc2 swModel = default(ModelDoc2);ModelDocExtension swModelDocExt = default(ModelDocExtension);DrawingDoc swDrawing = default(DrawingDoc);SelectionMgr swSelectionMgr = default(SelectionMgr);Note swNote = default(Note);string fileName = null;bool status = false;int errors = 0;int warnings = 0;// Open drawingfileName = "C:\\Users\\Public\\Documents\\SOLIDWORKS\\SOLIDWORKS 2018\\samples\\tutorial\\api\\2012-sm.slddrw";swModel = (ModelDoc2)swApp.OpenDoc6(fileName, (int)swDocumentTypes_e.swDocDRAWING, (int)swOpenDocOptions_e.swOpenDocOptions_Silent, "", ref errors, ref warnings);swDrawing = (DrawingDoc)swModel;// Put drawing template and sheet in edit modeswModelDocExt = (ModelDocExtension)swModel.Extension;status = swModelDocExt.SelectByID2("Sheet1", "SHEET", 0.0399580396732789, 0.20594194865811, 0, false, 0, null, 0);swDrawing.EditTemplate();swDrawing.EditSheet();swModel.ClearSelection2(true);// Select note to place behind the sheetstatus = swModelDocExt.SelectByID2("DetailItem3@Sheet Format1", "NOTE", 0.155548914819136, 0.017885845974329, 0, false, 0, null, 0);swSelectionMgr = (SelectionMgr)swModel.SelectionManager;swNote = (Note)swSelectionMgr.GetSelectedObject6(1, -1);swNote.BehindSheet = true;Debug.Print("Was the selected note placed behind the sheet? " + status);}/// <summary>/// The SldWorks swApp variable is pre-assigned for you./// </summary>public SldWorks swApp;} }

System.object FeatureByName( System.string Name)

//This example shows how to get and set the table anchor of a hole table in a drawing.//----------------------------------------------------------------- // Preconditions: Verify that the specified drawing to open exists. // // Postconditions: // 1. Opens the drawing. // 2. At System.Diagnostics.Debugger.Break(), examine the position // of the hole table in the drawing. // 3. Click the Continue button in the SOLIDWORKS Visual Studio Tools for // Applications IDE. // 4. Sets the position of the hole table's anchor // to the specified location. // 5. Examine the hole table in the drawing. // // NOTE: If prompted, do not save changes when closing the drawing. //------------------------------------------------------------------ using SolidWorks.Interop.sldworks; using SolidWorks.Interop.swconst; using System; using System.Diagnostics;namespace TableAnchorPositionCSharp.csproj {partial class SolidWorksMacro{public void Main(){string filename = null;filename = "C:\\Users\\Public\\Documents\\SOLIDWORKS\\SOLIDWORKS 2018\\samples\\tutorial\\api\\SimpleHole.slddrw";ModelDoc2 model = default(ModelDoc2);int errors = 0;int warnings = 0;model = (ModelDoc2)swApp.OpenDoc6(filename, (int)swDocumentTypes_e.swDocDRAWING, (int)swOpenDocOptions_e.swOpenDocOptions_Silent, "", ref errors, ref warnings);if (model == null)return;System.Diagnostics.Debugger.Break();TableAnnotation swTable = default(TableAnnotation);// If document is a drawing, then continueswitch (model.GetType()){case (int)swDocumentTypes_e.swDocDRAWING:DrawingDoc drw = default(DrawingDoc);drw = (DrawingDoc)model;// Get the current sheetSheet drwSheet = default(Sheet);drwSheet = (Sheet)drw.GetCurrentSheet();// Select the Sheet2 featureModelDocExtension modeldocext = default(ModelDocExtension);bool status = false;modeldocext = (ModelDocExtension)model.Extension;status = modeldocext.SelectByID2("Sheet2", "SHEET", 0, 0, 0, false, 0, null, 0);// Get the views on Sheet2object[] views = null;views = (object[])drwSheet.GetViews();foreach (object vView in views){View drwView = default(View);drwView = (View)vView;Feature viewFeature = default(Feature);viewFeature = (Feature)drw.FeatureByName(drwView.Name);// Traverse the features in the viewFeature subFeature = default(Feature);subFeature = (Feature)viewFeature.GetFirstSubFeature();// If the feature is HoleTableFeat, then get the table annotationswhile (!(subFeature == null)){if (subFeature.GetTypeName2() == "HoleTableFeat"){HoleTable swHoleTable = default(HoleTable);swHoleTable = (HoleTable)subFeature.GetSpecificFeature2();object[] holeTables = null;holeTables = (object[])swHoleTable.GetTableAnnotations();// If the annotation is a hole table, then continueif ((holeTables != null)){foreach (object table in holeTables){swTable = (TableAnnotation)table;// If the hole table is anchored, then continueif (swTable.Type == (int)swTableAnnotationType_e.swTableAnnotation_HoleChart){if (swTable.Anchored != false){TableAnchor holeTableAnchor = default(TableAnchor);holeTableAnchor = (TableAnchor)drwView.Sheet.get_TableAnchor((int)swTableAnnotationType_e.swTableAnnotation_HoleChart);// Get the position of the table anchordouble[] anchorPosition = null;anchorPosition = (double[])holeTableAnchor.Position;// Determine type of table anchorswBOMConfigurationAnchorType_e newCorner = default(swBOMConfigurationAnchorType_e);string corner = null;switch (swTable.AnchorType){case (int)swBOMConfigurationAnchorType_e.swBOMConfigurationAnchor_BottomLeft:corner = " Bottom-left ";newCorner = swBOMConfigurationAnchorType_e.swBOMConfigurationAnchor_TopRight;break;case (int)swBOMConfigurationAnchorType_e.swBOMConfigurationAnchor_BottomRight:corner = " Bottom-right ";newCorner = swBOMConfigurationAnchorType_e.swBOMConfigurationAnchor_TopLeft;break;case (int)swBOMConfigurationAnchorType_e.swBOMConfigurationAnchor_TopLeft:corner = " Top-left ";newCorner = swBOMConfigurationAnchorType_e.swBOMConfigurationAnchor_BottomRight;break;case (int)swBOMConfigurationAnchorType_e.swBOMConfigurationAnchor_TopRight:corner = " Top-right ";newCorner = swBOMConfigurationAnchorType_e.swBOMConfigurationAnchor_BottomLeft;break;}swTable.AnchorType = (int)newCorner;// Set the new position of the table anchordouble[] dNewPosition = new double[2];dNewPosition[0] = 0.0;dNewPosition[1] = 0.0;holeTableAnchor.Position = dNewPosition;}}}}}subFeature = (Feature)subFeature.GetNextSubFeature();}}break;case (int)swDocumentTypes_e.swDocASSEMBLY:case (int)swDocumentTypes_e.swDocPART:break;}}/// <summary>/// The SldWorks swApp variable is pre-assigned for you./// </summary>public SldWorks swApp;} }

System.bool GenerateViewPaletteViews( System.string FileName)

//This example shows how to get and set whether to hide cutting line shoulders in a //section view.//-------------------------------------------------------------------------- // Preconditions: // 1. Verify that the part and templates exist. // 2. Open the Immediate window. // // Postconditions: // 1. Opens the part. // 2. Creates a drawing of the part. // 3. Creates a section view. // 4. Gets and sets whether to hide cutting line shoulders in the section // view. // 5. Examine the Immediate window. // // NOTE: Because the part is used elsewhere, do not save it or the drawing. //-------------------------------------------------------------------------- using SolidWorks.Interop.sldworks; using SolidWorks.Interop.swconst; using System.Runtime.InteropServices; using System; using System.Diagnostics;namespace Macro1CSharp.csproj {public partial class SolidWorksMacro{public void Main(){ModelDoc2 swModel = default(ModelDoc2);DrawingDoc swDrawing = default(DrawingDoc);Sheet swSheet = default(Sheet);View swView = default(View);ModelDocExtension swModelDocExt = default(ModelDocExtension);SketchSegment swSketchSegment = default(SketchSegment);SketchManager swSketchMgr = default(SketchManager);DrSection swSectionView = default(DrSection);bool status = false;int errors = 0;int warnings = 0;string fileName = null;double swSheetWidth = 0;double swSheetHeight = 0;string drawingTemplate = null;string sheetTemplate = null;//Open partfileName = "C:\\Users\\Public\\Documents\\SOLIDWORKS\\SOLIDWORKS 2018\\samples\\tutorial\\api\\cam roller.sldprt";swModel = (ModelDoc2)swApp.OpenDoc6(fileName, (int)swDocumentTypes_e.swDocPART, (int)swOpenDocOptions_e.swOpenDocOptions_Silent, "", ref errors, ref warnings);//Create drawing of partswSheetWidth = 1.189;swSheetHeight = 0.841;drawingTemplate = "C:\\ProgramData\\SolidWorks\\SOLIDWORKS 2017\\templates\\Drawing.drwdot";swDrawing = (DrawingDoc)swApp.NewDocument(drawingTemplate, (int)swDwgPaperSizes_e.swDwgPapersUserDefined, swSheetWidth, swSheetHeight);swSheet = (Sheet)swDrawing.GetCurrentSheet();swSheet.SetProperties2((int)swDwgPaperSizes_e.swDwgPapersUserDefined, (int)swDwgTemplates_e.swDwgTemplateCustom, 1, 2, false, swSheetWidth, swSheetHeight, true);sheetTemplate = "C:\\ProgramData\\SolidWorks\\SOLIDWORKS 2017\\lang\\english\\sheetformat\\a0 - iso.slddrt";swSheet.SetTemplateName(sheetTemplate);swSheet.ReloadTemplate(true);status = swDrawing.GenerateViewPaletteViews(fileName);swView = (View)swDrawing.DropDrawingViewFromPalette2("*Left", 0.580930433566434, 0.431525272727273, 0);//Create section viewswDrawing = (DrawingDoc)swApp.ActiveDoc;status = swDrawing.ActivateView("Drawing View1");swModel.ClearSelection2(true);swModel = (ModelDoc2)swDrawing;swSketchMgr = (SketchManager)swModel.SketchManager;swSketchSegment = (SketchSegment)swSketchMgr.CreateLine(0.0, 0.0, 0.0, 0.012168, 0.021283, 0.0);swSketchSegment = (SketchSegment)swSketchMgr.CreateLine(0.0, 0.0, 0.0, 0.024347, -0.010966, 0.0);swModelDocExt = (ModelDocExtension)swModel.Extension;status = swModelDocExt.SelectByID2("Line1", "SKETCHSEGMENT", 0.690604633175108, 0.625483883858213, 0, false, 0, null, 0);status = swModelDocExt.SelectByID2("Line2", "SKETCHSEGMENT", 0.747211061353527, 0.357889859742052, 0, true, 0, null, 0);swView = (View)swDrawing.CreateSectionViewAt5(0.676815388637685, 0.116110180826413, 0, "A", (int)swCreateSectionViewAtOptions_e.swCreateSectionView_OffsetSection, null, 0);status = swDrawing.ActivateView("Drawing View2");swModel.ClearSelection2(true);//Get section view and get and set whether to hide cutting line shouldersswSectionView = (DrSection)swView.GetSection();if (swSectionView.CuttingLineShoulders){Debug.Print("Hide cutting line shoulders = True");Debug.Print("Setting hide cutting line shoulders to False");swSectionView.CuttingLineShoulders = false;Debug.Print(" Hide cutting line shoulders = " + swSectionView.CuttingLineShoulders);}else{Debug.Print("Hide cutting line shoulders = False");Debug.Print("Setting hide cutting line shoulders to True");swSectionView.CuttingLineShoulders = true;Debug.Print(" Hide cutting line shoulders = " + swSectionView.CuttingLineShoulders);}}/// <summary>/// The SldWorks swApp variable is pre-assigned for you./// </summary>public SldWorks swApp;} }

System.object GetCurrentSheet()

This example shows how to create a title block in a drawing, if one does not already exist, and how to get the notes from an existing title block in a drawing.//-------------------------------------------------------- // Preconditions: Drawing document is open. // // Postconditions: If the drawing contains a title block, then // the notes of that block are printed // to the Immediate window. If not, // a title block is created. //-------------------------------------------------------using SolidWorks.Interop.sldworks; using SolidWorks.Interop.swconst; using System; using System.Diagnostics; using System.Runtime.InteropServices; namespace ExampleCS.csproj {public partial class SolidWorksMacro{ModelDoc2 swModel;ModelDocExtension swExt;SelectionMgr swSelMgr;View swView;DrawingDoc swDraw;public void Main(){swModel = swApp.ActiveDoc as ModelDoc2;swExt = swModel.Extension;swSelMgr = swModel.SelectionManager as SelectionMgr;swDraw = swModel as DrawingDoc;Sheet swSheet;swSheet = swDraw.GetCurrentSheet() as Sheet;TitleBlock swTitleBlock;swTitleBlock = swSheet.TitleBlock;object[] vNotes;int i;// Create title block if one doesn't existif (swTitleBlock == null){swView = swDraw.GetFirstView() as View;vNotes = (object[])swView.GetNotes();// Add first two notes to the title blockDispatchWrapper[] notesArray = new DispatchWrapper[2];notesArray[0] = new DispatchWrapper(vNotes[0]);notesArray[1] = new DispatchWrapper(vNotes[1]);swTitleBlock = swSheet.InsertTitleBlock(notesArray);}vNotes = (object[])swTitleBlock.GetNotes();for (i = 0; i < vNotes.Length; i++){Note swNote;swNote = (Note)vNotes[i];Debug.Print("Name: " + swNote.GetName());Debug.Print("Value: " + swNote.GetText());}}/// <summary>/// The SldWorks swApp variable is pre-assigned for you./// </summary>public SldWorks swApp;} }

System.object GetFirstView()

//This example shows how to get the drawing view's bounding box, position, and position //lock status.//--------------------------------------------------------- // Preconditions: // 1. Verify that the drawing document to open exists. // 2. Open the Immediate window. // // Postconditions: // 1. Opens the specified drawing document. // 2. Gets each drawing view's: // * origin's x and y positions relative // to the drawing sheet origin // * bounding box // * position lock status // 3. Examine the Immediate window. // // NOTE: Because the drawing is used elsewhere, do not save // changes. //---------------------------------------------------------- using SolidWorks.Interop.sldworks; using SolidWorks.Interop.swconst; using System.Runtime.InteropServices; using System; using System.Diagnostics;namespace Macro1.csproj {public partial class SolidWorksMacro{public void Main(){DrawingDoc swDraw = default(DrawingDoc);View swView = default(View);double[] outline = null;double[] pos = null;string fileName = null;int errors = 0;int warnings = 0;fileName = "C:\\Users\\Public\\Documents\\SOLIDWORKS\\SOLIDWORKS 2018\\samples\\tutorial\\api\\replaceview.slddrw";swDraw = (DrawingDoc)swApp.OpenDoc6(fileName, (int)swDocumentTypes_e.swDocDRAWING, (int)swOpenDocOptions_e.swOpenDocOptions_Silent, "", ref errors, ref warnings);swView = (View)swDraw.GetFirstView();while ((swView != null)){outline = (double[])swView.GetOutline();pos = (double[])swView.Position;Debug.Print("View = " + swView.Name);Debug.Print(" X and Y positions = (" + pos[0] * 1000.0 + ", " + pos[1] * 1000.0 + ") mm");Debug.Print(" X and Y bounding box minimums = (" + outline[0] * 1000.0 + ", " + outline[1] * 1000.0 + ") mm");Debug.Print(" X and Y bounding box maximums = (" + outline[2] * 1000.0 + ", " + outline[3] * 1000.0 + ") mm");Debug.Print(" Position locked?" + swView.PositionLocked);swView = (View)swView.GetNextView();}}/// <summary>/// The SldWorks swApp variable is pre-assigned for you./// </summary>public SldWorks swApp;} }

System.object GetSheetNames()

//This example shows how to modify and reload a sheet format template.//------------------------------------------------------------ // Preconditions: // 1. Make a copy of: // C:\ProgramData\SolidWorks\SOLIDWORKS version\lang\english\sheetformat\a0 - iso.slddrt. // 2. Create a new blank drawing using standard sheet size AO (ISO). // 3. Add another blank sheet to the drawing, for a total of two sheets. // 4. Open the Immediate window. // // Postconditions: // 1. Modifies the sheet format template to include a new // note. // 2. Examine Sheet1, Sheet2, and the Immediate window. // 3. Delete: // C:\ProgramData\SolidWorks\SOLIDWORKS version\lang\english\sheetformat\a0 - iso.slddrt. // 4. Rename the copy that you made in Preconditions step 1 to: // C:\ProgramData\SolidWorks\SOLIDWORKS version\lang\english\sheetformat\a0 - iso.slddrt. //------------------------------------------------------------ using SolidWorks.Interop.sldworks; using SolidWorks.Interop.swconst; using System.Runtime.InteropServices; using System; using System.Diagnostics;namespace Macro1CSharp.csproj {public partial class SolidWorksMacro{const bool TEST_APPLY_CHANGES_TO_ALL = true;private string GetReloadResult(swReloadTemplateResult_e result){string functionReturnValue = null;switch (result){case (swReloadTemplateResult_e)swReloadTemplateResult_e.swReloadTemplate_Success:functionReturnValue = "Success";break;case (swReloadTemplateResult_e)swReloadTemplateResult_e.swReloadTemplate_UnknownError:functionReturnValue = "FAIL - Unknown Error";break;case (swReloadTemplateResult_e)swReloadTemplateResult_e.swReloadTemplate_FileNotFound:functionReturnValue = "FAIL - File Not Found";break;case (swReloadTemplateResult_e)swReloadTemplateResult_e.swReloadTemplate_CustomSheet:functionReturnValue = "FAIL - Custom Sheet";break;case (swReloadTemplateResult_e)swReloadTemplateResult_e.swReloadTemplate_ViewOnly:functionReturnValue = "FAIL - View Only";break;default:functionReturnValue = "FAIL - <unrecognized error code - " + result + ">";break;}return functionReturnValue;}public void Main(){ModelDoc2 swModel = default(ModelDoc2);swModel = (ModelDoc2)swApp.ActiveDoc;if (swModel == null){Debug.Print("Create a new empty drawing and add a second sheet to the drawing.");return;}if (swModel.GetType() != (int)swDocumentTypes_e.swDocDRAWING)return;DrawingDoc swDrwng = default(DrawingDoc);swDrwng = (DrawingDoc)swModel;//Get the current sheetSheet activeSheet = default(Sheet);activeSheet = (Sheet)swDrwng.GetCurrentSheet();Debug.Print("Active sheet name: " + activeSheet.GetName());//Get the sheet format templatestring templateName = null;templateName = activeSheet.GetTemplateName();Debug.Print("Sheet format template name to modify: " + templateName);swDrwng.EditTemplate();//Add a new note to the sheet format templateNote swNote = default(Note);swNote = (Note)swModel.InsertNote("A New Note");Annotation swAnno = default(Annotation);swAnno = (Annotation)swNote.GetAnnotation();swAnno.SetPosition2(0, 0.2, 0);TextFormat txtFormat = default(TextFormat);txtFormat = (TextFormat)swAnno.GetTextFormat(0);txtFormat.BackWards = (txtFormat.BackWards == false);txtFormat.Bold = true;txtFormat.CharHeightInPts = 10 * txtFormat.CharHeightInPts;swAnno.SetTextFormat(0, false, txtFormat);swDrwng.EditSheet();//At this point, the active sheet's format has changed if (TEST_APPLY_CHANGES_TO_ALL){//Save sheet format back to original sheet format templateactiveSheet.SaveFormat(templateName);//Reload all other sheets from the updated sheet format templateobject[] vSheetNames = null;vSheetNames = (object[])swDrwng.GetSheetNames();foreach (string vName in vSheetNames){if (vName != (string)activeSheet.GetName()){Debug.Print("Other sheet name: " + vName);Sheet otherSheet = default(Sheet);otherSheet = (Sheet)swDrwng.get_Sheet(vName);if (otherSheet.GetTemplateName() == templateName){swReloadTemplateResult_e reloadResult = default(swReloadTemplateResult_e);//Keep modifications and and reload all other elements//from original sheet format templatereloadResult = (swReloadTemplateResult_e)otherSheet.ReloadTemplate(true);//Discard modifications and reload all elements from//original sheet format template//reloadResult = otherSheet.ReloadTemplate(False) Debug.Print("Reload sheet format for <" + otherSheet.GetName() + ">: " + GetReloadResult(reloadResult));}}}swDrwng.ActivateSheet(activeSheet.GetName());}else{//Discard the changes and reload the original sheet format templateswReloadTemplateResult_e reloadResult = default(swReloadTemplateResult_e);reloadResult = (swReloadTemplateResult_e)activeSheet.ReloadTemplate(false);Debug.Print("Done - " + GetReloadResult(reloadResult));}}/// <summary>/// The SldWorks swApp variable is pre-assigned for you./// </summary>public SldWorks swApp;} }

System.int GetViewCount()

This example shows how to get all of the views and notes in a drawing document.'-------------------------------------------- ' Preconditions: Drawing document is open and at least ' one view has some notes. ' ' Postconditions: None ' ' NOTE: IDrawingDoc::GetViews returns both sheets and views. '----------------------------------------------Option Explicit Dim swApp As SldWorks.SldWorks Dim swModel As SldWorks.ModelDoc2 Dim swDrawDoc As SldWorks.DrawingDoc Dim swView As SldWorks.View Dim swNote As SldWorks.Note Dim sheetCount As Long Dim viewCount As Long Dim noteCount As Long Dim i As LongSub main()Set swApp = Application.SldWorks Set swModel = swApp.ActiveDoc Set swDrawDoc = swModel Dim viewCount As Long viewCount = swDrawDoc.GetViewCount Dim ss As Variant ss = swDrawDoc.GetViews For sheetCount = LBound(ss) To UBound(ss)Dim vv As Variantvv = ss(sheetCount)For viewCount = LBound(vv) To UBound(vv)Debug.Print (vv(viewCount).GetName2())Dim vNotes As VariantnoteCount = vv(viewCount).GetNoteCountIf noteCount > 0 ThenvNotes = vv(viewCount).GetNotesFor i = 0 To noteCount - 1Debug.Print " Note text: " & vNotes(i).GetTextNextEnd IfNext viewCount Next sheetCount End Sub

void HideEdge()

//This example shows how to hide and then show all of the edges in the root component in //a drawing view.//--------------------------------------------------------------------------- // Preconditions: // 1. Verify that the specified drawing document to open exists. // 2. Open the Immediate window. // // Postconditions: // 1. Opens the specified drawing document. // 2. Hides and then shows all edges in the root component in // Drawing View1. // 3. Examine the drawing and Immediate window. //---------------------------------------------------------------------------- using Microsoft.VisualBasic; using System; using System.Collections; using System.Collections.Generic; using System.Data; using System.Diagnostics; using SolidWorks.Interop.sldworks; using SolidWorks.Interop.swconst; using System.Runtime.InteropServices; namespace HideShowEdges_CSharp.csproj {partial class SolidWorksMacro{ModelDoc2 swModel;DrawingDoc swDraw;DocumentSpecification swDocSpecification;Sheet swSheet;View swView;DrawingComponent swDrawingComponent;Component2 swComponent;Entity swEntity;object[] vEdges;bool bRet;int i;public void Main(){// Specify the drawing to openswDocSpecification = (DocumentSpecification)swApp.GetOpenDocSpec("C:\\Users\\Public\\Documents\\SOLIDWORKS\\SOLIDWORKS 2018\\samples\\tutorial\\advdrawings\\foodprocessor.SLDDRW");swModel = (ModelDoc2)swApp.ActiveDoc;if (swModel == null){swModel = swApp.OpenDoc7(swDocSpecification);}swModel = (ModelDoc2)swApp.ActiveDoc;swDraw = (DrawingDoc)swModel;// Get the current sheetswSheet = (Sheet)swDraw.GetCurrentSheet();Debug.Print(swSheet.GetName());// Select Drawing View1bRet = swModel.Extension.SelectByID2("Drawing View1", "DRAWINGVIEW", 0.0, 0.0, 0.0, true, 0, null, (int)swSelectOption_e.swSelectOptionDefault);swView = (View)((SelectionMgr)swModel.SelectionManager).GetSelectedObject6(1, -1);// Print the drawing view name and get the component in the drawing viewDebug.Print(swView.GetName2());swDrawingComponent = swView.RootDrawingComponent;swComponent = swDrawingComponent.Component;// Get the component's visible entities in the drawing viewint eCount = 0;eCount = swView.GetVisibleEntityCount2(swComponent, (int)swViewEntityType_e.swViewEntityType_Edge);vEdges = (object[])swView.GetVisibleEntities2(swComponent, (int)swViewEntityType_e.swViewEntityType_Edge);Debug.Print("Number of edges found: " + eCount);// Hide all of the visible edges in the drawing viewfor (i = 0; i <= eCount - 1; i++){swEntity = (Entity)vEdges[i];swEntity.Select4(true, null);swDraw.HideEdge();}// Clear all selectionsswModel.ClearSelection2(true);// Show all hidden edgesswView.HiddenEdges = vEdges;}public SldWorks swApp;} }

void HideShowDrawingViews()

//This example shows how to set the display mode of a drawing view.//---------------------------------------------------------------------------- // Preconditions: // 1. Open a drawing document. // 2. Select a view. // 3. Inspect the graphics area and press F5 six times. // // Postconditions: The display mode, hide/show, and suppression // settings for the document are modified as specified. //----------------------------------------------------------------------------using Microsoft.VisualBasic; using System; using System.Collections; using System.Collections.Generic; using System.Data; using System.Diagnostics; using SolidWorks.Interop.sldworks; using SolidWorks.Interop.swconst; using System.Runtime.InteropServices; namespace DisplayHiddenLinesinDrawing_CSharp.csproj {partial class SolidWorksMacro{public void Main(){ModelDoc2 swModel = default(ModelDoc2);DrawingDoc swDraw = default(DrawingDoc);swModel = (ModelDoc2)swApp.ActiveDoc;swDraw = (DrawingDoc)swModel;swDraw.ViewDisplayHidden();System.Diagnostics.Debugger.Break();swDraw.ViewDisplayHiddengreyed();System.Diagnostics.Debugger.Break();swDraw.ViewDisplayWireframe();System.Diagnostics.Debugger.Break();swDraw.ViewDisplayShaded();System.Diagnostics.Debugger.Break();// Suppress viewswDraw.SuppressView();System.Diagnostics.Debugger.Break();// Display an X where the view was suppressedswDraw.HideShowDrawingViews();System.Diagnostics.Debugger.Break();// Unsuppress viewswDraw.UnsuppressView();}public SldWorks swApp;} }

Centerline InsertCenterLine2()

//This example shows how to get all of the centerlines in all of the drawing views in a //drawing.//------------------------------------ // Preconditions: // 1. Verify that the drawing document to open exists. // 2. Open the Immediate window. // // Postconditions: // 1. Opens the specified drawing. // 2. Inserts a centerline annotation. // 3. Prints the path and file name of the drawing document // to the Immediate window. // 4. Iterates the sheet and drawing view, prints their names, and // prints the name of the centerline annotation to // the Immediate window. // 5. Examine the Immediate window. // // NOTE: Because this drawing document is used elsewhere, // do not save any changes. //------------------------------------ using SolidWorks.Interop.sldworks; using SolidWorks.Interop.swconst; using System.Runtime.InteropServices; using System; using System.Diagnostics;namespace CenterLinesCSharp.csproj {public partial class SolidWorksMacro{public void Main(){ModelDoc2 swModel = default(ModelDoc2);ModelDocExtension swModelDocExt = default(ModelDocExtension);DrawingDoc swDrawing = default(DrawingDoc);View swView = default(View);Centerline swCenterLine = default(Centerline);Annotation swAnnotation = default(Annotation);bool status = false;int errors = 0;int warnings = 0;string fileName = null;fileName = "C:\\Users\\Public\\Documents\\SOLIDWORKS\\SOLIDWORKS 2018\\samples\\tutorial\\api\\cylinder20.SLDDRW";swModel = (ModelDoc2)swApp.OpenDoc6(fileName, (int)swDocumentTypes_e.swDocDRAWING, (int)swOpenDocOptions_e.swOpenDocOptions_Silent, "", ref errors, ref warnings);swDrawing = (DrawingDoc)swModel;swModelDocExt = (ModelDocExtension)swModel.Extension;status = swDrawing.ActivateView("Drawing View1");status = swModelDocExt.SelectByID2("cylinder20-9@Drawing View1", "COMPONENT", 0, 0, 0, false, 0, null, 0);status = swModelDocExt.SelectByID2("", "FACE", 0.513454307125032, 0.454946591641617, 250.013794595267, false, 0, null, 0);swCenterLine = (Centerline)swDrawing.InsertCenterLine2();swModel.ClearSelection2(true);swView = (View)swDrawing.GetFirstView();Debug.Print("File = " + swModel.GetPathName());while ((swView != null)){Debug.Print(" View = " + swView.GetName2());swCenterLine = (Centerline)swView.GetFirstCenterLine();while ((swCenterLine != null)){swAnnotation = (Annotation)swCenterLine.GetAnnotation();Debug.Print(" Name = " + swAnnotation.GetName());swCenterLine = swCenterLine.GetNext();}swView = (View)swView.GetNextView();}}/// <summary>/// The SldWorks swApp variable is pre-assigned for you./// </summary>public SldWorks swApp;} }

System.bool InsertCircularNotePattern(?
? ?System.double ArcRadius,
? ?System.double ArcAngle,
? ?System.int PatternNum,
? ?System.double PatternSpacing,
? ?System.bool PatternRotate,
? ?System.string DeleteInstances)

This example shows how to insert linear and circular note patterns in a drawing.//--------------------------------------------------------- // // Preconditions: Verify that the specified drawing document // to open exists. // // Postconditions: // 1. Inserts a note in the drawing and selects the note. // 2. Inserts a linear note pattern (2 instances, including // the original note) in the drawing. // 3. Inserts a circular note pattern (4 instances, including // the original note) in the drawing. // // NOTE: Because the model is used elsewhere, do not save // changes. //---------------------------------------------------------- using SolidWorks.Interop.sldworks; using SolidWorks.Interop.swconst; using System;namespace InsertLinearCircularNotePatternsCSharp.csproj {partial class SolidWorksMacro{public void Main(){ModelDoc2 swModel = default(ModelDoc2);DrawingDoc swDrawingDoc = default(DrawingDoc);Note swNote = default(Note);bool status = false;int errors = 0;int warnings = 0;// Open drawing document, activate sheet, and make it the active documentswModel = (ModelDoc2)swApp.OpenDoc6("C:\\Users\\Public\\Documents\\SOLIDWORKS\\SOLIDWORKS 2018\\samples\\tutorial\\advdrawings\\foodprocessor.slddrw", 3, 0, "", ref errors, ref warnings);swApp.ActivateDoc2("foodprocessor - Sheet1", false, ref errors);swDrawingDoc = (DrawingDoc)swApp.ActiveDoc;// Insert a noteswNote = (Note)swModel.InsertNote("Test inserting linear and circular note patterns");// Select the just-inserted notestatus = swModel.Extension.SelectByID2("DetailItem174@Sheet1", "NOTE", 0.2558797881203, 0.3700526, 0, false, 0, null, 0);// Create a linear note pattern using the selected notestatus = swDrawingDoc.InsertLinearNotePattern(2, 1, 0.01, 0.01, 0.7853981633975, 1.570796326795, "");// Create a circular pattern using the selected notestatus = swDrawingDoc.InsertCircularNotePattern(0.075, 4.03202193189, -4, 1.570796326795, true, "");}/// <summary>/// The SldWorks swApp variable is pre-assigned for you./// </summary>public SldWorks swApp;} }

System.object InsertRevisionCloud(?System.int CloudShape)

//This example shows how to insert revision clouds into a drawing and access revision //cloud data.//---------------------------------------------------------------------------- // Preconditions: Open public_documents\samples\tutorial\api\resetsketchvisibility.slddrw. // // Postconditions: // 1. Inserts an elliptical revision cloud in the drawing. // 2. Examine the Immediate window. // // NOTE: Because the drawing is used elsewhere, do not save changes. // --------------------------------------------------------------------------- using Microsoft.VisualBasic; using System; using System.Collections; using System.Collections.Generic; using System.Data; using System.Diagnostics; using SolidWorks.Interop.sldworks; using SolidWorks.Interop.swconst; using System.Runtime.InteropServices; namespace InsertRevisionCloud_CSharp.csproj {partial class SolidWorksMacro{DrawingDoc Part;RevisionCloud RevCloud;Annotation RevCloudAnno;bool boolstatus;public void Main(){Part = (DrawingDoc)swApp.ActiveDoc;boolstatus = Part.ActivateView("Drawing View1");// Create a revision cloud with an elliptical shapeRevCloud = (RevisionCloud)Part.InsertRevisionCloud(1);if ((RevCloud != null)){RevCloudAnno = (Annotation)RevCloud.GetAnnotation();if ((RevCloudAnno != null)){// Position the center of the elliptical revision cloudboolstatus = RevCloudAnno.SetPosition(0.270847371964905, 0.553263328912467, 0);RevCloud.ArcRadius = 0.00508;// Create a path point on the corner of an ellipse-inscribed rectangleboolstatus = RevCloud.SetPathPointAtIndex(-1, 0.378419710263212, 0.511051398694144, 0);// Close the revision cloud pathboolstatus = RevCloud.Finalize();}}}public SldWorks swApp;} }

TableAnnotation InsertTableAnnotation2(?
? ?System.bool UseAnchorPoint,
? ?System.double X,
? ?System.double Y,
? ?System.int AnchorType,
? ?System.string TableTemplate,
? ?System.int Rows,
? ?System.int Columns)
?

This example shows how to get a general table feature and some of its table annotation data.//----------------------------------------------------------------- // Preconditions: // 1. Verify that the specified drawing document to open exists. // 2. Open the Immediate window. // // Postconditions: // 1. Opens the specified drawing document. // 2. Inserts a table annotation. // 3. Gets the general table feature. // 4. Prints the name of the general table feature and // some of its annotation table data the Immediate window. // 5. Examine the Immediate window. // // NOTE: Because the drawing document is used elsewhere, do not // save changes. //-----------------------------------------------------------------using SolidWorks.Interop.sldworks; using SolidWorks.Interop.swconst; using System.Runtime.InteropServices; using System; using System.Diagnostics;namespace GeneralTableFeatureCSharp.csproj {public partial class SolidWorksMacro{ public void Main(){ModelDoc2 swModel = default(ModelDoc2);DrawingDoc swDrawing = default(DrawingDoc);bool status = false;int errors = 0;int warnings = 0;string fileName = null;TableAnnotation swTableAnnotation = default(TableAnnotation);GeneralTableFeature swGeneralTableFeature = default(GeneralTableFeature);SelectionMgr swSelectionMgr = default(SelectionMgr);ModelDocExtension swModelDocExt = default(ModelDocExtension);Feature swFeature = default(Feature);int nbrTableAnnotations = 0;object[] tableAnnotations = null;int i = 0;bool anchorAttached = false;int anchorType = 0;int nbrColumns = 0;int nbrRows = 0;//Open drawing documentfileName = "C:\\Users\\Public\\Documents\\SOLIDWORKS\\SOLIDWORKS 2018\\samples\\tutorial\\api\\assem20.slddrw";swModel = (ModelDoc2)swApp.OpenDoc6(fileName, (int)swDocumentTypes_e.swDocDRAWING, (int)swOpenDocOptions_e.swOpenDocOptions_Silent, "", ref errors, ref warnings);//Insert table annotationswDrawing = (DrawingDoc)swModel;swTableAnnotation = (TableAnnotation)swDrawing.InsertTableAnnotation2(false, 0.0275123456559767, 0.132124518483965, 1, "", 2, 2);if ((swTableAnnotation != null)){swTableAnnotation.BorderLineWeight = 0;swTableAnnotation.GridLineWeight = 0;}//Select and get general table featureswModelDocExt = (ModelDocExtension)swModel.Extension;status = swModelDocExt.SelectByID2("General Table1", "GENERALTABLEFEAT", 0, 0, 0, false, 0, null, 0);swSelectionMgr = (SelectionMgr)swModel.SelectionManager;swGeneralTableFeature = (GeneralTableFeature)swSelectionMgr.GetSelectedObject6(1, -1);swFeature = (Feature)swGeneralTableFeature.GetFeature();Debug.Print("General table feature name: " + swFeature.Name);//Get general table feature's annotation datanbrTableAnnotations = swGeneralTableFeature.GetTableAnnotationCount();Debug.Print("Number of annotations = " + nbrTableAnnotations);tableAnnotations = (object[])swGeneralTableFeature.GetTableAnnotations();for (i = 0; i <= (nbrTableAnnotations - 1); i++){swTableAnnotation = (TableAnnotation)tableAnnotations[i];anchorAttached = swTableAnnotation.Anchored;Debug.Print("Table anchored = " + anchorAttached);anchorType = swTableAnnotation.AnchorType;Debug.Print("Anchor type = " + anchorType);nbrColumns = swTableAnnotation.ColumnCount;Debug.Print("Number of columns = " + nbrColumns);nbrRows = swTableAnnotation.RowCount;Debug.Print("Number of rows = " + nbrRows);}}/// <summary>/// The SldWorks swApp variable is pre-assigned for you./// </summary>public SldWorks swApp;} }

void IsolateChangedDimensions()

This example shows how to isolate a changed dimension.//------------------------------------------------------ // Preconditions: The specified drawing and part // documents exist. // // Postconditions: // 1. Opens the drawing document. // 2. Sets the system option to display // changed dimensions in the color selected // for Tools > Options > System Options > // Colors > Color scheme settings > // Drawings, Changed dimensions. // 3. Saves and closes the drawing document. // 4. Opens the part document of the drawing document. // 5. Changes a dimension. // 6. Saves and closes the part document. // 7. Opens the previously saved drawing document. // 8. Examine the drawing document to verify that // the changed dimension is displayed in the // changed-dimension color. Place your cursor over // the dimension to see its previous value. //------------------------------------------------------- using SolidWorks.Interop.sldworks; using SolidWorks.Interop.swconst; using System;namespace IsolateChangedDimensionsDrawingDocCSharp.csproj {partial class SolidWorksMacro{public void Main(){ModelDoc2 swModel = default(ModelDoc2);ModelDocExtension swModelDocExt = default(ModelDocExtension);DrawingDoc swDrawing = default(DrawingDoc);string fileName = null;string saveFileName = null;int errors = 0;int warnings = 0;bool status = false;// Open drawing document fileName = "C:\\Users\\Public\\Documents\\SOLIDWORKS\\SOLIDWORKS 2018\\samples\\tutorial\\api\\box.slddrw";swModel = (ModelDoc2)swApp.OpenDoc6(fileName, (int)swDocumentTypes_e.swDocDRAWING, (int)swOpenDocOptions_e.swOpenDocOptions_Silent, "", ref errors, ref warnings);// Isolate changed dimensions // Equivalent to selecting Tools > Options > System Options > Colors > // Use specified color for changed drawing dimensions on openswApp.SetUserPreferenceToggle((int)swUserPreferenceToggle_e.swUseChangedDimensions, true);swDrawing = (DrawingDoc)swModel;swDrawing.IsolateChangedDimensions();// Save drawing document to another namesaveFileName = "C:\\Users\\Public\\Documents\\SOLIDWORKS\\SOLIDWORKS 2018\\samples\\tutorial\\api\\box_changed.slddrw";swModelDocExt = (ModelDocExtension)swModel.Extension;status = swModelDocExt.SaveAs(saveFileName, (int)swSaveAsVersion_e.swSaveAsCurrentVersion, (int)swSaveAsOptions_e.swSaveAsOptions_Silent, null, ref errors, ref warnings);swApp.CloseDoc(saveFileName);// Open the part document referenced by the drawing document,// change a dimension, and save the documentfileName = "C:\\Users\\Public\\Documents\\SOLIDWORKS\\SOLIDWORKS 2018\\samples\\tutorial\\api\\box.sldprt";swModel = (ModelDoc2)swApp.OpenDoc6(fileName, (int)swDocumentTypes_e.swDocPART, (int)swOpenDocOptions_e.swOpenDocOptions_Silent, "", ref errors, ref warnings);swModelDocExt = (ModelDocExtension)swModel.Extension;status = swModelDocExt.SelectByID2("Sketch1", "SKETCH", 0, 0, 0, true, 0, null, 0);status = swModelDocExt.SelectByID2("D2@Sketch1@box.SLDPRT", "DIMENSION", -0.03613329319351, -0.02215939491444, 0.02938582119709, true, 0, null, 0);Dimension swDimension = default(Dimension);swDimension = (Dimension)swModel.Parameter("D2@Sketch1");swDimension.SystemValue = 0.185;swModel.ClearSelection2(true);status = swModel.EditRebuild3();status = swModel.Save3((int)swSaveAsOptions_e.swSaveAsOptions_Silent, ref errors, ref warnings);swApp.CloseDoc(fileName);// Open the previously saved drawing document// and place your cursor on the changed dimension,// which displays in the color specified for// changed dimensions, to see its previous valueswModel = (ModelDoc2)swApp.OpenDoc6(saveFileName, (int)swDocumentTypes_e.swDocDRAWING, (int)swOpenDocOptions_e.swOpenDocOptions_Silent, "", ref errors, ref warnings);}/// <summary>/// The SldWorks swApp variable is pre-assigned for you./// </summary>public SldWorks swApp;} }

System.bool NewSheet4(?
? ?System.string Name,
? ?System.int PaperSize,
? ?System.int TemplateIn,
? ?System.double Scale1,
? ?System.double Scale2,
? ?System.bool FirstAngle,
? ?System.string TemplateName,
? ?System.double Width,
? ?System.double Height,
? ?System.string PropertyViewName,
? ?System.double ZoneLeftMargin,
? ?System.double ZoneRightMargin,
? ?System.double ZoneTopMargin,
? ?System.double ZoneBottomMargin,
? ?System.int ZoneRow,
? ?System.int ZoneCol)

This example shows how to create a drawing sheet with zones, modify the zones in the drawing sheet, and insert a revision table.//----------------------------------------------------------------------------- // Preconditions: // 1. Verify that the specified model document and templates exist. // 2. Open an Immediate window. // // Postconditions: // 1. Creates a new sheet named Test with four zones. // 2. Inspect the graphics area. // 3. Press F5. // 4. Modifies Test to contain nine zones. // 5. Creates Revision Table1. // 6. Adds a revision row to the table. // 7. Inspect the FeatureManager design tree, the graphics area, and the // Immediate window. // // NOTE: Because the model is used elsewhere, do not save changes to it. //--------------------------------------------------------------------------- using Microsoft.VisualBasic; using System; using System.Collections; using System.Collections.Generic; using System.Data; using System.Diagnostics; using SolidWorks.Interop.sldworks; using SolidWorks.Interop.swconst; using System.Runtime.InteropServices; namespace InsertRevisionTable_CSharp.csproj {partial class SolidWorksMacro{DrawingDoc swDraw;Sheet currentsheet;ModelDoc2 swModel;RevisionTableAnnotation revTableAnno;bool boolstatus;int longstatus;int longwarnings;public void Main(){swModel = swApp.OpenDoc6("C:\\Users\\Public\\Documents\\SOLIDWORKS\\SOLIDWORKS 2018\\samples\\tutorial\\api\\assem20.slddrw", 3, 0, "", ref longstatus, ref longwarnings);swApp.ActivateDoc2("assem20 - Sheet1", false, ref longstatus);swModel = (ModelDoc2)swApp.ActiveDoc;swDraw = (DrawingDoc)swModel;boolstatus = swModel.Extension.SetUserPreferenceToggle((int)swUserPreferenceToggle_e.swShowZoneLines, 0, true);boolstatus = swModel.Extension.SetUserPreferenceInteger((int)swUserPreferenceIntegerValue_e.swRevisionTableMultipleSheetStyle, 0, (int)swRevisionTableMultipleSheetStyle_e.swRevisionTable_Independent);if ((swDraw == null)){Debug.Print(" Please open a drawing document. ");}currentsheet = (Sheet)swDraw.GetCurrentSheet();swDraw.ActivateSheet(currentsheet.GetName());// Create sheet, Test, with 4 zonesboolstatus = swDraw.NewSheet4("Test", (int)swDwgPaperSizes_e.swDwgPaperAsize, (int)swDwgTemplates_e.swDwgTemplateAsize, 1, 1, true, "", 0, 0, "",0.5, 0.5, 0.5, 0.5, 2, 2);System.Diagnostics.Debugger.Break();boolstatus = swModel.Extension.SelectByID2("Sheet Format2", "SHEET", 0, 0, 0, false, 0, null, 0);swDraw.EditTemplate();swModel.EditSketch();swModel.ClearSelection2(true);boolstatus = swModel.Extension.SelectByID2("Sheet Format2", "SHEET", 0.0812585524728589, 0.139959974668275, 0, false, 0, null, 0);// Modify Test to have 9 zonesboolstatus = swDraw.SetupSheet6("Test", (int)swDwgPaperSizes_e.swDwgPapersUserDefined, (int)swDwgTemplates_e.swDwgTemplateCustom, 1, 1, true, "C:\\Program Files\\SOLIDWORKS Corp\\SOLIDWORKS\\lang\\english\\sheetformat\\a - landscape.slddrt", 0.2794, 0.2159, "Default",false, 0.5, 0.5, 0.5, 0.5, 3, 3);swDraw.EditSheet();swModel.EditSketch();swModel.ForceRebuild3(true);currentsheet = (Sheet)swDraw.GetCurrentSheet();swDraw.ActivateSheet(currentsheet.GetName());// Insert a revision table and add a revision rowrevTableAnno = currentsheet.InsertRevisionTable2(true, 0.0, 0.0, (int)swBOMConfigurationAnchorType_e.swBOMConfigurationAnchor_TopLeft, "C:\\Program Files\\SOLIDWORKS Corp\\SOLIDWORKS\\lang\\English\\standard revision block.sldrevtbt", (int)swRevisionTableSymbolShape_e.swRevisionTable_CircleSymbol, true);Debug.Print("Revision table annotation");Debug.Print(" New revision: " + revTableAnno.AddRevision("A"));Debug.Print(" Current revision: " + revTableAnno.CurrentRevision);RevisionTableFeature revTableFeat = default(RevisionTableFeature);revTableFeat = revTableAnno.RevisionTableFeature;Debug.Print("Revision table feature");Debug.Print(" Number of revision table annotations: " + revTableFeat.GetTableAnnotationCount());Feature feat = default(Feature);feat = (Feature)revTableFeat.GetFeature();Debug.Print("Feature: " + feat.Name);}/// <summary>/// The SldWorks swApp variable is pre-assigned for you./// </summary>public SldWorks swApp;} }

System.bool ReplaceViewModel(?
? ?System.string NewModelPathName,
? ?System.object Views,
? ?System.object Instances)

This example shows how to replace a model in drawing views.//--------------------------------------------------------------------------- // Preconditions: // 1. Open public_documents\samples\tutorial\api\assem20.slddrw. // 2. Verify that the specified replacement model exists. // // Postconditions: Replaces the specified component in Drawing View1 // with the specified model. // // NOTE: Because the model is used elsewhere, do not save changes // when closing it. //---------------------------------------------------------------------------using SolidWorks.Interop.sldworks; using SolidWorks.Interop.swconst; using System.Runtime.InteropServices; using System; namespace ReplaceViewModel_CSharp.csproj {partial class SolidWorksMacro{public void Main(){ModelDoc2 swModel;ModelDocExtension swModelDocExt;DrawingDoc swDrawingDoc;SelectionMgr swSelectionMgr;DrawingComponent swDrawingComponent;View swView;Component2 swComponent;object view;object instance;object[] views = new object[1];object[] instances = new object[1];DispatchWrapper[] viewsIn = new DispatchWrapper[1];DispatchWrapper[] instancesIn = new DispatchWrapper[1];bool status;swModel = (ModelDoc2)swApp.ActiveDoc;swDrawingDoc = (DrawingDoc)swModel;status = swDrawingDoc.ActivateView("Drawing View1");//Select the view in which to replace the modelswModelDocExt = (ModelDocExtension)swModel.Extension;status = swModelDocExt.SelectByID2("Drawing View1", "DRAWINGVIEW", 0, 0, 0, false, 0, null, 0);swSelectionMgr = (SelectionMgr)swModel.SelectionManager;swView = (View)swSelectionMgr.GetSelectedObject6(1, -1);view = (object)swView;views[0] = view;viewsIn[0] = new DispatchWrapper(views[0]);// Select the instance of the model to replacestatus = swModelDocExt.SelectByID2("Assem20-3@Drawing View1", "COMPONENT", 0, 0, 0, false, 0, null, 0);swDrawingComponent = (DrawingComponent)swSelectionMgr.GetSelectedObject6(1, -1);swComponent = (Component2)swDrawingComponent.Component;instance = (object)swComponent;instances[0] = instance;instancesIn[0] = new DispatchWrapper(instances[0]);status = swDrawingDoc.ReplaceViewModel("C:\\Users\\Public\\Documents\\SOLIDWORKS\\SOLIDWORKS 2018\\samples\\tutorial\\api\\bagel.sldprt", (viewsIn), (instancesIn));}public SldWorks swApp;} }

void SetSheetsSelected( System.object NewSheetList)

//This example shows how to modify the setups of multiple drawing sheets.//-------------------------------------------------------- // Preconditions: // 1. Verify that the drawing and sheet format files exist. // 2. Open the Immediate window. // // Postconditions: // 1. Opens the drawing. // 2. Sets Sheet1, Sheet2 and Sheet3 drawing sheet formats // to portrait. // 3. Rebuilds the drawing. // 4. Click each sheet tab, click Zoom to Fit, and examine // the sheet. // // NOTE: Because the drawing is used elsewhere, do not // save changes. //--------------------------------------------------------- using SolidWorks.Interop.sldworks; using SolidWorks.Interop.swconst; using System.Runtime.InteropServices; using System;namespace Macro1CSharp.csproj {public partial class SolidWorksMacro{public void Main(){ModelDoc2 swModel = default(ModelDoc2);ModelDocExtension swModelDocExt = default(ModelDocExtension);DrawingDoc swDrawing = default(DrawingDoc);string fileName = null;bool status = false;int errors = 0;int warnings = 0;object sheetNameArray = null;string[] sheetNames = new string[2];fileName = "C:\\Users\\Public\\Documents\\SOLIDWORKS\\SOLIDWORKS 2018\\samples\\tutorial\\advdrawings\\foodprocessor.slddrw";swModel = (ModelDoc2)swApp.OpenDoc6(fileName, (int)swDocumentTypes_e.swDocDRAWING, (int)swOpenDocOptions_e.swOpenDocOptions_Silent, "", ref errors, ref warnings);swModelDocExt = (ModelDocExtension)swModel.Extension;swDrawing = (DrawingDoc)swModel;sheetNames[0] = "Sheet2";sheetNames[1] = "Sheet3";sheetNameArray = sheetNames;swDrawing.SetSheetsSelected(sheetNameArray);status = swDrawing.SetupSheet6("Sheet3", (int)swDwgPaperSizes_e.swDwgPapersUserDefined, (int)swDwgTemplates_e.swDwgTemplateCustom, 1, 1, true, "C:\\ProgramData\\SOLIDWORKS\\SOLIDWORKS 2017\\lang\\english\\sheetformat\\a4 - portrait.slddrt", 0.2794, 0.2159, "Default",true, 0, 0, 0, 0, 0, 0);swModel.ForceRebuild3(true);swModel.ViewZoomtofit2();}/// <summary>/// The SldWorks swApp variable is pre-assigned for you./// </summary>public SldWorks swApp;} }

void SuppressView()

//This example shows how to automatically insert center marks in multiple drawing views.//---------------------------------------------------------------------------- // Preconditions: Open public_documents\samples\tutorial\advdrawings\foodprocessor.slddrw. // // Postconditions: // 1. Clears the Tools > Options > Document Properties > Centerlines/Center Marks > // Scale by view scale check box. // 2. Activates Sheet3. // 3. Suppresses Drawing View9. // 4. Inserts center marks in Drawing View9 and Drawing View11. // 5. Unsuppresses Drawing View9. // 6. Examine the drawing. // // NOTE: Because the drawing is used elsewhere, do not save changes. // --------------------------------------------------------------------------- using System; using SolidWorks.Interop.sldworks; using SolidWorks.Interop.swconst;namespace AutoInsertCenterMarks_CSharp.csproj {partial class SolidWorksMacro{ModelDoc2 Part;DrawingDoc Draw;ModelDocExtension ModelDocExt;View swActiveView;bool boolstatus;public void Main(){Part = (ModelDoc2)swApp.ActiveDoc;Draw = (DrawingDoc)Part;ModelDocExt = (ModelDocExtension)Part.Extension;// Clear the Scale by view scale check box to set gapModelDocExt.SetUserPreferenceToggle((int)swUserPreferenceToggle_e.swDetailingCenterMarkScaleByViewScale, (int)swUserPreferenceOption_e.swDetailingNoOptionSpecified, false);Draw.ActivateSheet("Sheet3");// Suppress Drawing View9 boolstatus = ModelDocExt.SelectByID2("Drawing View9", "DRAWINGVIEW", 0, 0, 0, false, 0, null, 0);Draw.SuppressView();// Insert center marks for all holes, fillets, and slots in the specified viewboolstatus = Draw.ActivateView("Drawing View9");swActiveView = (View)Draw.ActiveDrawingView;boolstatus = swActiveView.AutoInsertCenterMarks2(7, 11, true, true, true, 0.0025, 0.0025, true, true, 0);boolstatus = Draw.ActivateView("Drawing View11");swActiveView = (View)Draw.ActiveDrawingView;boolstatus = swActiveView.AutoInsertCenterMarks2(7, 11, true, true, false, 0.005, 0.005, true, false, 0);Part.ClearSelection2(true);// Unsuppress Drawing View9boolstatus = ModelDocExt.SelectByID2("Drawing View9", "DRAWINGVIEW", 0, 0, 0, false, 0, null, 0);Draw.UnsuppressView();}public SldWorks swApp;}}


?

總結(jié)

以上是生活随笔為你收集整理的IDrawingDoc Interface 学习笔记的全部內(nèi)容,希望文章能夠幫你解決所遇到的問題。

如果覺得生活随笔網(wǎng)站內(nèi)容還不錯,歡迎將生活随笔推薦給好友。

亚洲在线不卡 | 中文字幕丝袜一区二区 | 欧美一区二区在线看 | 五月婷香蕉久色在线看 | 国产精品久久艹 | 久久久久久久久久网站 | 蜜臀av夜夜澡人人爽人人桃色 | 免费久草视频 | 天天爽天天做 | 狠狠色婷婷丁香六月 | 亚洲视屏| 午夜视频导航 | 欧美午夜性生活 | 久久在线观看 | 91桃色在线播放 | 在线免费观看黄色 | 久草在线播放视频 | 久久久久这里只有精品 | 亚洲精品成人免费 | 久久综合桃花 | 日韩欧美一区二区不卡 | 成年人在线免费看视频 | 成 人 黄 色 视频 免费观看 | 久久成人毛片 | 搡bbbb搡bbb视频 | 中文字幕在线播放第一页 | 日韩试看| 午夜精品电影一区二区在线 | 最新三级在线 | 久久久久久久久网站 | 天天综合成人网 | 亚洲在线网址 | 日韩免费电影在线观看 | 五月天久久狠狠 | 91九色视频国产 | 91视频观看免费 | 日韩极品在线 | 成年人在线免费看视频 | 久久午夜免费视频 | 久久免费99精品久久久久久 | 中文字幕五区 | 久久经典国产视频 | 久久人91精品久久久久久不卡 | 国产精品国内免费一区二区三区 | 在线观看91精品视频 | 黄色大片日本免费大片 | 中日韩在线视频 | 2019av在线视频 | 在线看一级片 | 中文字幕av在线免费 | 久久一视频 | 亚洲精品字幕在线 | 久久久 精品 | 能在线看的av | 中文字幕色在线 | 久久久久久久久久久久av | 色婷婷色 | 欧美极品久久 | 国产精品区一区 | 欧美日韩精品在线观看视频 | 国产日产欧美在线观看 | 久久久这里有精品 | 91在线你懂的| 五月天开心 | 四虎在线永久免费观看 | 国产精品涩涩屋www在线观看 | 久久不见久久见免费影院 | 在线观看国产亚洲 | 久久成人毛片 | 在线观看日韩专区 | 中文字幕在线观看日本 | 亚洲精品欧美精品 | 国产二区电影 | 国产在线97 | 欧美激情视频一二区 | 999国内精品永久免费视频 | 久久精品国产免费看久久精品 | 在线观看国产日韩欧美 | 国产字幕在线观看 | 国产精品v欧美精品 | 久久人视频| 伊人中文网 | 又污又黄网站 | 亚洲国产高清在线观看视频 | 久久人91精品久久久久久不卡 | 亚洲精品视频偷拍 | 中文字幕你懂的 | 欧美日韩国产伦理 | 国产一级片免费视频 | 欧美一区二区在线刺激视频 | 国产一区免费在线观看 | 天天爽网站 | 欧美一级黄色片 | 婷婷丁香狠狠爱 | 精品不卡av | 欧美日韩三级 | 亚洲人av免费网站 | 亚洲一级理论片 | 播五月婷婷| 热久久影视| a视频免费看 | 久久99国产精品久久99 | 亚洲h在线播放在线观看h | 四虎影视成人 | 天天综合91 | 蜜臀aⅴ精品一区二区三区 久久视屏网 | 中文字幕第一 | 中文字幕a∨在线乱码免费看 | 亚洲精品久久久久久中文传媒 | 西西www4444大胆在线 | 97av在线| 日韩在线免费观看视频 | 日日碰狠狠添天天爽超碰97久久 | 中文av字幕在线观看 | 00av视频 | 亚洲视频2 | 亚洲欧美日韩中文在线 | 久久综合九色99 | 91原创在线观看 | 91在线精品一区二区 | 亚洲国产成人精品电影在线观看 | 国产成人精品三级 | 欧美视频99 | 在线国产日韩 | 国产精品一区二区吃奶在线观看 | 久久精品欧美日韩精品 | 欧美午夜精品久久久久久孕妇 | 二区中文字幕 | 天天操天天摸天天射 | 天海冀一区二区三区 | 色婷婷成人 | 中文字幕日韩一区二区三区不卡 | 国产精品久久久久av免费 | 国产小视频国产精品 | 亚洲欧美综合精品久久成人 | 一级免费看视频 | 人人爽久久涩噜噜噜网站 | 超级av在线| 久久精品爱爱视频 | 亚洲日本国产精品 | 国产综合香蕉五月婷在线 | 国产精品观看 | www.亚洲视频 | 久久精品9 | 国产一级片免费视频 | 成人免费看黄 | 国产精品久久一 | 国产成人av电影在线 | 99免费在线视频观看 | 2019中文在线观看 | 偷拍区另类综合在线 | 91人人网 | 欧美精品久久久久久 | 成人国产精品一区 | 国产精品久久久久久久久久白浆 | 精品色综合| 免费日韩一区二区三区 | 亚洲成色777777在线观看影院 | 日韩av手机在线观看 | 国产亚洲精品久久久久久电影 | 国产黄在线播放 | 色狠狠久久av五月综合 | 久久伊人精品一区二区三区 | 一区二区 久久 | 日韩精品免费一线在线观看 | 麻豆影视网| 国产精品久久久久久欧美 | 国产美腿白丝袜足在线av | 国产成人在线看 | 久久婷婷色 | 在线天堂中文在线资源网 | 亚洲欧美偷拍另类 | 久久伊人综合 | 日本aaa在线观看 | 免费看的黄色小视频 | 欧美日韩一级久久久久久免费看 | 免费看污在线观看 | 免费视频色 | 综合色伊人 | 国产黄色免费观看 | 超碰在97| 日韩色在线 | 色瓜| 国产欧美精品一区aⅴ影院 99视频国产精品免费观看 | 亚洲天天综合 | 成人在线免费视频观看 | 精品在线一区二区 | 在线观看www视频 | 国产 一区二区三区 在线 | 青草视频在线看 | 久久国产手机看片 | 97精品国自产拍在线观看 | 不卡的av电影在线观看 | 伊人婷婷综合 | 久久久久久麻豆 | 欧美aa级 | 久久一区二区免费视频 | av成人在线播放 | 97视频网站 | 91在线网址| 国产日韩一区在线 | 91精品国产麻豆国产自产影视 | 国产极品尤物在线 | 国产精品色婷婷 | 欧美va在线观看 | 亚洲精品免费在线视频 | 天天色天天 | 欧美精选一区二区三区 | 久久九九网站 | 69国产盗摄一区二区三区五区 | 国产成人av电影 | 国产黄色在线观看 | 午夜神马福利 | 亚洲精品玖玖玖av在线看 | 一级一片免费观看 | 亚洲精品视频久久 | 天堂v中文 | 午夜国产福利视频 | 正在播放日韩 | 国产一在线精品一区在线观看 | 色综合久久久久久久 | 日韩一级精品 | 91亚洲精品视频 | 久久久久久免费网 | 成人av视屏 | 国产精品av电影 | www.成人sex| 97免费在线视频 | 久久精品99久久久久久 | 91大神免费在线观看 | av在线播放快速免费阴 | 国产精品久久久久久久免费观看 | 在线观看91av| 国产成人精品一区二区三区福利 | 欧美在线观看视频一区二区 | 中文字幕丝袜美腿 | 久久久久久久久免费视频 | 日韩欧美国产成人 | 成人一级影视 | 91系列在线观看 | 东方av在线免费观看 | 91中文字幕视频 | 国产正在播放 | 亚洲资源在线观看 | 中文国产成人精品久久一 | 欧美在线久久 | av在线播放一区二区三区 | 亚洲精品视频二区 | 视频一区二区三区视频 | 久久天天躁狠狠躁夜夜不卡公司 | 亚洲资源网 | 毛片永久免费 | 日韩中文字幕免费视频 | 天天综合天天做 | 久久这里只有精品视频99 | 亚洲综合在线发布 | 久久99久久99精品免观看粉嫩 | 中文字幕91在线 | 成人av电影免费在线播放 | 五月天亚洲综合小说网 | 久久久激情网 | 狠狠狠色狠狠色综合 | 91人人爽久久涩噜噜噜 | 又黄又刺激的网站 | 开心激情五月婷婷 | 国产一区二区三区在线 | 亚洲一区日韩在线 | av一级二级 | 欧美日韩国产xxx | 婷婷丁香激情五月 | 久久尤物电影视频在线观看 | 久久久久久久久久久精 | 国产成人久久 | 欧美日韩裸体免费视频 | 91麻豆精品国产91久久久使用方法 | 二区三区在线观看 | 国产成人精品999在线观看 | 国产aaa大片 | 成人羞羞视频在线观看免费 | 黄色三级免费网址 | 国产午夜精品在线 | 在线看小早川怜子av | 婷婷色中文字幕 | 久久艹艹| 97色综合 | 国产麻豆精品一区二区 | 国产涩涩在线观看 | 在线观看一区 | 夜夜夜 | 亚洲精品美女久久久久 | 国产欧美综合视频 | 国产日韩视频在线播放 | 亚洲精品视频在线播放 | 国产日韩精品在线观看 | 青春草免费在线视频 | 日韩高清毛片 | 在线观看国产www | 91视频这里只有精品 | 亚洲久草网| 婷婷精品国产欧美精品亚洲人人爽 | 成人免费在线视频 | 国产二区电影 | 欧美日韩一区二区免费在线观看 | 国产精品99久久久精品免费观看 | 一本一道波多野毛片中文在线 | 日韩区欧美久久久无人区 | 久久综合五月婷婷 | 国产精品毛片一区视频播不卡 | 日韩二区三区 | 日韩二区在线播放 | 色婷婷综合久久久久中文字幕1 | 在线电影中文字幕 | 亚洲天堂首页 | 麻豆精品视频 | 色吊丝在线永久观看最新版本 | 国产成人精品午夜在线播放 | av不卡中文字幕 | 亚洲一区二区三区毛片 | 欧美极品xxxxx | 五月婷婷六月综合 | 成人精品一区二区三区电影免费 | 99精品视频在线观看 | 黄色av三级在线 | 免费高清在线视频一区· | 激情久久久久久久久久久久久久久久 | 国产精品午夜av | 天堂av色婷婷一区二区三区 | 天天看天天干 | 又湿又紧又大又爽a视频国产 | 视频二区在线 | 91精品入口 | 香蕉91视频 | 在线黄色国产电影 | 91禁在线观看 | 精品毛片在线 | 日韩精品中文字幕一区二区 | 欧美a级一区二区 | 久久精品99国产国产 | 黄色一级在线免费观看 | 精品女同一区二区三区在线观看 | 国产精品成人免费精品自在线观看 | 国产视频69 | 在线观看mv的中文字幕网站 | 国产午夜精品av一区二区 | 2019精品手机国产品在线 | 丁香六月婷婷激情 | 久久综合婷婷国产二区高清 | 日韩 在线观看 | 黄色影院在线免费观看 | 天天操天天操天天操天天操天天操天天操 | 色播五月激情综合网 | 亚洲午夜电影网 | 激情久久婷婷 | 国产一级二级av | 97色免费视频| 日韩精品一区二区三区免费观看 | 免费网站观看www在线观看 | 久久视频国产精品免费视频在线 | 97香蕉视频| 国产123av| 99精品热视频只有精品10 | 韩日三级av | 日日爱av | 久久免费精品国产 | 超碰在线中文字幕 | 精品成人免费 | 久久精品国产成人精品 | 福利一区二区在线 | 超碰免费成人 | 亚洲精品理论 | 国产精品久久久久久久久久久免费看 | 日韩高清三区 | 久久久久久久久综合 | 99精品乱码国产在线观看 | 中文区中文字幕免费看 | 日韩欧美一区二区三区在线观看 | 狂野欧美激情性xxxx | 欧美aa一级片 | 中文字幕在线免费看线人 | 国产高清福利在线 | 国产视频资源 | www.伊人色.com | 中文字幕欧美日韩va免费视频 | 久久视频在线视频 | 免费99| 婷婷色在线观看 | 久久人人看 | 亚洲综合精品在线 | 玖玖在线视频观看 | 中文字幕一区二区三区在线播放 | 国产在线精品国自产拍影院 | 激情综合亚洲 | 天天干天天想 | 18国产精品白浆在线观看免费 | 国产色爽| 在线观看成人小视频 | 中国一级片免费看 | 天天干天天操人体 | 亚洲精品在线电影 | 亚洲天天看 | 国产在线播放一区二区 | 日韩在线观看第一页 | 久久久综合精品 | 婷婷在线五月 | 在线 影视 一区 | 精品毛片在线 | 国产91精品看黄网站在线观看动漫 | 粉嫩av一区二区三区免费 | 日韩精品国产一区 | 超碰97在线资源 | 黄色特级毛片 | 91在线视频 | 免费男女羞羞的视频网站中文字幕 | 国产91探花 | 成年人av在线播放 | 亚洲精品在线观看的 | 久草在线免 | 成人在线视频观看 | 最新av在线免费观看 | 在线视频免费观看 | 999精品视频 | 激情亚洲综合在线 | 亚洲免费av在线 | 91精品久久久久久久久久入口 | 日日夜夜骑 | 国产女人18毛片水真多18精品 | 日韩精品一区二区三区高清免费 | 日韩精品短视频 | 国产精品免费久久久久 | 九九热免费视频在线观看 | 日韩精品电影在线播放 | 精品一区二区精品 | 国产黑丝一区二区 | 日韩视频中文 | 国产午夜亚洲精品 | 精品在线观看一区二区三区 | 中文字幕一区二区三区在线视频 | 99视频精品免费视频 | 九九久久成人 | av在线播放快速免费阴 | 国产最顶级的黄色片在线免费观看 | 毛片基地黄久久久久久天堂 | 久久久久精 | 成人a级黄色片 | 最新真实国产在线视频 | 久久人人爽人人片 | 九九精品视频在线看 | 天天看天天干 | 国内成人综合 | 在线中文字幕一区二区 | 久久视频免费观看 | 久黄色 | 在线观看亚洲视频 | 五月婷久 | 国产不卡精品视频 | 久久久久成人精品免费播放动漫 | 99热在线观看免费 | 天天操天天爽天天干 | 国语精品久久 | 黄色小视频在线观看免费 | www.久久久精品 | 午夜国产一区二区 | 国产一区在线免费观看 | 免费在线观看a v | 久久综合九色综合网站 | 午夜精品一区二区三区免费 | 亚洲国产99 | 免费男女羞羞的视频网站中文字幕 | 国产日韩在线一区 | 中文字幕一区二区在线播放 | 国内视频一区二区 | 在线观看av片 | 日韩天堂网 | 精品久久久免费视频 | 国产精品国产亚洲精品看不卡 | 国产亚洲精品精品精品 | 精品在线看 | 日韩在线高清免费视频 | 天堂在线视频中文网 | 亚洲女同ⅹxx女同tv | 精品国产一区二区三区男人吃奶 | 国产又粗又硬又爽的视频 | 97精品国产97久久久久久久久久久久 | 国产精品福利在线播放 | 亚洲精品小视频 | 国产精品第二十页 | 99久久精品国产网站 | 一二三久久久 | 国产香蕉久久精品综合网 | 人人揉人人揉人人揉人人揉97 | 麻豆免费看片 | 最近字幕在线观看第一季 | 操操日 | 在线电影91| 91看片网址 | 欧洲精品视频一区 | 国产在线精品一区二区三区 | av网站地址 | 成人羞羞免费 | 91色蜜桃 | 久久免费公开视频 | 五月亚洲| 日本3级在线观看 | av成人在线看 | 91免费国产在线观看 | 久久96国产精品久久99漫画 | 黄色高清视频在线观看 | 日本中文在线观看 | 亚洲午夜精品一区 | 国产一区在线视频观看 | 人人狠狠综合久久亚洲婷 | 99久久精品国产一区 | 亚洲精品影院在线观看 | 精品国产亚洲一区二区麻豆 | 超碰av在线 | 999成人网| 国产日韩精品一区二区 | 国产亚洲精品成人av久久ww | 久久综合色影院 | 国产亚洲成av人片在线观看桃 | 精品人妖videos欧美人妖 | 亚洲免费成人av电影 | 久久精品99久久久久久 | 国产精品入口麻豆 | 福利视频一区二区 | 国产在线观看国语版免费 | av综合在线观看 | 久久av免费 | 亚洲狠狠操 | 久草在线视频中文 | 玖玖综合网 | 亚洲精品网站 | 二区三区毛片 | 456成人精品影院 | 久久久久久久久久久网 | 久草在线免费播放 | 一区二区 不卡 | 天天爽夜夜爽人人爽一区二区 | 99在线播放 | 国产精品一区二区三区四区在线观看 | 精品产品国产在线不卡 | 久久免费观看少妇a级毛片 久久久久成人免费 | 日韩免费在线观看网站 | 亚洲一区精品二人人爽久久 | 久久字幕精品一区 | h网站免费在线观看 | 日韩av电影中文字幕 | 狠狠婷婷 | 亚洲精品中文在线资源 | 免费成人黄色av | 久久手机在线视频 | 九九一级片| 97人人艹 | 欧美一区二区三区特黄 | 99r在线播放| 久久久久久久久久久久亚洲 | 超碰97中文 | 精品99视频 | 欧美日韩中文国产一区发布 | 国内99视频 | 草樱av| 国产精品午夜在线 | 91成人短视频在线观看 | 国内精品国产三级国产aⅴ久 | 久久久电影 | 久久久国产精品亚洲一区 | 亚洲国产美女久久久久 | 狠狠操天天干 | 在线播放国产精品 | 亚洲成a人片在线观看网站口工 | 婷婷激情五月 | 二区三区在线视频 | 激情视频在线观看网址 | 91九色成人蝌蚪首页 | 91在线91 | 美女黄濒| 欧美性色综合网站 | 五月婷婷精品 | 99久e精品热线免费 99国产精品久久久久久久久久 | 国产区在线视频 | 国语精品免费视频 | 91高清不卡 | 激情影院在线 | 国产一级片免费观看 | 91精品国自产在线偷拍蜜桃 | 91在线免费视频观看 | 91av欧美| 婷婷六月天综合 | 天天天天天天天天操 | www.久久免费 | www.啪啪.com| 一区二区三区精品在线视频 | 国产美女精彩久久 | 不卡的av电影在线观看 | 久久久综合香蕉尹人综合网 | 成人av免费看 | 综合在线色 | 精品国产一区二区三区蜜臀 | 日韩av高潮 | 九九免费精品视频在线观看 | 最近中文字幕国语免费av | 欧美午夜精品久久久久久浪潮 | 99在线观看视频 | 狠狠色丁香婷婷综合最新地址 | 伊人干综合 | 黄色av免费在线 | 久精品视频在线 | 欧美日韩免费一区二区 | 91香蕉视频黄色 | 国产精品欧美一区二区 | 99re6热在线精品视频 | 麻豆你懂的 | 久久爱综合 | 精品美女久久 | 黄色一级在线视频 | 三级黄色大片在线观看 | 亚洲经典中文字幕 | 国产中文a| 日韩啪啪小视频 | 午夜精品一区二区三区在线播放 | www.五月婷婷| 黄色aa久久| 天天色欧美 | 国产视频在线一区二区 | 高清av在线 | 色婷婷午夜| 51精品国自产在线 | 日本女人b| 91麻豆精品国产91 | 免费下载高清毛片 | 韩日三级av | 成人综合日日夜夜 | 国产成人1区 | 91精品一区二区三区蜜臀 | 久久艹艹 | 天天鲁一鲁摸一摸爽一爽 | 成年人黄色免费网站 | 国产精品高潮呻吟久久av无 | 手机色在线 | 久久久久亚洲精品 | 天天操操操操操操 | zzijzzij亚洲日本少妇熟睡 | 欧美在线久久 | 国内精品久久久久影院男同志 | 国产亚洲小视频 | 国产69久久久 | 亚洲国产人午在线一二区 | 亚洲一区二区三区在线看 | 狠狠操狠狠 | 国产二区视频在线观看 | 日韩区欠美精品av视频 | 成人av手机在线 | www.天天干 | 国产精品久久二区 | 99人久久精品视频最新地址 | 九色视频网站 | 中文字幕乱码电影 | 精品国自产在线观看 | 免费福利小视频 | 精品视频国产一区 | 日韩免费在线视频观看 | 久久精品欧美一 | 成人午夜电影在线 | 99久久精品国 | 91超级碰碰| 日韩精品视频在线免费观看 | 97在线观看免费高清 | 九七视频在线观看 | 草久久影院 | 免费a级毛片在线看 | 亚洲黑丝少妇 | 欧美一级艳片视频免费观看 | www蜜桃视频 | 免费看的黄色小视频 | 美女黄久久 | 日韩不卡高清视频 | 干狠狠| 99精品视频免费观看视频 | 黄色影院在线免费观看 | 色噜噜在线观看 | 欧美成人h版 | 美女久久精品 | 久久久久 免费视频 | 在线观看黄色 | 国产免费久久精品 | 91精品国自产在线观看欧美 | 日韩免费视频 | 九九热在线免费观看 | 久久久私人影院 | 黄色一级网 | 欧美粗又大| 在线性视频日韩欧美 | 五月婷婷影院 | 超碰人人99 | 偷拍区另类综合在线 | 91成人亚洲| 国产精品久久久999 国产91九色视频 | 日韩欧美一级二级 | 久久黄色成人 | 中文字幕日韩免费视频 | 五月婷婷在线观看视频 | 亚洲少妇影院 | 亚洲国产精品va在线看黑人 | 久久亚洲国产精品 | 99精品热视频只有精品10 | 色婷婷狠狠五月综合天色拍 | 亚洲精品国偷拍自产在线观看蜜桃 | 狠狠狠狠狠狠天天爱 | 日韩精品视频在线观看免费 | 国产 字幕 制服 中文 在线 | 婷婷色 亚洲| 日韩免费电影一区二区三区 | 国产在线观看地址 | 中文字幕免费观看视频 | 嫩草伊人久久精品少妇av | 黄色小说视频网站 | 中文字幕在线播放视频 | 国产美女视频免费 | 在线观看岛国片 | 国产午夜一区 | 国产裸体bbb视频 | 九九交易行官网 | 精品国产自 | 国产99久久久国产精品免费二区 | 色综合久久网 | 一二三精品视频 | 国产特级毛片aaaaaa毛片 | 久久久国产一区二区三区四区小说 | 成人免费在线观看电影 | 日本99精品| 草久在线 | 99精品视频免费看 | 日日躁夜夜躁xxxxaaaa | 在线播放国产一区二区三区 | 天无日天天操天天干 | 99国产精品一区二区 | 亚洲精品久久久久中文字幕m男 | 国产精品一区二区三区视频免费 | 国产精品久久久久久久久蜜臀 | 美女免费网视频 | 国产精品丝袜久久久久久久不卡 | 久久精品成人热国产成 | 国产精品视频地址 | 国产精品久久久久久久电影 | 欧美超碰在线 | 国产美女精品视频 | 亚洲乱码一区 | 亚洲久草在线 | 三级视频片 | www色com| 欧美孕交vivoestv另类 | 伊人精品影院 | 亚洲精品欧美视频 | 伊人天堂久久 | 中文字幕乱偷在线 | 久久夜视频 | 精品一区二区在线播放 | 久久精品成人欧美大片古装 | 色多视频在线观看 | 欧美在线free | 97干com | 啪啪免费视频网站 | 亚洲乱码一区 | 欧美日韩国产综合网 | 91在线观看欧美日韩 | 操操操天天操 | 久久久久国 | 久久精品久久久久电影 | 色婷婷综合在线 | 国产色视频123区 | 97av影院| 久久久久久久99 | 日日夜夜天天操 | 96精品高清视频在线观看软件特色 | 精品1区2区3区 | 992tv在线观看 | 91精品成人久久 | 中文字幕日韩有码 | 97人人爽人人 | 日韩一区二区三区高清在线观看 | 中文字幕在线看视频国产 | 亚洲男男gaygayxxxgv | 国产日韩中文字幕 | 久章操 | 精品美女久久久久久免费 | 黄色免费看片网站 | 欧美国产91| 天天综合网天天综合色 | 免费日韩电影 | 国产一区二区高清视频 | 亚洲综合网站在线观看 | 亚洲精品欧美视频 | 中文字幕影片免费在线观看 | 国产成人精品国内自产拍免费看 | 色综合天天射 | 操少妇视频 | 亚洲成年人av | 亚洲一级理论片 | 福利在线看片 | 精品国产伦一区二区三区观看说明 | 亚洲 综合 激情 | 天天天干天天射天天天操 | 久久精品电影 | 免费视频三区 | 天天干.com | 日韩视频免费 | av网站大全免费 | 日韩成人免费观看 | 国产精品激情在线观看 | 中文字幕一区二区三 | 亚洲一区二区三区精品在线观看 | 日韩一二三 | 在线观看免费91 | 亚洲精选99| 免费国产亚洲视频 | 亚洲视频免费在线 | 国产又粗又猛又黄又爽 | 欧美极品少妇xxxxⅹ欧美极品少妇xxxx亚洲精品 | 九九日韩| 九九免费在线视频 | 久久久国产精品网站 | 一区二区三区在线免费播放 | 在线亚洲日本 | 91刺激视频 | 在线观看黄色大片 | 手机av电影在线观看 | 久久激情视频 久久 | 17婷婷久久www| 激情视频91 | 97在线观看免费 | 色欲综合视频天天天 | 九九热久久免费视频 | 黄色三级视频片 | 久久99久久99精品中文字幕 | 中文字幕精品在线 | 国产精品毛片一区二区在线 | 久久久免费观看视频 | 99久久这里只有精品 | 天天操天天操天天操天天操天天操天天操 | 国产色影院| 成人毛片一区 | 久草久热 | 999久久久久久久久久久 | 日本精品一 | 久久久福利视频 | 成人免费视频a | 在线观看网站你懂的 | 亚洲激精日韩激精欧美精品 | 国产日产高清dvd碟片 | 99精品在线观看视频 | 在线综合 亚洲 欧美在线视频 | 中文在线字幕免费观看 | 黄色一级大片免费看 | 日韩精品一区二区电影 | 日本黄色免费电影网站 | a级片网站 | av电影中文字幕在线观看 | 欧美一区二区视频97 | 91免费在线视频 | 色婷婷六月天 | 国产字幕在线播放 | 久久久久久毛片精品免费不卡 | 色视频网站在线观看一=区 a视频免费在线观看 | 韩国av永久免费 | 中文字幕中文字幕在线中文字幕三区 | 久久综合色综合88 | 一区免费在线 | 国产麻豆精品久久 | 欧美一级淫片videoshd | 日韩女同一区二区三区在线观看 | 国产婷婷视频在线 | www.在线观看视频 | 久久免费视频精品 | 国产精品 视频 | 国产欧美中文字幕 | 韩国av不卡 | 色爱区综合激月婷婷 | 免费看黄在线观看 | 国产亚洲资源 | 中文字幕一区二区三区在线观看 | 色噜噜在线观看 | 欧美视频国产视频 | 国产精品第 | 久久国产精品一区二区三区四区 | 欧美成人在线网站 | 成人性生交大片免费观看网站 | 天天透天天插 | 亚洲成人第一区 | 91看片看淫黄大片 | 国产最新在线 | 天天操天天干天天爽 | www.色爱 | 人人爽人人爱 | 成人免费观看网站 | 免费看三级黄色片 | 久久国产精品视频免费看 | 欧美一级免费黄色片 | 国产三级国产精品国产专区50 | 中文字幕区 | 9在线观看免费高清完整版在线观看明 | 日韩av视屏在线观看 | a在线一区| 午夜久久久久久久久久久 | 91精品免费视频 | 亚洲国产精品久久久久 | 日韩高清dvd| 亚洲精品午夜一区人人爽 | 中文av在线播放 | 久久夜色精品国产欧美一区麻豆 | 色综合www | 97电影在线看视频 | 亚洲欧美在线观看视频 | 国产在线播放一区二区 | 日韩在线高清免费视频 | 成人影片免费 | 欧美精品一区二区免费 | 婷婷在线资源 | 狠狠干成人综合网 | 亚洲激情在线播放 | 日韩欧美一区二区在线 | 东方av在 | 日韩动态视频 | 久久精品国产亚洲精品 | 成人网444ppp | av在线免费不卡 | 在线看中文字幕 | 日韩a欧美 | 欧美日韩综合在线 | 久视频在线 | 日韩 精品 一区 国产 麻豆 | 亚洲成人av在线播放 | 成人观看 | 六月丁香色婷婷 | 麻豆成人网 | 91看片淫黄大片一级在线观看 | 极品嫩模被强到高潮呻吟91 | 五月天激情开心 | 在线观看aa | 国产精品久久久久久久久久久久午 | av片一区二区 | av手机版| 国产精品综合在线观看 | av官网在线 | 久久久久久美女 | 日韩欧美黄色网址 | 国产精品乱码高清在线看 | 婷婷网址 | 日韩高清无线码2023 | 久久情网 | 美女久久久久 | 最近中文字幕国语免费高清6 | 91资源在线视频 | 国产中文欧美日韩在线 | 色五月色开心色婷婷色丁香 | 久草在线视频免赞 | 日韩毛片精品 | 97**国产露脸精品国产 | 久久99精品久久久久久 | 国产精品久久久久久久久久久免费看 | 国产视频不卡一区 | 国产亚洲精品美女久久 | 亚洲精品乱码久久久久久9色 | 男女全黄一级一级高潮免费看 | 久久视频一区二区 | av在线等 | 欧美日韩精品在线 | 久久综合婷婷 | 亚洲区另类春色综合小说 | 日韩激情网 | 丁香婷婷网 | 亚洲高清精品在线 | 亚洲精品小视频 | 国产91在线免费视频 | 久久这里有 | 国产色婷婷在线 | 国产在线小视频 | 99精品视频在线免费观看 | 色在线免费 | 99精品国产一区二区 | 精品视频专区 | 欧美性久久久 | 日韩 精品 一区 国产 麻豆 | 中文字幕在线视频一区二区三区 | 操久久网 | 欧美少妇影院 | 久久久久日本精品一区二区三区 | 久久久久国产精品视频 | 亚洲精品国产自产拍在线观看 | 丁香五月缴情综合网 | 婷婷网站天天婷婷网站 | 奇米网网址 | 亚洲乱亚洲乱亚洲 | 99精彩视频| 中文字幕一区2区3区 | 国产免费观看av | 精品一区 精品二区 | 亚洲深夜影院 | 久久久久久久久久亚洲精品 |