Greetings,
I am trying to find my way through MII. I suceeded in creating transactions and now I am about to make my first steps towards User interaction. I googled around and found some pages (like XMII Runner) that i used to create the following code inside a HTML.
I inserted a button and a container. The transaction I created is returning some integer value as output. I just want to dispaly that figuer in the container. As I understood, runner is returning an XML that can be parsed.
To do so, I used the following code to print runner XML but somehow I cannot manage to get the result....How can I call that runner?!
When I paste URL created by fnCrtRunner into my browser, I get below result - so Runner is working.
Can somebody assist me? That would be awesome!
Call XML
<button type="button" onclick="fnCallRunner();">Run Transaction</button>
<div id="result">empty</div>
<script type="text/javascript">
function fnCrtRunner()
{
var URL = "http://XXXX/XMII/Runner?Transaction=TEST/Browser GUI/getTargetQuantity&OutputParameter=DailyQuantity";
URL +="&Content-Type=text/xml&IsBinary=true";
return URL;
}
function fnCallRunner()
{
var runner = fnCrtRunner;
var x = new XMLHttpRequest();
x.open("GET", runner, true);
document.getElementById("result").innerHTML = x.responseXML;
}
Runner Result:
<?xml version="1.0" encoding="UTF-8"?>
<RowsetsDateCreated="2014-12-08T01:51:26"EndDate="2014-12-08T01:51:26"StartDate="2014-12-08T01:51:26"Version="14.0 SP5 Patch 3 (May 19, 2014)"TransactionID="-1">
<RowsetTrxID="-1">
<Columns>
<ColumnDescription=""MaxRange="0.0"MinRange="0.0"Name="DailyQuantity"SQLDataType="-5"SourceColumn="DailyQuantity"/>
</Columns>
<Row>
<DailyQuantity>15</DailyQuantity>
</Row>
</Rowset>
</Rowsets>