anchor.diff:  
   
         case(11)
  -      im=irm(ii)
  -      if(att_name=="scaleall") then
  -
  -      else if(att_name(1:1) == "a" .or. att_name(1:1) == "b") then
  -        if(LEN_TRIM(att_name) .eq. 5) then
  -           range = 3
  -          read(att_name(2:2), *) orderMult
  -        else if(LEN_TRIM(att_name) .eq. 6) then
  -          read(att_name(2:3), *) orderMult
  -          range = 4
  -        else
  -          goto 100
  +        im=irm(ii)
  +        if(att_name=="scaleall") then
  +          dynk_getvalue = scalemu(im) 
  +        else if(att_name(1:1) == "a" .or. att_name(1:1) == "b") then
  +          if(LEN_TRIM(att_name) .eq. 5) then
  +             range = 3
  +            call chr_cast(att_name(2:2), orderMult, iErr)
  +          else if(LEN_TRIM(att_name) .eq. 6) then
  +            call chr_cast(att_name(2:3), orderMult, iErr)
  +            range = 4
  +          else
  +            goto 100
  +          endif
  +          if(iErr) goto 100
  +          
  +          if(att_name(1:1) == "a" .and. att_name(range:range+3) == "rms") then
  +            dynk_getvalue = aka(im,orderMult)
  +          else if(att_name(1:1) == "b" .and. att_name(range:range+3) == "rms") then
  +            dynk_getvalue = bka(im,orderMult)  
  +          else if(att_name(1:1) == "a" .and. att_name(range:range+3) == "str") then
  +            dynk_getvalue = ak0(im,orderMult)  
  +          else if(att_name(1:1) == "b" .and. att_name(range:range+3) == "str") then
  +            dynk_getvalue = bk0(im,orderMult) 
  +          else
  +            goto 100 ! ERROR
  +          endif
           endif
  -      
  -        if(att_name(1:1) == "a" .and. att_name(range:range+3) == "rms") then
  -          dynk_getvalue = aka(im,orderMult)
  -        else if(att_name(1:1) == "b" .and. att_name(range:range+3) == "rms") then
  -          dynk_getvalue = bka(im,orderMult)  
  -        else if(att_name(1:1) == "a" .and. att_name(range:range+3) == "str") then
  -          dynk_getvalue = ak0(im,orderMult)  
  -        else if(att_name(1:1) == "b" .and. att_name(range:range+3) == "str") then
  -          dynk_getvalue = bk0(im,orderMult) 
  -        else
  -          goto 100 ! ERROR
  -        endif
  -      endif
  -
  -
   
         case(12) ! Cavities
           if(att_name == "voltage"  ) then ! MV
  
positive.code: 
    integer el_type, ii, orderMult, im, range
  
    logical ldoubleElement
    ldoubleElement = .false.  ! For sanity check
  
    if(dynk_debug) then
      write(lout,"(a)") "DYNK> DEBUG In getValue, element_name = '"//trim(element_name)//"'"//&
        ", att_name = '"//trim(att_name)//"'"
  
negative.code:   use mod_commont
    use mod_commonmn
    use mod_particles
  
    use elens
    use parbeam, only : beam_expflag
    implicit none
  