Autofilter Java Error Help

Scott Klement's open source interface to the POI HSSF/XSSF Spreadsheet Project for RPG Programmers. http://www.scottklement.com/poi/
Post Reply
DGR
Posts: 3
Joined: Tue Dec 09, 2025 5:39 pm

Autofilter Java Error Help

Post by DGR »

I created a prototype to set up the spreadsheet with the automatic filter. I tried to follow the instructions given for another problem. Unfortunately, when I launch the program, a Java error is reported that I can't interpret.

ID messaggio . . . . . : RNQ0301 Gravità . . . . . . . : 99
Tipo di messaggio . . : Interrogazione
Data invio . . . . . . : 18/12/25 Ora invio . . . . . . : 10:13:41

Messaggio . . . : Ricevuta eccezione Java nel richiamo del metodo Java (C G
D F).
Causa . . . . . : La procedura RPG XXM10X nel programma MOD_AMI/XXM10X ha
ricevuto un'eccezione Java "java.lang.NoSuchMethodError:
org/apache/poi/ss/usermodel/Sheet.SetAutoFilter(Ljava/lang/String;)V" nel
richiamo al metodo "SetAutoFilter" con firma "(Ljava.lang.String;)V" nella
classe "org.apache.poi.ss.usermodel.Sheet".
Correzione . . . : Rivolgersi al responsabile per l'assistenza del programma
per determinare la causa del problema.
Scelte possibili per la risposta al messaggio . . . . . . . . . . . . . . . :
D -- Per ottenere un dump formattato RPG.
S -- Ottenere un dump di sistema.

I created the prototype and ran it like this

dSSSheet_AutoFilter...
d PR Extproc(*JAVA
d :SHEET_CLASS
d :'SetAutoFilter')
d Interval like(Jstring)

frw = 1 ;
fcl = 0 ;
lrw = rowcount ;
lcl = 22;
Range = new_CellRangeAddress(frw:lrw:fcl:lcl) ;
SSSheet_AutoFilter(Sheet:Range) ;

Poi 3.6

Help Me please
jonboy49
Posts: 255
Joined: Wed Jul 28, 2021 8:18 pm

Re: Autofilter Java Error Help

Post by jonboy49 »

I don't see how it could work when you specify the cell address range as Interval like(Jstring). It has to refer to an object of class CellRangeAddress. You don't show your proto for CellRangeAddress.
DGR
Posts: 3
Joined: Tue Dec 09, 2025 5:39 pm

Re: Autofilter Java Error Help

Post by DGR »

Thanks for help
The problem is the prototype call parameter on AS400. I can't insert the launch of another prototype as a parameter for the previous one, so I don't know
how to do it, nor how to define the parameter to pass.
I copied a piece of the program from Scott's, but unfortunately I don't have a complete example (or rather, I couldn't find one).

This is Scott's prototype of the cell range address

D new_CellRangeAddress...
D PR like(CellRangeAddress)
D ExtProc(*JAVA
D : CELLRANGEADDRESS_CLASS
D : *CONSTRUCTOR)
D firstRow like(jint) value
D lastRow like(jint) value
D firstCol like(jint) value
D lastCol like(jint) value
Post Reply