Create Standard Data Transfer

If the Data Sources (LU:s) for the forms you are navigating between share the same keys, it is straight forward to set up data transfer between the forms.

Sending Form

In most cases, the navigation is done from a context menu item.

In the EnabledWhen-method you enable the menu item if navigation to the requested form should be possible. In the MenuActions-method you execute the navigation. In the example here we only consider the navigation itself, no validation of data is done. Normally you probably at least check that you have populated the form.

private bool menuItemInventoryPart_EnabledWhen()
{
   return vrtDataSourceCreateWindow(Ifs.Fnd.ApplicationForms.Const.METHOD_Inquire, Pal.GetActiveInstanceName("frmInventoryPart"));
}
If possible, avoid sending/posting messages (Sal.SendMsg/Sal.PostMsg). The main reason for that is due to often being forced to provide string arguments using the dedicated wParam and/or lParam parameters, which in turn requires a conversion from string to number using the methods Sal.HStringToNumber/Sal.NumberToHString. These methods will create a "mapping" reference on the heap and keep it for quite a while, resulting in using a larger memory allocation that is often necessary.
 
private SalNumber menuItemInventoryPart_MenuActions()
{
   return vrtDataSourceCreateWindow(Ifs.Fnd.ApplicationForms.Const.METHOD_Execute, Pal.GetActiveInstanceName("frmInventoryPart"));
}

Example: Navigation from ifsapf:frmPurchasePart to ifsapf:frmInventoryPart.

Receiving Form

Nothing needs to be done. The form will populate with the sent data.