PopUpAddConsDlg(String,Boolean,String,String,Object,Boolean,Boolean,Boolean,Boolean,Boolean,Double,Double,Double,Int32,Double,Object,Object) Method
- Last UpdatedNov 06, 2025
- 2 minute read
The PopUpAddConsDlg() method opens the Add Consumption dialog. This dialog allows the user to enter consumption for a specified BOM component of the current job.
This overload of the method allows you to specify the quantity per parent item, which is assumed to be 1 in the other overload. It also allows you to specify the minimum grade that can be consumed (the other overload has no restrictions.
'Declaration
Public Overloads Function PopUpAddConsDlg( _
ByVal jobDesc As String, _
ByVal dlgForSteps As Boolean, _
ByVal itemID As String, _
ByVal itemDesc As String, _
ByVal bomPos As Object, _
ByVal must_consume_from_inv As Boolean, _
ByVal may_choose_alt_inv_loc As Boolean, _
ByVal may_create_lots As Boolean, _
ByVal must_consume_from_wip As Boolean, _
ByVal update_inv As Boolean, _
ByVal actualQty As Double, _
ByVal maxQty As Double, _
ByVal consumedQty As Double, _
ByVal stepNo As Integer, _
ByVal qtyPerFG As Double, _
ByVal reqGradeCd As Object, _
ByVal job_bom_subst_exist As Object _
) As Boolean
public bool PopUpAddConsDlg(
string jobDesc,
bool dlgForSteps,
string itemID,
string itemDesc,
object bomPos,
bool must_consume_from_inv,
bool may_choose_alt_inv_loc,
bool may_create_lots,
bool must_consume_from_wip,
bool update_inv,
double actualQty,
double maxQty,
double consumedQty,
int stepNo,
double qtyPerFG,
object reqGradeCd,
object job_bom_subst_exist
)
Parameters
- jobDesc
- Required. Holds the description of the job.
- dlgForSteps
- Required. Holds a flag that, if set to true, indicates that consumption is being recorded at a step.
- itemID
- Required. Holds the ID of the item being consumed.
- itemDesc
- Required. Holds the description of the item being consumed.
- bomPos
- Optional. Hold the BOM position of the item being consumed.
- must_consume_from_inv
- Required. Holds a flag that, if set to true, indicates that consumption must come from inventory.
- may_choose_alt_inv_loc
- Required. Holds a flag that, if set to true, indicates that an alternative inventory location can be chosen.
- may_create_lots
- Required. Holds a flag that, if set to true, indicates that new lots can be created.
- must_consume_from_wip
- Required. Holds a flag that, if set to true, indicates that consumption must come from WIP.
- update_inv
- Required. Holds a flag that, if set to true, indicates that inventory is to be updated.
- actualQty
- Required. Holds the quantity of the item that is required.
- maxQty
- Required. Holds the actual maximum quantity of the item. This value is equal either to the maximum quantity per parent item or to the maximum per parent item times the start quantity or times the quantity produced (whichever is greater).
- consumedQty
- Required. Holds the quantity of the item that has been consumed.
- stepNo
- Required. Holds the number of the step in which the consumption has occurred.
- qtyPerFG
- Required. Holds the quantity per parent item.
- reqGradeCd
- Optional. Holds the required grade of the item when consumed.
- job_bom_subst_exist
- Optional. Holds a flag that, if true, indicates that a job BOM substitute for the item exists. This parameter is currently not supported by the dialog.
Return Value
Returns true if the user enters consumption; otherwise, it returns false.