[netcdfgroup] Fortran netCDF create error

Dear Sir/Madam,

I am trying to read and write a netcdf file based on the read data. I am 
reading a 4-D and want to write a 3-D netcdf file.

I am successful at reading and performing computations on the read-in data but 
it cannot write the new netcdf file. I get the following error;
"""
I am writing a fortra NetCDF: Invalid dimension ID or name
STOP 2

"""
Kindly find attached a sample of my sample code.

Looking forward to hearing from you soon.

Sincerely,

Peter Nunekpeku.

Attachment: africa_writer.f90
Description: Binary data