Clarification on Pick() Method
Hi All,
As per bookshelf, "The Pick method places the currently chosen record in a pick business component into the appropriate fields of the parent business component.".
Consider a scenario where I'm trying to insert a record in Service Request BC.
What is the difference between the following 2 code snippets??
Code.1:
SetFieldValue(“SR Type”, sSRType);
Code.2:
Even if I'm gonna use SetFieldValue, the fields in the PickMap will also be set right???
Regards,
Maggi.
As per bookshelf, "The Pick method places the currently chosen record in a pick business component into the appropriate fields of the parent business component.".
Consider a scenario where I'm trying to insert a record in Service Request BC.
What is the difference between the following 2 code snippets??
Code.1:
SetFieldValue(“SR Type”, sSRType);
Code.2:
var oSRTypeBC = GetPicklistBusComp("SR Type");
with(oSRTypeBC)
{
SetViewMode(AllView);
ClearToQuery();
SetSearchSpec("Value", sSRType);
SetSearchSpec("Type", "SR Type");
ExecuteQuery(ForwardOnly);
if(FirstRecord())
{
Pick();
}
}
with(oSRTypeBC)
{
SetViewMode(AllView);
ClearToQuery();
SetSearchSpec("Value", sSRType);
SetSearchSpec("Type", "SR Type");
ExecuteQuery(ForwardOnly);
if(FirstRecord())
{
Pick();
}
}
Even if I'm gonna use SetFieldValue, the fields in the PickMap will also be set right???
Regards,
Maggi.
0