Hi,
I have created New/Delete Command buttons under a new TabPage with 'ToolBar & List' Pattern. but that button getting disabled.
I have tried to write COC on init & updateDesign method on CustParameters form to change some standard fuctionality if any but buttons are still disabled.
Thanks,
Harshit
Harshit Singh That's great. Please verify the answer, so it help someone in future.
Hi Girish & Mohit,
yes, now I got that parameters Table can have only one record, I have created new Table & added it in CustParameters form & it works.
Thanks,
Harshit
Parameter tables have can have only one record per legal entity. You can create custom table and add it in CustParameters form. We have done the same.
I think SalesParameter table cannot have more than one record. As you see you have key field as index on the table it won't allow you create more than one record in a table.
One option will be creating a new table and add that table to form DataSource. If you create custom table you can create more than one records.
Thanks,
Girish S.
Hi Girish,
I have added my fields on Salesparameters Table which is the primary datasource of CustParameters form .& I have given Salesparameters as datasource on Tab page.
& index on Salesparameters is key field which has ParametersKey as EDT.
Thanks,
Harshit
Hi Girish,
I cannot change directly bcz working with formextension, using form COC init but getting errros which I specified in above reply.
Thanks,
Harshit
What is the DataSource you used for the tab page?
In which table you have created new fields?
What is the index on the table?
Thanks,
Girish S.
Hi Mohit,
Yes alowCreate & allowDelete Property set to no, I have wrote COC on init method, using this buttons gets enabled. But now I am able to create only one record. If I am creating 2nd record then its throwing error 'Record already exist' & if I am deleting that first record that already exist then it throwing error 'cannot delete Transaction'.
[ExtensionOf(formStr(CustParameters))] final class HSHTCustParametersForm_Extension { public void init() { next init(); SalesParameters_ds.allowCreate(true); SalesParameters_ds.allowDelete(true); } }
Thanks,
Harshit
If you set the AllowDelete and AllowCreate property to No - Add and Delete button will be disabled only.
You need to set that property to Yes on the DataSource level.
Thanks,
Girish S.
Hi Girish,
I gave the dataSource- Salesparameters to Action Pane bcz I have added grid which have custom fields from SalesParameters DataSource. Also I have already given Command property to New & Delete Buttons (New & DeleteRecord) & allowEdit Property set to yes only in Form Extension.
But that AllowDelete & AllowCreate Property set to no.
Thanks,
Harshit
André Arnaud de Cal...
292,111
Super User 2025 Season 1
Martin Dráb
230,934
Most Valuable Professional
nmaenpaa
101,156