Continue to Site

Eng-Tips is the largest engineering community on the Internet

Intelligent Work Forums for Engineering Professionals

  • Congratulations KootK on being selected by the Eng-Tips community for having the most helpful posts in the forums last week. Way to Go!

export points into femap from excels via macro 3

Status
Not open for further replies.

rk_19

Structural
Aug 7, 2012
71
Replies continue below

Recommended for you

You have the “.Put” method graysd out. You’ll need that to actually create the nodes.

You may also want to include “.feViewRegenerate(0)” at the end to redraw the screen.

With those small changes your script created nodes for me.

Nodes_wxikjf.png
 
Hello Rcatania, thanks for the suggestion - it worked. i wish the coordinates to be exported as points, not as nodes. how do i achieve that ..thanks
 
You will need a point object instead of a node object. In your script from "Dim nd as node" down to "loop" should be changed to

Dim pt As Point
Set pt = App.fePoint
'
I = 5
Do While Cells(I, 2) <>""
rc = pt.Get(pt.ID)
pt.ID = Cells(I, 2)
pt.x = Cells(I, 3)
pt.y = Cells(I, 4)
pt.z = Cells(I, 5)
pt.defCSys = Cells(I, 6)

rc = pt.Put(pt.ID)
I = I + 1
Loop

The nd.OutCsys is no longer needed.
 
You need to change your code for Module2. Also, you need to dimension point a little differently. "Dim pt as femap.Point"

Points_Excel_h41g2s.png
 
or you can create a point on the node

another day in paradise, or is paradise one day closer ?
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor