简体   繁体   English

如何在Office 365中使用下划线搜索联系人姓名?

[英]How to search the contact name with underscore in office 365?

I searched contact using office 365 API I got the value. 我使用office 365 API搜索了联系人,并获得了价值。 One of the scenario it displayed error message. 它显示错误消息的情况之一。 When I used '_' symbol in request it showed response returned as HTTP error 400. 当我在请求中使用'_'符号时,它显示响应作为HTTP错误400返回。

Eg: 1) https://outlook.office.com/api/v2.0/Me/Contacts ?$search=james kumar 例如:1) https://outlook.office.com/api/v2.0/Me/Contacts?$ search = james kumar

No error. 没错 I changed the name james kumar into james_kumar. 我将名称james kumar更改为james_kumar。 Now I tried the following query. 现在,我尝试了以下查询。

2) https://outlook.office.com/api/v2.0/Me/Contacts ?$search=james_kumar it showed as, Array ( [errorNumber] => 400 [error] => Request returned HTTP error 400 ) 2) https://outlook.office.com/api/v2.0/Me/Contacts?$ search = james_kumar它显示为Array([errorNumber] => 400 [error] =>请求返回了HTTP错误400)

用双引号括住您的字词,例如:

https://outlook.office.com/api/v2.0/Me/Contacts?$search="james_kumar"

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM