Tuesday 3 March 2015

we can covert a string to a base enum also

Here say we have a base enum and we want to  assign a vaulue of the string to the base enum it can be done by   function "str2enum"



say we have a line od code :

 ledgerJournalTrans.AccountType = LedgerJournalACType::Bank;

it means AccountType 's value will be Bank

or else you can do this way also


  LedgerJournalACType   LedgerJournalACType;  //declare this variable in the top
ledgerJournalTrans.AccountType = str2enum(LedgerJournalACType,"Bank");

No comments:

Post a Comment

intercompany PO multiple product receipt by x++

public void processStampICPO(PackingSlipId _deliveryNote,                             Transdate _deliverydate,                             ...