I am trying to add records to the DtaPmTrxStatsDetailWindow.SwCodes scrolling window from a GPAddin form. The addin form has a combobox from which I will select the codeid. I then try to add the record to the scrolling window but, if I do not manually move my cursor to the first cell in the first line, the codeid and posting code description are dropped into the second line and disappear when I try to auto allocate or even move my cursor to the scrolling window. See below for my code to add the data:
private void btnOk_Click(object sender, EventArgs e)
{
GPAddIn.PmTrxStatsDetailWindow.SwCodes.DtaCodeId.Value = cbRegion.SelectedValue.ToString();
GPAddIn.PmTrxStatsDetailWindow.SwCodes.DtaPostingDescr.Value = "test";
GPAddIn.PmTrxStatsDetailWindow.SwCodes.LocalCodeDescr.Value = cbRegion.SelectedText.ToString();
this.Close();
}
I have tried using the various "line" events with no luck. Any help will be greatly appreciated!
My goal is to add the record to the scrolling window and cause the Auto Allocate button to click programmatically so the user will not do anything beyond selecting the codeid from the addin form. I have not figured out how to click on a button in GP programmatically but my priority at this point is adding the record to the scrolling window.
Debi
*This post is locked for comments