integer res
character(len=CALCEPH_MAX_CONSTANTVALUE) version
TYPE(C_PTR) :: peph

peph = calceph_open("example1.dat"//C_NULL_CHAR)
if (C_ASSOCIATED(peph)) then
     res = calceph_getfileversion(peph, version)
     write (*,*) "The version of the file is ", version

    call calceph_close(peph)
 endif