Web Service Proxy class
-
I created a Web Service that has a method that takes string arrays for ex: public void CalculateModel(string[] stringList1, string[] stringList2) { //code here } When I add this web service as a web reference to my C++ application it generates a proxy class, in the proxy class it displays the array parameters like this: BSTR* stringList1, int __stringList1_nSizeIs, BSTR* stringList2, int __stringList2_nSizeIs, Then it does the following: checks these pointers for NULL if ( stringList1 == NULL ) return E_POINTER; if ( stringList2 == NULL ) return E_POINTER; So my question is how do I prevent the proxy file from adding these checks for NULL? because I do allow the user to pass in an empty string array which is defaulted to NULL on the C++ side. Thanks
-
I created a Web Service that has a method that takes string arrays for ex: public void CalculateModel(string[] stringList1, string[] stringList2) { //code here } When I add this web service as a web reference to my C++ application it generates a proxy class, in the proxy class it displays the array parameters like this: BSTR* stringList1, int __stringList1_nSizeIs, BSTR* stringList2, int __stringList2_nSizeIs, Then it does the following: checks these pointers for NULL if ( stringList1 == NULL ) return E_POINTER; if ( stringList2 == NULL ) return E_POINTER; So my question is how do I prevent the proxy file from adding these checks for NULL? because I do allow the user to pass in an empty string array which is defaulted to NULL on the C++ side. Thanks
A check for NULL isn't going to hurt you, is it? It doesn't look like the wsdl.exe tool has an option like this. This posting is provided "AS IS" with no warranties, and confers no rights. Alex Korchemniy
-
A check for NULL isn't going to hurt you, is it? It doesn't look like the wsdl.exe tool has an option like this. This posting is provided "AS IS" with no warranties, and confers no rights. Alex Korchemniy
Yes, it does effect me the check for NULL because it returns if the array is NULL & does not continue processing the data.
-
A check for NULL isn't going to hurt you, is it? It doesn't look like the wsdl.exe tool has an option like this. This posting is provided "AS IS" with no warranties, and confers no rights. Alex Korchemniy
Yes, it does effect me the check for NULL, because it returns if the array is NULL & does not continue processing the data.