How to make use of “category” according to “A.3.4 Field Search Request” of developers guide? The Bloomberglp.Blpapi.dll is from blpapi_dotnet_3.4.8.1., development by C# .net.
I used the following code in order to get the information but it does not work.
Service refDataSvc = session.GetService("//blp/refdata");
Request request = refDataSvc.CreateRequest("ReferenceDataRequest");
request.Append("securities", "/isin/CNE1000002Q2 HK");
Element element = request.GetElement("include");
element.SetElement("productType", "Equity");
element.SetElement("fieldType", "Static");
Element element1 = element.GetElement("category");
element1.AppendValue("Ratings");
element1.AppendValue("Analysis");
element1.AppendValue("Corporate Actions");
session.SendRequest(request, null);
I also tried other ways
a)
Service refDataService = session.GetService("//blp/refdata");
Request request = refDataService.CreateRequest("ReferenceDataRequest");
Element securities = request.GetElement("securities");
securities.AppendValue("IBM US Equity");
Element fields = request.GetElement("fields");
fields.AppendValue("PX_LAST");
Element element1 = fields.GetElement("category");
element1.AppendValue("Corporate Actions");
session.SendRequest(request, null);
b)
Service refDataService = session.GetService("//blp/refdata");
Request request = refDataService.CreateRequest("ReferenceDataRequest");
Element securities = request.GetElement("securities");
securities.AppendValue("IBM US Equity");
Element element1 = request.GetElement("category");
element1.AppendValue("Corporate Actions");
session.SendRequest(request, null);
Both are not successful. Could anyone advise me on this?
来源:https://stackoverflow.com/questions/11899919/bloomberg-api-field-search-request