Stuck in programming



I made the following code:

Module module2

Sub main()


Dim objApp As SolidEdgeFramework.Application

Dim objDocuments As SolidEdgeFramework.Documents

Dim objDraft As SolidEdgeDraft.DraftDocument

Dim objSheet As SolidEdgeDraft.Sheet

Dim objBSpline As SolidEdgeFrameworkSupport.BSplineCurve2d


' Connect to a running instance of Solid Edge

objApp = Marshal.GetActiveObject("SolidEdge.Application")


' Get a reference to the documents collection

objDocuments = objApp.Documents


' Connect to a running instance of a Solid Edge Document

objDraft = Marshal.GetActiveObject("SolidEdge.draftdocument")


'getting the Active Sheet object

objSheet = objDraft.ActiveSheet


'Draw the curves

[u]objBSpline = objSheet.BsplineCurves2d. ( Getting stuck here...)


Catch ex As Exception



If Not (objBSpline Is Nothing) Then


objBSpline = Nothing

End If

If Not (objDocuments Is Nothing) Then


objDocuments = Nothing

End If

If Not (objApp Is Nothing) Then


objApp = Nothing

End If

End Try

End Sub

End Module


With this code i want to make curves on 2D draft file. I use coordinates from a excel file. My problem is, How do i get an connection to that excel file to let it read the xy collums i made (these are a lot of collums). I have used the Solid Edge programming guide to make the code i got now.

I'm not a programmer but like trying to figure this out but i'm stuck now.

Can someone helpme out here?

Btw, im using visual 2003.


Thank is advance.


Posted by: Andries
Post date: 11/7/2012 2:19:59 AM