Вниз
Скачать: CL | DM;

c VB на Delphi   Найти похожие ветки 

← →
ilka ©   (2003-11-07 16:38) [0]

Подскажите как переделать с visual basic на delphi?

Dim MyXMLDocument
Dim MyHTTPCommunicator

rem Creating MSHTML objects
Set MyXMLDocument = CreateObject ("MSXML2.DOMDocument")
Set MyHTTPCommunicator = CreateObject ("Msxml2.XMLHTTP")

MyXMLDocument.load ("C:\file.xml")

rem connect to webpage
MyHTTPCommunicator.open "POST", " http://localhost/test.asp", false

rem send xml to the page
MyHTTPCommunicator.send MyXMLDocument

rem and display te response
wscript.echo MyHTTPCommunicator.responseText


← →
AngryMac ©   (2003-11-07 16:44) [1]

Ну как-то так:


var
MyXMLDocument, MyHTTPCommunicator: OleVariant;
begin
MyXMLDocument := CreateOLEObject ("MSXML2.DOMDocument");
MyHTTPCommunicator := CreateOLEObject ("Msxml2.XMLHTTP");
MyXMLDocument.load("C:\file.xml");
MyHTTPCommunicator.open("POST", " http://localhost/test.asp", False); // (может вместо False -> 0)
MyHTTPCommunicator.send(MyXMLDocument);
ShowMessage(MyHTTPCommunicator.responseText);
end;



Страницы: 1 вся ветка

Скачать: CL | DM;



Память: 0.44 MB
Время: 0.018 c
1-56613
Zorlag
2003-11-05 19:59
2003.11.17
Помогите, пожалуйста с отправкой письма через Delphi!


1-56705
Maxon
2003-11-07 12:28
2003.11.17
Как управлять Windows Media Player


3-56482
wHammer
2003-10-28 14:51
2003.11.17
Проблема с инкрементом


3-56444
dolmat
2003-10-29 15:46
2003.11.17
Создание вычисляемого поля


1-56695
td
2003-11-07 16:08
2003.11.17
VCLZip и VCLUnZip




   Наверх