Главная страница
Top.Mail.Ru    Яндекс.Метрика
Текущий архив: 2003.11.17;
Скачать: 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 вся ветка

Текущий архив: 2003.11.17;
Скачать: CL | DM;

Наверх




Память: 0.46 MB
Время: 0.027 c
14-56820
Marser
2003-10-25 13:51
2003.11.17
AVR 90S2313


14-56816
Шустрый
2003-10-21 13:08
2003.11.17
XP Manifest


1-56661
Jack
2003-11-05 10:46
2003.11.17
Exception


1-56710
BJValentine
2003-11-07 10:21
2003.11.17
Размер массива


1-56650
FlankerX
2003-10-31 12:22
2003.11.17
ICQ Winamp3