Insert a power port.
	  	
	  
		
	    	
	    	 Syntax:  | 
	    	
	            | 
					DlxLayer.DrawPowerPort(insertionPoint, type, rotationAngle, 
				bLink)
				 | 
	   	    
	    	
	     
		   
		Parameters
      
		
		
			
				
					
						| Parameter | 
						Description | 
					
					
						| insertionPoint | 
						A DlxPoint object with the coordinates on the drawing where the port is placed. | 
					
					
						| type | 
						Type of port. Select from the following: 
						
						| DlxApp.POWERPORT_VCC |  
						| DlxApp.POWERPORT_VCCARROW |  
						| DlxApp.POWERPORT_VCCBAR |  
						| DlxApp.POWERPORT_VCCWAVE |  
						| DlxApp.POWERPORT_GND |  
						| DlxApp.POWERPORT_GNDSIGNAL |  
						| DlxApp.POWERPORT_GNDEARTH |  
						 
						 | 
					
					
						| rotationAngle  | 
						The angle, in degrees, of rotation of the port. | 
					
					
						| bLink | 
						Specify true if the port must connect to electrical objects or false to draw only the port. | 
					
				
			 
		 
		   
		Return Value
		The last newly created DlxPower object. Call the IsValid() method to determine if the 
		object was created correctly.
							
	Example
	
		
			
				|  
				 | 
				
                    
                         Copy code
				 | 
			
			
				
  var prj = DlxApp.GetJob().GetProject("Example Sch");
if (!prj.IsValid())
  prj = DlxApp.GetJob().NewProject("Example Sch");
var doc = prj.GetDocument("Examples Sch", DlxApp.DOCTYPE_SCHEMATIC);
if (!doc.IsValid())
{
  doc = prj.NewDocument("Examples Sch", DlxApp.DOCTYPE_SCHEMATIC);
  doc.SetPageFormat("A4", false);
}
if (doc.IsValid() && doc.Activate())
{
  var page = doc.GetActivePage();
  if (page.IsValid())
  {
    var layer = page.GetLayerFromType(DlxApp.LAYERTYPE_DRAWING);
    if (layer.IsValid())
    {
      layer.DrawPowerPort(new DlxPoint(90,100), DlxApp.POWERPORT_VCC, 0, true);
    }
  }
}
				 | 
			
		
	 
	    
		See also