*-----------------------------------------------------------------------
      subroutine nxdqsz(ncdfid,cdname,ndsize)

      include   '/usr/local/include/netcdf.inc'

      character cdname*(*)

      character cdtemp*(MAXNCNAM)


      ndimid=ncdid(ncdfid,cdname,ircode)
      if (ircode.ne.0) call msgdmp('e','nxdqsz','error in ncdid.')

      call ncdinq(ncdfid,ndimid,cdtemp,ndsize,ircode)
      if (ircode.ne.0) call msgdmp('e','nxdqsz','error in ncdinq.')

      end
