× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



Enums are just classes, so define the enum like this:

dcl-c HorizontalAlignment_ENUM
org.apache.poi.ss.usermodel.HorizontalAllignment;
dcl-s HorizontalAlignment Object(*JAVA:
HorizontalAlignment_ENUM);

Then you probably want to be able to retrieve an enum by the name, so you
also need to define a valueOf method like this:

dcl-pr HorizontalAllignment_valueOf
Like(HorizontalAlignment)
ExtProc(*JAVA: HorizontalAlignment_ENUM: 'valueOf')
Static;
value Like(jString) const;
end-pr;

And finally you can define the setAlignment method like this:

dcl-pr HSSFCellStyle_setAlignment
ExtProc(*JAVA: HSSFCellStyle_CLASS: 'setAlignment');
horizAlign Like(HorizontalAlignment) const;
end-pr;

On Mon, Nov 6, 2017 at 6:07 PM, Don Brown <DBrown@xxxxxxxxxx> wrote:

I suggest you go to version 3.14 of POI.

We recently updated t this version which added a number of functions we
required, particularly the streaming option for very large excel files and
does not have the new enum options.

Alternatively if you sort out all the java method calls using enum's I am
sure quite a few people on this list would look to use it.

Cheers


Don Brown





From: RWillis@xxxxxxxxxxxxxxxxxxxxxxxx
To: rpg400-l@xxxxxxxxxxxx
Date: 07/11/2017 07:35 AM
Subject: Newsletter / Marketing: xssf cellstype setAlignment
Sent by: "RPG400-L" <rpg400-l-bounces@xxxxxxxxxxxx>



Can anyone suggest how I can change the prototype and call to
ssCellStyle_setAlignment in Scott's HSSFR4 service program to work with
POI HSSF version 3.17? Seems the parm has changed from a short data type
to an enum. I can't figure out how to define the prototype to get the call

to work.

I've been successfully using POI HSSF version 3.6, but now trying to
convert to release 3.17.

In version 3.6 the setAlignment definition was;
void setAlignment(short align)

In version 3.17;
void setAlignment(HorizontalAlignment align)

This is in class org.apache.poi.ss.usermodel.CellStyle.
The prototype as defined in HSSF_H for version 3.6 is;
D HSSFCellStyle_setAlignment...
D PR EXTPROC(*JAVA
D : HSSF_CELLSTYLE_CLASS
D : 'setAlignment')
D align like(jshort) value

I've tried various data types and keep getting a compile error;

The type of parameter 2 specified for the call does not match the
prototype.

______________________________________________________________________
This e-mail and any files transmitted with it may be privileged and
confidential and intended solely for the use of the individual or
entity to which it is addressed. If the reader of this message is
not the intended recipient, or an employee or agent responsible for
delivering this message to the intended recipient, you are hereby
notified that any dissemination, distribution or copying of this
communication is strictly prohibited. If you have received this
e-mail in error, please notify the sender immediately by replying
to this e-mail and deleting it from your computer.
______________________________________________________________________
--
This is the RPG programming on the IBM i (AS/400 and iSeries) (RPG400-L)
mailing list
To post a message email: RPG400-L@xxxxxxxxxxxx
To subscribe, unsubscribe, or change list options,
visit: https://lists.midrange.com/mailman/listinfo/rpg400-l
or email: RPG400-L-request@xxxxxxxxxxxx
Before posting, please take a moment to review the archives
at https://archive.midrange.com/rpg400-l.

Please contact support@xxxxxxxxxxxx for any subscription related
questions.

Help support midrange.com by shopping at amazon.com with our affiliate
link: http://amzn.to/2dEadiD

______________________________________________________________________
This email has been scanned by the Symantec Email Security.cloud service.
For more information please visit http://www.symanteccloud.com
______________________________________________________________________


--
This is the RPG programming on the IBM i (AS/400 and iSeries) (RPG400-L)
mailing list
To post a message email: RPG400-L@xxxxxxxxxxxx
To subscribe, unsubscribe, or change list options,
visit: https://lists.midrange.com/mailman/listinfo/rpg400-l
or email: RPG400-L-request@xxxxxxxxxxxx
Before posting, please take a moment to review the archives
at https://archive.midrange.com/rpg400-l.

Please contact support@xxxxxxxxxxxx for any subscription related
questions.

Help support midrange.com by shopping at amazon.com with our affiliate
link: http://amzn.to/2dEadiD


As an Amazon Associate we earn from qualifying purchases.

This thread ...

Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.