Consulting

Results 1 to 2 of 2

Thread: text file results in a drawing in autocad

  1. #1
    VBAX Regular
    Joined
    Apr 2005
    Posts
    14
    Location

    text file results in a drawing in autocad

    i have structured my text file (file.txt) according to ANSYS command file, now i want that when i put this file again in autocadd than it results in a drawing of the same structure frm which the text file is generated.

    i am posting myt text file also...
    /title , frame

    /PREP7

    !Enter the height and width of the frame:

    300, 400

    ! Define Keypoints

    K,1,x1, y1 ! keypoint, #, x, y
    K,2,x2, y2
    K,3,x3, y3
    K,4,x4, y4
    K,5,x5, y5
    K,6,x6, y6

    ! Define Lines Linking Keypoints

    L,1,2 ! L,keypoint1,keypoint2
    L,2,3
    L,3,4
    L,4,1
    L,4,6
    L,4,5
    L,3,5
    L,3,6

    ! element definition

    !

    ET,1,LINK1 ! element type #1; spring element
    R,1,3250 ! real constant #1; Xsect area: 3200 mm^2
    MP,EX,1,200e3 ! material property #1; Young's modulus: 200 GPa


    LESIZE,ALL, , ,1,1,1 ! specify divisions on unmeshed lines
    LMESH,all ! mesh all lines

    !
    FINISH ! finish pre-processor
    !
    /SOLU ! enter solution phase
    !
    ! apply some constraints

    DK,1,UX,0,,,UY,UZ ! define a DOF constraint at a keypoint
    DK,7,UY,0,,,UZ

    !
    ! apply loads
    !

    FK,1,FY,-280e3 ! define a force load to a keypoint
    FK,3,FY,-210e3
    FK,5,FY,-280e3
    FK,7,FY,-360e3

    !
    SOLVE ! solve the resulting system of equations

    FINISH ! finish solution

    /POST1

    PRRSOL,F ! List Reaction Forces
    PLDISP,2 ! Plot Deformed shape
    PLNSOL,U,SUM,0,1 ! Contour Plot of deflection

    ETABLE,SAXL,LS, 1 ! Axial Stress
    PRETAB,SAXL ! List Element Table
    PLETAB,SAXL,NOAV ! Plot Axial Stress
    to make more clear, i have generated my text file by using VBA programming in autocad, i know that to get drawing from this text file also need programming in VBA but i am not getting any idea how to do it.

    the problem, to export text file to ansys is solved so the problem remains is the above one.

    please help me out ..its really urgent, deadline is very near

    thanks

    nsdhakar

  2. #2
    VBAX Regular
    Joined
    Apr 2005
    Posts
    14
    Location
    as i posted text file in first post....i want to make the following part of the file more clear...

    ! Define Keypoints
    K,1,x1, y1 ! keypoint, #, x, y
    K,2,x2, y2
    K,3,x3, y3
    K,4,x4, y4
    K,5,x5, y5
    K,6,x6, y6
    in above part actually X1, Y1 have some values...so actually above part is like this in text file..except this everything is correct in file and written as i want to.


    ! Define Keypoints
    K, 1,4578.2531,7919.0487

    K, 2,11346.8678,11826.9102

    K, 3,11346.8678,3072.2707

    K, 4,4578.2531,3072.2707

    K, 5,11346.8678,7919.0487

    K, 6,4578.2531,11826.9102

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •