![]() |
|
Soap ile ilgili sorun - Baskı Önizleme +- Delphi Can (https://www.delphican.com) +-- Forum: Delphi (https://www.delphican.com/forumdisplay.php?fid=3) +--- Forum: Genel Programlama (https://www.delphican.com/forumdisplay.php?fid=6) +--- Konu Başlığı: Soap ile ilgili sorun (/showthread.php?tid=5678) |
Soap ile ilgili sorun - mcb - 25-01-2021 Değerli arakadaşlar, java ile yazılmış bir soap servere istek gönderirken array olan parametreleri gönderemiyorum.int yada string sorunsuz gidiyor. wdsl import ederken oluşan dosyadaki "InvRegistry.RegisterInvokeOptions(TypeInfo(xxx), ioLiteral);" satırını silince sorunsuz çalışıyor. bu konuda bilgisi olan vamrıdır acaba Cvp: Soap ile ilgili sorun - tmrksmt - 25-02-2021 Hangi yöntemi kullanıyorsunuz tabi bilemiyorum ama şayet xml ise benim soap servislerinde eskiden kullandığım yöntem şu şekildeydi; xiDHTTP1 := TIdHTTP.Create(nil);
xidHttp1.ConnectTimeout := 20000;
ResponseData := TMemoryStream.Create;
PostData := TStringStream.Create(SoapMsg, TEncoding.UTF8);
xIdHTTP1.HTTPOptions := xIdHTTP1.HTTPOptions + [hoNoProtocolErrorException, hoWantProtocolErrorContent];
xIdHTTP1.Request.ContentType := 'text/xml';
xIdHTTP1.Request.Charset := 'utf-8';
xIdHTTP1.Request.Accept := 'text/xml';
xIdHTTP1.Request.CacheControl := 'no-cache';
xIdHTTP1.Request.CustomHeaders.Values['SOAPAction'] := 'http://tempuri.org/GetMessage';
xIdHTTP1.Post(YPostUrl, PostData, ResponseData);
PostData.Free;
xstr := TStringList.Create;
xstr.Clear;
xstr.BeginUpdate;
xstr.Add(Format('Response Code: %d', [xIdHTTP1.ResponseCode]));
// xstr.Lines.Add(Format('Response Text: %s', [xIdHTTP1.ResponseText]));
ResponseData.Position := 0;
//// ReadStringsAsCharset fonksiyonu için Uses'e bunu ekle = IdGlobalProtocols
ReadStringsAsCharset(ResponseData, xstr , xIdHTTP1.Response.Charset);
xstr.EndUpdate;
xmldoc := TXMLDocument.Create(nil);
xmldoc.XML.Text:=xstr.Text;
xmldoc.Active:=true;
Siparisler1 := XMLParse_01( xmldoc.XML.Text );
Umarım size bir faydası olur... Cvp: Soap ile ilgili sorun - ss1907 - 25-02-2021 (25-01-2021, Saat: 13:57)mcb Adlı Kullanıcıdan Alıntı: Değerli arakadaşlar, Aşağıdaki şekilde kullanmayı dener misin ? InvRegistry.RegisterInvokeOptions(TypeInfo(xxx), ioDocument); Cvp: Soap ile ilgili sorun - enigma - 25-02-2021 (25-02-2021, Saat: 03:25)tmrksmt Adlı Kullanıcıdan Alıntı: Hangi yöntemi kullanıyorsunuz tabi bilemiyorum ama şayet xml ise benim soap servislerinde eskiden kullandığım yöntem şu şekildeydi;Merhaba. Ben SOAP ile veri gönderip cevap almak için, HTTPReqresp1.Execute(GelecekCevapVerisi. GonderilenXMLVerisi); Şeklinde kullanıyorum. Siz sadece POST yani gönderim yapıyorsunuz. Cvp: Soap ile ilgili sorun - tmrksmt - 25-02-2021 (25-02-2021, Saat: 12:09)enigma Adlı Kullanıcıdan Alıntı:(25-02-2021, Saat: 03:25)tmrksmt Adlı Kullanıcıdan Alıntı: Hangi yöntemi kullanıyorsunuz tabi bilemiyorum ama şayet xml ise benim soap servislerinde eskiden kullandığım yöntem şu şekildeydi;Merhaba. Sizi anladım. Ancak örnek kodlarıma dikkat ederseniz proje icabı POST Metodunu kullandığımda dönen değeri Stream olarak alıyorum. Gerçi artık xml kullanan web servis de pek kalmadı. Ben de bu yüzden Rest API kullanıyorum ama belki bir yardımı dokunur diye paylaşmak istedim. Kolay gelsin. |