13.01.2013 Views

Connecting to PaymentTrust's Secure Transaction Network - WorldPay

Connecting to PaymentTrust's Secure Transaction Network - WorldPay

Connecting to PaymentTrust's Secure Transaction Network - WorldPay

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

' Submit <strong>to</strong> the STLink and s<strong>to</strong>re the result for handling.<br />

result = TMHTTP.submit() ß THE RESULT IS STORED HERE<br />

' Release the STL COM object<br />

set TMHTTP = nothing<br />

Code from this point onwards illustrates how the received data may be used.<br />

' In this sample the result is parsed and formatted <strong>to</strong> be displayed in a HTML table.<br />

' The result can be parsed and manipulated in any way such as: S<strong>to</strong>red in a database.<br />

' Arrays <strong>to</strong> split StringIn in<strong>to</strong> <strong>to</strong>kens<br />

Dim <strong>to</strong>kens1<br />

Dim <strong>to</strong>kens2<br />

'Split the result in<strong>to</strong> <strong>to</strong>kens at every '~'<br />

<strong>to</strong>kens1 = split(result, "~")<br />

' Build an HTML table <strong>to</strong> display data nicely.<br />

Dim table<br />

table = table & ""<br />

table = table & ""<br />

table = table & ""<br />

table = table & "Parameter"<br />

table = table & "Value"<br />

table = table & ""<br />

' Loop indexes<br />

Dim i1<br />

Dim i2<br />

' Loop through the <strong>to</strong>kens<br />

for i1=0 <strong>to</strong> UBound(<strong>to</strong>kens1)<br />

271<br />

table = table & ""

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!