LaunchFormOptions

How do I figure out what the system is looking for when using ProcessCaller and LaunchFormOptions for the Pro Forma Invoice? Or any process, for that matter.

You can reflect into it…
Looks like it’s looking for a LFO.ValueIn = YourOrderNumber

You can reflect into it…

ELI5?

Sorry .NET Reflection

You can use a program like .Net Reflector to see what epicor expects and view (some of) the Epicor Code. For example for the pro-forma invoice. Epicor has this function on Form Loaded

it looks for if LaunchFormOpts is a ReportArgs
If not, then it looks for LaunchFormOpts.ValueIn being an order numer
etc…

1 Like

When I click on the new Pro Forma menu, it explodes Epicor. I get the “Trying to Reconnect” and all the screens go white. When I close the white pro forma window, it reconnects and gives me an object ref error.
Am I missing a step?

public void proFormaTool_Click(object sender, EventArgs args)
{
	EpiDataView edv = ((EpiDataView)oTrans.EpiDataViews["OrderHed"]);

	LaunchFormOptions lfo = new LaunchFormOptions();
	lfo.ValueIn = Convert.ToInt32(edv.dataView.Table.Rows[0]["OrderNum"]);;

	ProcessCaller.LaunchForm(oTrans,"UDCSG009", lfo);
}
1 Like

Only issue could be that it is looking for this.Trans.ReportParamView.HasRow… if that’s not true then maybe it is not executing…hmm

So, I got it, but I don’t know why it works.
“UDCSG009” refers to DotNetIT’s Doc Sender customization menu, which is what I was originally calling with ProcessCaller.
I created a new process for pro forma in Menu Maintenance, gave it a new Menu ID, and assigned the customization to the DNI (Base Ext) and called that new Menu ID with ProcessCaller and suddenly it works.

ah! the document sender customization probably uses the ValueIn or the LFO object.

1 Like