// Spludlow Software // Copyright © Samuel P. Ludlow 2020 All Rights Reserved // Distributed under the terms of the GNU General Public License version 3 // Distributed WITHOUT ANY WARRANTY; without implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE // https://www.spludlow.co.uk/LICENCE.TXT // The Spludlow logo is a registered trademark of Samuel P. Ludlow and may not be used without permission // v1.14 using System; using System.Collections.Generic; using System.Linq; using System.Web; using System.Web.UI; using System.Web.UI.WebControls; using System.Data; public partial class CallSet : System.Web.UI.Page { protected void Page_Load(object sender, EventArgs e) { string host = this.Request.QueryString["Host"]; string queue = this.Request.QueryString["Queue"]; string messageId = this.Request.QueryString["Message"]; Spludlow.CallSet callSet = Spludlow.MessageQueues.Peek(host, queue, messageId); this.DisplayData1.Display(callSet); DataTable callSetTable = Spludlow.Data.TextTable.ReadText(new string[] { "Index Host Queue Assembly Type Method Flags PrevResultIndex PickUpQueue", "Int32 String String String String String String Int32 String", }); for (int index = 0; index < callSet.Calls.Length; ++index) { Spludlow.CallMethod method = callSet.Calls[index]; callSetTable.Rows.Add(new object[] { index, method.Host, method.Queue, method.Assembly, method.Type, method.Method, method.Flags, method.PrevResultParamIndex, method.PickUpQueue }); } this.DataListCallSet.DataSource = callSetTable; this.DataListCallSet.DataBind(); } protected void DataListCallSet_ItemDataBound(object sender, DataListItemEventArgs e) { if (e.Item.ItemType != ListItemType.Item) return; DataRow methodRow = ((DataRowView)e.Item.DataItem).Row; int index = (int)methodRow["Index"]; GridView gridView = (GridView)e.Item.FindControl("GridViewCallMethod"); gridView.DataSource = Spludlow.Data.ADO.WireDataSet(methodRow); gridView.DataBind(); } }