Empresas
Empleos
  • Sobre nosotros
  • Soluciones
    • Publicación de vacantes
      Publica tu vacante y recibe candidatos calificados en 48h.
    • Evaluación de candidatos
      500+ pruebas técnicas y psicológicas, más anti-fraude.
    • Headhunting
      Búsqueda ejecutiva a la medida de principio a fin.
    • Nómina + EOR
      Dispersión de nómina y EOR en más de 15 países de LATAM.
  • Precios
  • Empleos

0

169
Vistas
oracle Apex Interactive grid

I have a interactive grid. If no rows selected I want to display a error msg as 'No records selected'. If more than 1 record selected then display 'select 1 record'. If 1 row selected then call a procedure. How can I achieve this using Java Script?

The error message should appear as inline notification.

I have tried this code. But this doesn't give correct error message. If I try clicking one record it is giving correct error msg then if I click one more record the error msg is incorrect. I mean whatever error I'm getting for first time I'm getting the same error always.

var gridView = apex.region("your-IG-static-id").widget().interactiveGrid("getViews").grid;

var records = gridView.getSelectedRecords();

var recs = records.length;

if (recs = 0) {apex.message.alert("No records selected")};

if (recs > 1) {apex.message.alert("Select 1 record")};

if (recs = 1) {
    apex.server.process("CALL_YOUR_AJAX_PROCESS", {

        x01: $v("PAGE_ITEM_1") ,// Parameters to pass to AJAX process if any

        x02: $v("PAGE_ITEM_2") ,// Parameters to pass to AJAX process if any

      }, {

        //pageItems: ''

        //dataType: 'text'

      }).done(function (pData) {

        console.log(pData);

      });

};
about 4 years ago · Juan Pablo Isaza
Responde la pregunta
Encuentra empleos remotos

¡Descubre la nueva forma de encontrar empleo!

Top de empleos
Top categorías de empleo
Empresas
Publicar vacante Precios Comercial
Legal
Términos y condiciones Política de privacidad
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomiéndame algunas ofertas
Necesito ayuda