Hi,
I am working on a protocol and have a good use case for using a Dynamic Table. I have seen Dynamic Tables being used in the past but cannot recall what protocol it was and when I last saw it. When looking at the Docs there is a section mentioning of it's existence but nothing more than that (Table parameters | DataMiner Docs). I presume it works similar to the Matrix logic but need more to get started with it.
Is it possible to get an example or point me to where it is documented.
Thanks.
P.S Text tables is also mentioned but also couldn't find anything more about it in the docs.
Hi Aston,
Hope you are well.
We were able to update the column description from teh code of our WF by using the Set Parameter Description method.
Our usecase was that we have 1 out of 2 different (traps) protocols that might be used in the subscriptions of the WF to update a single table (traps table). The order of the columns was different and we have had different headers for each type of the traps. Therefore, we used an "Information Template" on each of the traps protocols to configure the expected headers for the columns.
Then, depending on the source of the received subscriprion message, we check the information template headers and update the headers of the columns if they are different to the existing ones.
Here is the code snippet where we were updating the headers:
public class TrapsTableColumnsHeaders
{
public static void LoadTrapsTableRhel8Headers(SLProtocolExt protocol, string protocolName)
{
GetProtocolMessage message = new GetProtocolMessage(protocolName, "Production");
GetProtocolInfoResponseMessage informationTemplates = protocol.SLNet.SendSingleResponseMessage(message) as
GetProtocolInfoResponseMessage;var overridenParams = informationTemplates.Parameters.Where(param =>
param.InformationTemplateData.Filter == "*");
foreach (var parameterInfo in overridenParams)
{
var trapsTableColumnPid = (parameterInfo.ID + 2001); // The Pids in the traps driver start from 1006, and start in this WF from 3007
var currentDesc = Convert.ToString(protocol.GetParameterDescription(trapsTableColumnPid));
if (!string.IsNullOrEmpty(currentDesc) && currentDesc != parameterInfo.Description)
protocol.SetParameterDescription(trapsTableColumnPid, parameterInfo.Description);
}
}
}
Note that there was not any way for us to show/hide the columns or setting their width.
Hope this helps 🙂
Thanks Saddam,
Really helpful and well explained.
Will keep this in mind for next time.
Many thanks 🙂