BPM form from a button

So like this. If I don’t put that in there, it would run every custom action that has a base process, right? Thanks for the clarification, that’s why I asked.

1 Like

Correct

One more question (for now anyways), do custom actions always have to be called through code then? I was sort of expecting these to show up in the actions menu of a deployed dashboard, but it doesn’t. Is that expected behavior?

They will show up in the actions menu. If you add the action in your Dashboard.

1 Like

Thank you. The help files are a bit discombobulated with bits and pieces spread around, but nothing that makes a ton of sense.

Interesting conundrum. If I don’t have any information in my grid, the BPM form won’t fire. I don’t want to populate the grid until the BPM form fires so that I can get the filters in place. ugghhhhh…

Any slick ideas on how to do this? Should I just look at customizing the parameters form? Can I do that? I’ve seen where I can get in and customize it, but I don’t know how to apply it. I would imagine that I have to set the customization in the Processes section of the Menu Maintenance?

So you want to run an action on an EmptyBAQ and what does the action do? Ask you to type something in? (A Barcode?) Then you’ll use that barcode to filter down the Dashboard?

If so why not just use a parameter, it automatically prompts you to enter the parameter and uses it to filter.

Because I need to parse the barcode, so I need a customization. Hence the question on customizing the parameter screen. If I can apply it, then that’s the way I will go.

Although it is technically possible to customize the parameter screen I don’t think that’s going to be too fisible. Why not just take the parameter as a whole string and “parse” it in your BAQ?
Meaning wherever you are using your param in your BAQ use an expression to get the pieces you need.

so basically call the same parameter in an expression for each criteria in the BAQ and then have the expression grab the requisite piece? That could work. Good idea.

Back to the customize the parameter screen, what makes that difficult? Is it applying it? The customization screen seems to work fine, it was just not knowing how to make it work without customization mode.

Right there’s no way to apply it as far as I can tell. Maybe using Process Calling… but seems cumbersome how do you differentiate between THIS BAQ and another one?

1 Like

Right

ok. I’ll go with your parameter idea. That seems more feasible anyways.

Hi @Banderson,
have you managed to do this? reading through this threads can not see any C# code to call the form directly through UI script editor,

am i correct saying that you are triggering the relevant BPM when clicking a button on UI form, then when the BPM run will go through a condition, to call the BPM Form ?

I ended up making a listener call and did all of the code in the customization instead of the BPM. I couldn’t figure out how to get the BPM to work since I needed to the filter prior to the BAQ being populated. The customization works great though.

I used help from code that @fredmeissner posted to get an idea of what to do.

Let me know if you have specific questions and I can post some of the code.

1 Like

@Banderson
i am very interested to see your code of doing it this way, as my way is triggering a callcontext variable and changing the relevant RowMod to Update status, when clicking my button, then these two will trigger my BPM and its form, my code on script editor screen of Part BO is:

private void btnEffExclude_Click(object sender, System.EventArgs args)
{
// ** Place Event Handling Code Here **
EpiDataView edvCallContextBpmData = ((EpiDataView)(this.oTrans.EpiDataViews[“CallContextBpmData”]));
System.Data.DataRow edvCallContextBpmDataRow = edvCallContextBpmData.CurrentDataRow;
if ((edvCallContextBpmDataRow != null))
{
edvCallContextBpmDataRow.BeginEdit();
edvCallContextBpmDataRow[“Checkbox01”] = true;
edvCallContextBpmDataRow.EndEdit();
}
EpiDataView edvPartRev = ((EpiDataView)(this.oTrans.EpiDataViews[“PartRev”]));
System.Data.DataRow edvPartRevRow = edvPartRev.CurrentDataRow;
if(edvPartRevRow != null)
{
edvPartRevRow[“RowMod”] = ‘U’;
oTrans.Update();
}
}
this simply will trigger the following BPM which has a call for a BPM Form:

My final solution isn’t triggering a BPM at all. I’m assuming that what you mean by “it”? I just have listener set up to listen for a special character at the beginning of the barcode, and then parse the barcode to fill in the tracker values, run the BAQ, then use the results of the BAQ to run a loop to clock in based on what’s in the grid.

What is it that you want to do that you need help with?

i want the C# code to call the PBM form to pop it up without the need to trigger any BPM, capture the entered parameter, then save it directly on a UD field i created on that tt table, the BPM form is giving me a flexible control rather than create a std C# form.

Yeah, I couldn’t figure it out, because I couldn’t figure out where the hang the BPM on. I was trying to use a custom action on a BAQ so that it wouldn’t affect anything else, and that didn’t work. I was calling the query using the dynamic query adapter. But it didn’t work, so I abandoned the idea.

1 Like