c#代码提示','附近有语法错误(已经换成半角字符了,vs2010里用全角字符在编译前就会报错)
代码:arr[]=AT+CIPSEND$GPRMC,20130517,081247.454,A,26.25951,N,131.12146,E,7.4,1.1,3.4,14...
代码:
arr[]=
AT+CIPSEND$GPRMC,20130517,081247.454,A,26.25951,N,131.12146,E,7.4,1.1,3.4,14,23.25,0.12,34,A*70
string[] arr = temp.Split(',');
string time = arr[2].PadLeft(15, '0');
arr[2] = arr[2].Insert(2, ":");
arr[2] = arr[2].Insert(5, ":"); 展开
arr[]=
AT+CIPSEND$GPRMC,20130517,081247.454,A,26.25951,N,131.12146,E,7.4,1.1,3.4,14,23.25,0.12,34,A*70
string[] arr = temp.Split(',');
string time = arr[2].PadLeft(15, '0');
arr[2] = arr[2].Insert(2, ":");
arr[2] = arr[2].Insert(5, ":"); 展开
3个回答
展开全部
你这个代码看起来到处是错的,如果想解决问题最起码要把问题说清楚吧。
arr[]=
AT+CIPSEND$GPRMC,20130517,081247.454,A,26.25951,N,131.12146,E,7.4,1.1,3.4,14,23.25,0.12,34,A*70
C#不支持这种语法,这句话是代码中的一部分吗?
另外注意N,131.12146,E,7.4,1.1,3.4,14,23.25,0.12,34,A*70,这段代码中23.25与0.12之间有一个全角的逗号。是这个原因吗?
arr[]=
AT+CIPSEND$GPRMC,20130517,081247.454,A,26.25951,N,131.12146,E,7.4,1.1,3.4,14,23.25,0.12,34,A*70
C#不支持这种语法,这句话是代码中的一部分吗?
另外注意N,131.12146,E,7.4,1.1,3.4,14,23.25,0.12,34,A*70,这段代码中23.25与0.12之间有一个全角的逗号。是这个原因吗?
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询