Here I retrieve the output parameter from a stored procedure in Entity Framework(EDMX) (the out parameter is TransactionId) here i want to transfer the value TransactionId to Scdid(in the next post method) how to get the TransactionId = Scdid in the controller
my API code is
public class StockcountheaderController : ApiController
{
private adminv2Entities enqentities = new adminv2Entities();
[HttpPost]
private void Stock([FromBody] List<spGetNewStockCountHeader_Result> jsonvalues)
{
foreach (spGetNewStockCountHeader_Result Datastock in jsonvalues)
{
ObjectParameter TransactionId = new
ObjectParameter("TransactionId", typeof(Int32));
spGetNewStockCountHeader_Result Stockobject = new
spGetNewStockCountHeader_Result();
Stockobject.UserID = Datastock.UserID;
Stockobject.created = Datastock.created;
Stockobject.CompanyID = Datastock.CompanyID;
Stockobject.modified = Datastock.modified;
Stockobject.modifieduserid = Datastock.modifieduserid;
Stockobject.confirm = Datastock.confirm;
Stockobject.ShopId = Datastock.ShopId;
enqentities.spGetNewStockCountHeader(Datastock.UserID,
Datastock.created,
Datastock.CompanyID, Datastock.modified,
Datastock.modifieduserid, Datastock.confirm,
Datastock.ShopId, TransactionId);
}
}
}