Announcements
No record found.
on Invent journal create form when name of move journal is changed description changes accordingly to name. here
here i have customized this site fields , now it should also be changed according to movement journal name as description is changing above.
Hi Sachin mittal,
On the InventJournalCreate form - On the name field modified method add code to get the site name based on the selection of name and assign it to site field.
Thanks,
Girish S.
Hi, As Girish mentioned, you can create CoC of use modified event of 'Name' control and based on the relation with Site field you can populate it. Let us know if you need assistance during implementing it (after you tried writing the code).
this is standard code
[ExtensionOf(FormControlStr( InventJournalCreate,InventJournalTable_JournalNameId ))] final class InventJournalCreate_Extension { public boolean modified() { var res = next modified(); InventJournalName journalName; InventJournalTable inventJournalTable; journalName = InventJournalName::find(inventJournalTable.JournalNameId); inventJournalTable.InventSiteId = journalName.OABSiteId; return res; } }
this code is not working
Hi, Try replacing Line#10 with below code
journalName = InventJournalName::find(InventJournalTable_JournalNameId.ValueStr());
Also inventJournalTable buffer will be empty, so add below line at line# 9
inventJournalTable = this.formrun().datasource(IdentifierStr(InventJournalTable)).cursor();
You have declared the buffer InventJournalTable and you don't have any select statement added.
[ExtensionOf(FormControlStr( InventJournalCreate,InventJournalTable_JournalNameId ))] final class InventJournalCreate_Extension { public boolean modified() { var res = next modified(); FormRun fRun; InventJournalName journalName; InventJournalTable inventJournalTable; frun = this.FormRun(); FormDataSource fds = frun.datasource(formDataSourcestr(InvnetJournalCreate, InvnetJOurnalTable)); inventJournalTable = fds.cursor(); journalName = InventJournalName::find(inventJournalTable.JournalNameId); inventJournalTable.InventSiteId = journalName.OABSiteId; return res; } }
thankyou it worked , i want to know if this same functionality can work on extension of tablestr InventJournalName ??
Yes, it will work the same way. In table modifiedField method, you can create case of JournalNameId and get value of form control JournalNameId in this.JournalNameId. Below code will work on CoC for modifiedField table method
journalName = InventJournalName::find(this.JournalNameId); this.InventSiteId = journalName.OABSiteId;
On table level you can write coc for the modifiedField method and add the logic there.
can you help with specific code ?? it would be very great
I don't think getting code here and implement it directly will not let you learn new things.
Try it yourself as suggestion given by Mohit and me and let us know for any issues.
We have no problem in giving you the code, but you have to learn writing code yourself.
There is lots of blog available for your scenario - Based on the blogs try to write code and if you face any issue let us know.
Under review
Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.
Congratulations to our 2026 Super Stars!
Thanks to all of our 2025 Community Spotlight stars!
These are the community rock stars!
Stay up to date on forum activity by subscribing.
André Arnaud de Cal... 586 Super User 2026 Season 1
Giorgio Bonacorsi 311
Diego Mancassola 271