I’m trying to mimic the behaviour of the “File → New → New Release” button in a purchase order. I’ve created a customization where clicking a “+” button creates a new release for the PO.
I can swap to the releases tab fine, but when it comes to switching to a specific release I can’t seem to figure it out.
My initial idea was to just set the value in the ComboPlus control or try setting it to active.
i.e
But these didn’t work. I also tried finding the node in the treeview and activating it, but it can’t find the releases as a node. For example, when I traverse the tree and get to where releases should be, I can’t actually interact with the individual release nodes.
My final idea would be to trigger the ClickLastButton event manually, similar to a PerformClick(), but I’m not sure how to do this
If anybody has other ideas I’d appreciate any help.
Yeah, the data is all looking good after I call the BO methods. I just need it to swap to the correct tab and select the corresponding release when it’s created now just like the original “New Release” button.
To clarify though, relNavControl.EpiCombo.Value = releases; is setting the navigation control for releases to the latest release. The ‘releases’ variable is based on the number of already existing rows in the control and incremented after GetNewPORel is called.
My thought was that manually setting the control to the latest release would switch the form to that release under the releases tab, although it didn’t.
Jonathan thought that maybe it’s because the release is temporarily 0 when creating a new release, so maybe that would swap it. Also no luck.