Auto New Line Generation in Interactive Grid Oracle APEX

Auto New Line Generation in Interactive Grid Oracle APEX

Preview 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. Dynamic action
  • Copy and Paste the following JavaScript Code:
apex.region("REPORT_ID").widget().interactiveGrid("getActions").invoke("insert-record")

javascript code 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")


Demo

You might like:


comments powered by Disqus