API申请token时,返回index was outside the bounds of the array

栏目:k3wise知识作者:金蝶来源:金蝶云社区发布:2024-09-16浏览:1

API申请token时,返回index was outside the bounds of the array

今天录单的同事反馈,二次开发的同步功能出错,需要解决一下。

原本以为是程序代码的问题,调试代码

image.webp

停在申请token这一条地址上,翻译过来就是

http://192.168.0.231:80818/K3API/Token/Create?authorityCode=ee8d54df9f7ee41ca82d0923d2b9fef26xxxxxxx

通过这个地址申请获得token,

看了一下日志,如下面截图所示

image.webp

StatusCode:201

Error:Index was outside the bounds of the array.

第一次遇到这样的问题。

这个错误是说在访问数组时尝试使用的索引超出了数组的实际范围。

想不通是什么原因,只是申请Token,怎么会提示这个呢?


不管那么多,先按常规的处理方法整一遍

1、停止IIS服务,再启动

image.webp

2、网站管理--》重新启动

image.webp

3、应用池,所有的全部停止后,启动一次。

image.webp


还别说,这么一套下来,再运行代码调试,居然真的正常了,但问题的根源还是没有找到,不知道后面还会不会出现,只能继续观察了。


API申请token时,返回index was outside the bounds of the array

今天录单的同事反馈,二次开发的同步功能出错,需要解决一下。原本以为是程序代码的问题,调试代码停在申请token这一条地址上,翻译过来就...
点击下载文档
确认删除?
回到顶部
客服QQ
  • 客服QQ点击这里给我发消息