//根据坐标计算2.5万图幅号的公式。
int M1, M2, M3, M4, J1;
double J2, W;
W = y; //纬度
J1 = (int)x; //经度度
J2 = x-J1;//经度秒
M1 = (int)(W*60/40);
M2 = J1-60;
M3 = (int)( (W*60/40-( (int)(W*60/40) ) ) *40/5);
M4 = (int)(J2*3600)/450;
char ss1[3],ss2[3],ss3[2],ss4[2];
_itoa(M1,ss1,10);
_itoa(M2,ss2,10);
_itoa(M3,ss3,10);
_itoa(M4,ss4,10);
CString M;
M = ss1;
M += ss2;
M += ss3;
M += ss4;
//根据坐标计算5千图幅号的公式。
xMin=M2*3600+M4*450+60*3600;
xMax=xMin+450;
yMin=M1*2400+M3*300;
yMax=yMin+300;
double xx,yy;
xx = x*3600-xMin;
yy = y*3600-yMin;
int mapcode_1 = 3 + int(xx/225) - 2*int(yy/150);
xx = xx - int(xx/225)*225;
yy = yy - int(yy/150)*150;
int mapcode_05 = 3 + int(xx/112.5) - 2*int(yy/75);
CString strTemp;
strTemp.Format("%s_%d_%d", M, mapcode_1, mapcode_05);