Site Tools


Differences

This shows you the differences between two versions of the page.

Link to this comparison view

developer:scriptsamples:copytoexcel [2015/09/14]
127.0.0.1 external edit
developer:scriptsamples:copytoexcel [2015/11/18] (current)
dale
Line 24: Line 24:
  
 <code vb> <code vb>
- Call Rhino.ClipboardText("​Hello from Rhino!"​)+Call Rhino.ClipboardText("​Hello from Rhino!"​)
 </​code>​ </​code>​
  
Line 30: Line 30:
  
 <code vb> <code vb>
- Call Rhino.ClipboardText("​A"​ & vbTab & "​B"​ & vbTab & "​C"​ & vbTab & "​1"​ & vbTab & "​2"​ & vbTab & "​3"​)+Call Rhino.ClipboardText("​A"​ & vbTab & "​B"​ & vbTab & "​C"​ & vbTab & "​1"​ & vbTab & "​2"​ & vbTab & "​3"​)
 </​code>​ </​code>​
  
Line 36: Line 36:
  
 <code vb> <code vb>
-   Call Rhino.ClipboardText("​A"​ & vbLf & "​B"​ & vbLf & "​C"​ & vbLf & "​1"​ & vbLf & "​2"​ & vbLf & "​3"​)+Call Rhino.ClipboardText("​A"​ & vbLf & "​B"​ & vbLf & "​C"​ & vbLf & "​1"​ & vbLf & "​2"​ & vbLf & "​3"​)
 </​code> ​   </​code> ​  
  
Line 42: Line 42:
  
 <code vb> <code vb>
- Sub CopyClipCrvLength() +Sub CopyClipCrvLength() 
-   ​Dim curves, crv, length, str +  Dim curves, crv, length, str 
-   ​curves = Rhino.GetObjects("​Select curves to copy length",​ 4, True, True) +  curves = Rhino.GetObjects("​Select curves to copy length",​ 4, True, True) 
-   ​If IsArray(curves) Then +  If IsArray(curves) Then 
-     ​str = str & "​Id"​ & vbTab & "​Length"​ & vbLf +    str = str & "​Id"​ & vbTab & "​Length"​ & vbLf 
-     ​For Each crv In curves +    For Each crv In curves 
-       ​length = Rhino.CurveLength(crv) +      length = Rhino.CurveLength(crv) 
-       ​str = str & crv & vbTab & CStr(length) & vbLf +      str = str & crv & vbTab & CStr(length) & vbLf 
-     ​Next +    Next 
-     ​Call Rhino.ClipboardText(str) +    Call Rhino.ClipboardText(str) 
-   ​End If     +  End If     
- End Sub+End Sub
 </​code>​ </​code>​
  
developer/scriptsamples/copytoexcel.txt · Last modified: 2015/11/18 by dale