| gif | history | intraday | java | news | objects | options | quote | soap | spots | tickers | weather | end of day | wddx |

Requests:
 Quote
 Chart
 Lookup
Sample Code:
 Coldfusion
 ASP
 JSP
 PHP
 Perl
 
ASP
The ASP sample below uses a COM object called ASP tear. The code and other samples can be found at openwddx.org. In addition to the ASP Tear object there is a COM object that allows you to parse the WDDX XML packet returned from a query request. It is also included in the sample code below.

FinWin owes it's thanks to Kiran Kumar for the excellent and concise example found below.

Active Server Page Example
<%@ Language=VBScript %>
<%
	strSymbol ="INDU.X,COMPX.X,SPX.XO,NAJ.X,DAX.X,CAC.X,NIK.X,TYX.XO"
	set oHTTP = Server.CreateObject("SOFTWING.ASPtear")
	oHTTP.ForceReload = 1
	oHTTP.FollowRedirects = 1
	oHTTP.UserAgent = "Mozilla/4.0 (compatible; MSIE 5.0b2; Windows NT)"
	oHTTP.ConnectionTimeout = 90
	FinwinURL 	 = "Http://www.finwin.com/processCT/ProcessQuoteTag.cfm"
	PostData = "username=myUsername&password=myPassword&id=186&request=quote" &
	"type=query&symbol=" & strSymbol
	content = oHTTP.Retrieve(FinwinURL,1,PostData, "", "")
	
	set MyDeser = Server.CreateObject("WDDX.Deserializer.1")
	set MyRs = Server.CreateObject("WDDX.Struct.1")
	set MyRs = MyDeser.deserialize(content)

%>
<table border=0 width=608>
<tr bgcolor=DarkGray>
	<td align="center"><b>Index</b></td>
	<td align="center"><b>Value</b></td>
	<td align="center"><b>Change</b></td>
	<td align="center"><b>Open</b></td>
	<td align="center"><b>Low</b></td>
	<td align="center"><b>High</b></td>
</tr>
<%for RowNum = 1 to MyRs.getRowCount()%>
<tr bgcolor=#EEEEEE>
	<td><%=Replace(MyRs.getField (RowNum ,"DESC")&" "," I ","")%></td>
	<td><%=Round(MyRs.getField (RowNum ,"LAST"),2)%></td>
	<td width=80><%=Round(MyRs.getField (RowNum ,"CHANGE"),2)%></td>
	<td><%=Round(MyRs.getField (RowNum ,"OPEN"),2)%></td>
	<td><%=Round(MyRs.getField (RowNum ,"LOW"),2)%></td>
	<td><%=Round(MyRs.getField (RowNum ,"HIGH"),2)%></td>
</tr>
<%Next
 set MyRs = Nothing
%>
</table>  

DTN Market Access
9110 West Dodge Road, Suite 200   Omaha, Nebraska 68114
Copyright 2010, All rights reserved