Click here to Skip to main content
15,608,738 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hello guys, I lost sleep and my head with a problem sending the invoice to the sogei ws. I am NOT a top so in case of an answer please be simple. Let's talk about (vb) a simple project that generates an invoice should send it to the TS system. I pulled in the wsdl file via "add service reference" (I had to enter the direct path is what worries me in production). I see that VS 2019 has created all the classes. Well, at this point I pass to the code below, arrived at "Dim ccc = ws.Insert (insDoc)" the certificate error is generated (which I would like to skip). I saw that in the web.config the related endpoint has been inserted in applicationSettings. Sogei is not very clear at least for me, I am not a top and the ws are difficult for me so I turn to the upper floors in the hope you can give me help, working code, tips etc ...
thanks thanks thanks

my code:

What I have tried:

Dim DocSpesaGen As DocumentoSpesa730pPort = New DocumentoSpesa730pPort
Dim insDoc As inserimentoDocumentoSpesaRequest = New inserimentoDocumentoSpesaRequest
Dim docSpesa As documentoSpesa = New documentoSpesa

Dim ws As DocumentoSpesa730pPort = New DocumentoSpesa730pPort
ws.Credentials = New System.Net.NetworkCredential("Authorization", "Basic " & Convert.ToBase64String(Encoding.UTF8.GetBytes(userTS & ":" + passwdTS)))
ws.PreAuthenticate = True
Dim a = ws.Url
insDoc.pincode = txtPinCode.Text
Dim ccc = ws.Inserimento(insDoc)
Updated 5-Apr-21 10:16am

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900