! ANSYS $RCSfile: EDPL.MAC,v $
! Modified on $Date: 2010-11-14 13:40:31 -0500 (Sun, 14 Nov 2010) $ 
! Source ID = $Revision: 435640 $
!  -------------------------------------------------------------------------
!   This macro is designed to plot loads entered via the EDLOAD command.
!
!   Use this macro as follows:
!
!   edpl,arg1
!
!   where: arg1 - Defined load number determined using "EDLOAD,LIST"
!              
!  -------------------------------------------------------------------------



/nopr
_lc=arg1

_j=0
*if,_lc,eq,0,then

/gopr  
*msg,error
Invalid input. The load number is zero.    &
The EDPL command is ignored.
/nopr
_j=1

*endif


*del,_TIME
*del,_VALUE

!*get,_def,edll,_lc,defi
!*if,_def,gt,0.0d0,THEN


   _num=0
   *get,_num,edll,_lc,number
   *dim,_TIME,table,_num
   *dim,_VALUE,table,_num

*if,_num,eq,0,then

_j=1

*endif


*get,_scale,edll,_lc,scale
*if,_scale,eq,0.0,then
  _scale=1.0
*endif

*if,_j,eq,0,then

   *do,_i,1,_num,1
  
     *get,_TIME(_i),edll,_lc,val,_i
     *get,_k,edll,_lc,val,_i+_num
     _VALUE(_i)=_scale*_k

   *enddo  

   *vplot,_TIME(1),_VALUE(1)


*endif
   

/gopr
