on 2017 Jun 30 8:47 AM
Hello everyone,
As my topic say,I bound a EC to Account ,when I create new EC item by QC,I want to get Account current country(at this point, it has not been saved to the database)
Process:Open a Account(old country code"CN")->change Account country(new country code"US")->create a EC item before save(I want to get "US" but not "CN")
I have tried the following two ways but I got the "CN" but not "US"
Wish someone can help me!
Thanks in advance!
Hello Baoxiang,
The query wont work as a Query.Execute(...) is always going to the database.
But: If you changed the CountryCode of the resp. Account and performed a round-trip this new value should be i the Account buffer. Thus retrieving the data via Account.Retrieve( <nodeID> ) should do it.
Bye,
. Horst
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hello Baoxiang,
With the ABSL code above you simply set the association. You will not retrieve any data. 😞
If the "ToCustomer" is already set you can simply use
var currentCustomerData = Customer.Retrieve( this.ToCustomer);
Else if the "this.DistrbutorID" represent the customer too
var currentCustomerData = Customer.Retrieve( this.DistributorID);
HTH;
. Horst
Hi Horst,
Yes , the Country is mandatory field in Account,I can get the old value but not new buffer value by using my ABSL.
Can you help me test access the Account buffer data and give me same sample code which can be run successful?
I'm so stupid,I just want to get Account buffer data by using some way like SAP CRM BOL..........
Thanks
Baoxiang
Hello Baoxiang,
First add an extension element to the Common node of the Customer BO and place this element on the UI.
Ensure that you can access this extension element within your ABSL coding.
Then maintain values for this element and save the changes.
Now call up the instance with the data maintained, change the value of the extension element and verify if the new value is available in the ABSL coding.
HTH,
. Horst
Hi Horst,
Thanks for your reply very much
I got your point and follow your steps one by one but I can't get the new value
this.Remarks = Customer.Retrieve(this.DistributorID).Common.GetFirst().GSTNo;
this.Remarks = Customer.Retrieve(this.DistributorID).CurrentCommon.GSTNo;
I used two ways to get the new value .
Thanks
Baoxiang
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
27 | |
1 | |
1 | |
1 | |
1 | |
1 | |
1 | |
1 | |
1 | |
1 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.