{"id":613,"date":"2009-09-05T20:15:00","date_gmt":"2009-09-05T12:15:00","guid":{"rendered":""},"modified":"2013-11-17T16:08:48","modified_gmt":"2013-11-17T08:08:48","slug":"geocalc-2-0","status":"publish","type":"post","link":"https:\/\/kyle.ai\/blog\/613.html","title":{"rendered":"GeoCalc 2.0"},"content":{"rendered":"<p>\u4eca\u5929\u521a\u4ece\u82b1\u5c71\u56de\u6765\u3002\u82b1\u679c\u5c71\u5b9e\u4e60\u5171\u82b1\u4e24\u5929\uff0c\u7b2c\u4e00\u5929\u4ece\u65e9\u4e0a8\uff1a30\u51fa\u53d1\uff0c\u4e0b\u53484\u70b9\u56de\u6821\uff0c\u7b2c\u4e8c\u5929\u65e9\u4e0a7\uff1a00\u51fa\u53d1\uff0c\u4e0b\u53483\u70b9\u56de\u6821\uff0c\u603b\u7b97\u662f\u641e\u5b8c\u4e86\u3002\u6211\u7684\u624b\u4e25\u91cd\u6652\u4f24\uff0c\u597d\u75db\uff0c\u6628\u665a\u90a3\u4e48\u665a\u4e86\u8fd8\u8dd1\u51fa\u53bb\u4e70\u4e86\u836f\uff0c\u5e0c\u671b\u4e0d\u8981\u8131\u76ae\uff01<\/p>\n<div>\n<p>\u524d\u5929\u62ff\u5230\u5168\u7ad9\u4eea\u5c31\u5199\u4e86\u6700\u540e\u4e00\u4e2a\u529f\u80fd\uff0c\u4f46\u662f\u7531\u4e8e\u65f6\u95f4\u592a\u4ed3\u4fc3\uff0c\u529f\u80fd\u4e0a\u6709\u70b9\u95ee\u9898\uff0c\u6628\u665a\u4e0a\u53c8\u6539\u4e86\u4e00\u4e0b\uff0c\u624d\u6ca1\u6709\u95ee\u9898\u3002\u8fd9\u4e2a\u8f6f\u4ef6\u5c31\u5230\u8fd9\u91cc\u4e86\uff0c\u4e0d\u60f3\u518d\u5199\u4e0b\u53bb\u4e86\uff01\u5c31\u8ba92.0\u6210\u4e3a\u6700\u540e\u4e00\u4e2a\u7248\u672c\u5427\uff0c\u53ef\u80fd\u4e5f\u53ea\u6709\u6211\u672c\u4eba\u624d\u6709\u8fd9\u4e2a\u7248\u672c\u2026\u2026<\/p>\n<p><img decoding=\"async\" src=\".\/wp-content\/uploads\/hibaidu\/3feb297e60295a2328388a15.jpg\" alt=\"\" border=\"0\" \/><\/p>\n<p>\u5e16\u4e0a\u4e24\u975e\u5e38\u91cd\u8981\u7684\u51fd\u6570\u3002<\/p>\n<pre class=\"brush: delphi; title: ; notranslate\" title=\"\">\r\n\/\/\u5c06\u6570\u636e\u8f6c\u6362\u6210\u5357\u65b9CASS\u7684\u6570\u636e\u683c\u5f0f\r\nprocedure Tform1.StringToNF(s:AnsiString);\r\nvar temp2,tempData:AnsiString;\r\n    i,j:integer;\r\nbegin\r\n  dataString:=dataString+s;\r\nrepeat\r\n  i:=pos('+',string(dataString)); j:=pos('_',string(dataString));\r\n  if((i&lt;&gt;0) and (j&lt;&gt;0)) then\r\n  begin\r\n  dataString:=Copy(dataString,i+1,length(dataString)-i);\r\n  j:=pos('_',string(dataString));\r\n  tempData:=AnsiString(trim(string(Copy(dataString,1,j-1))));\r\n  dataString:=copy(dataString,j+1,length(dataString)-j);\r\n  case times mod 4 of\r\n    1:  tempNFstr:=tempNFstr+tempData+',,';\r\n    2,3:\r\n      begin\r\n        temp2:=AnsiString(IntToStr(strtoint(string(tempData))));\r\n        Insert('.',temp2,length(temp2)-2);\r\n        tempNFstr:=tempNFstr+temp2+',';\r\n      end;\r\n    0:\r\n      begin\r\n        temp2:=AnsiString(IntToStr(strtoint(string(tempData))));\r\n        Insert('.',temp2,length(temp2)-2);\r\n        tempNFstr:=tempNFstr+temp2;\r\n        bsSkinMemo1.Lines.Add(string(ExchangeXY(tempNFstr)));\r\n        label102.Caption:='\u5df2\u4e0b\u8f7d\u70b9\u6570\uff1a'+IntToStr(times div 4);\r\n        tempNFstr:='';\r\n      end;\r\n  end;\r\n  end;\r\n  times:=times+1;\r\nuntil ((pos('+',string(dataString))=0) or (pos('_',string(dataString))=0));\r\nend;\r\n\r\n\/\/\u5c06X,Y\u5750\u6807\u4e92\u6362(\u56e0\u6d4b\u7ed8\u5750\u6807\u7cfb\u4e0e\u6570\u5b66\u7684X,Y\u53cd\u7684)\r\nfunction ExchangeXY(s:Ansistring):Ansistring;\r\nvar i:integer;\r\n    s1,s2,s3,s4:AnsiString;\r\nbegin\r\n   i:=pos(',',string(s));\r\n   s1:=copy(s,1,i+1);\r\n   s:=Copy(s,i+2,length(s)-i);\r\n\r\n   i:=pos(',',string(s));\r\n   s2:=copy(s,1,i);\r\n   s:=Copy(s,i+1,length(s)-i);\r\n\r\n   i:=pos(',',string(s));\r\n   s3:=copy(s,1,i);\r\n   s4:=Copy(s,i+1,length(s)-i);\r\n\r\n   Result:=s1+s3+s2+s4;\r\nend;\r\n<\/pre>\n<p><img decoding=\"async\" src=\".\/wp-content\/uploads\/hibaidu\/c523dc1ab5a646fead6e75d8.jpg\" alt=\"\" border=\"0\" \/><\/p>\n<\/div>\n","protected":false},"excerpt":{"rendered":"<p>\u4eca\u5929\u521a\u4ece\u82b1\u5c71\u56de\u6765\u3002\u82b1\u679c\u5c71\u5b9e\u4e60\u5171\u82b1\u4e24\u5929\uff0c\u7b2c\u4e00\u5929\u4ece\u65e9\u4e0a8\uff1a30\u51fa\u53d1\uff0c\u4e0b\u53484\u70b9\u56de\u6821\uff0c\u7b2c\u4e8c\u5929\u65e9\u4e0a7\uff1a00\u51fa\u53d1\uff0c\u4e0b\u53483\u70b9 [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[5],"tags":[],"class_list":["post-613","post","type-post","status-publish","format-standard","hentry","category-diary"],"_links":{"self":[{"href":"https:\/\/kyle.ai\/blog\/wp-json\/wp\/v2\/posts\/613","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/kyle.ai\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/kyle.ai\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/kyle.ai\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/kyle.ai\/blog\/wp-json\/wp\/v2\/comments?post=613"}],"version-history":[{"count":2,"href":"https:\/\/kyle.ai\/blog\/wp-json\/wp\/v2\/posts\/613\/revisions"}],"predecessor-version":[{"id":4661,"href":"https:\/\/kyle.ai\/blog\/wp-json\/wp\/v2\/posts\/613\/revisions\/4661"}],"wp:attachment":[{"href":"https:\/\/kyle.ai\/blog\/wp-json\/wp\/v2\/media?parent=613"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/kyle.ai\/blog\/wp-json\/wp\/v2\/categories?post=613"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/kyle.ai\/blog\/wp-json\/wp\/v2\/tags?post=613"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}