Good day everyone.
Im not that experienced with c# yet, and im having trouble in getting the correct information from a servlet response.
In my code i make a request usign code like this:
HttpWebRequest request = (HttpWebRequest)WebRequest.Create("https://<ServerIP>/downloadCfdWebView? serie=[serie]&folio=[folio]&tipo=[XML o PDF]&rfc=[rfc]&key=[key]");
// Execute the request
HttpWebResponse response = (HttpWebResponse)request.GetResponse();
In my servlet if the parameters are ok a XML or PDF file is retrieved when using the call in a browser, but if the file that i requested doesn't exist just trhow a message in the internet browser, "File doesn`t exist".
IF i make a call through c# to that servlet, with wich method can i validate that response? the methods showed by the HttpWebResponse doesn't seems to help to get that validation, and i want to know when the file didn't exist .
Maybe i need another form of call to the servlet.
Can anyone help me with some guidance, tip or trick?
Any help would be greatly appreciated!
View Complete Post