![](https://blogs.ontoorsolutions.com/wp-content/uploads/2023/01/preview-3.gif)
Sometimes user don’t want to go with add row button for a new row generation on those cases I will show you how to generate new line without using add row button. for this, you will have to follow some simple steps:
- Create Interactive grid using following query and Define a static ID “REPORT_ID”.
SELECT ROWID,
empno,
ename,
job,
deptno
FROM emp
WHERE 1 = 2
- Create Dynamic action with Change Event and Execute JavaScript Action on last column from where you will create a new row.
![](https://blogs.ontoorsolutions.com/wp-content/uploads/2023/01/image-395-1024x347.png)
- Copy and Paste the following JavaScript Code:
apex.region("REPORT_ID").widget().interactiveGrid("getActions").invoke("insert-record")
![](https://blogs.ontoorsolutions.com/wp-content/uploads/2023/01/image-396-1024x364.png)
Note: If You want to add row from the top then must use bellow code instead of above code:
apex.region("REPORT_ID").widget().interactiveGrid("getActions").invoke("row-add-row")