Login
Enter your username and password to login. If you do not have a username you can register one.

Username: 
Password: 
Remember Me



Forgotten Password?

Online
1 member and 14 guests have been online with in the last 10 minutes.

Hot Topic
No posts have caught fire as of yet.

JD Edwards® Enterprise One / One World Discussions >> JD Edwards® EnterpriseOne Developers

Pages: 1
Axel
member


Reged: 12/06/00
Last on: 10/10/01
Posts: 7
Get Max Grid Rows
      #22452 - 10/10/01 12:34 AM

Hi List,

i have a problem with the system function "Get Max Grid Rows".
i use this function to loop through all lines in a grid and set a default value in a row for each line. this seems to work fine as long as i do not have more lines in the grid as they could be seen on the screen.
for example: the grid contains 25 lines. if i have a screen resolution 1024x768 i can see aprox. 20 lines and the "GetMaxGridRows" returns 25 but if i change now the res to 800x600 the systemfunction returns for the same grid only 15.
if i go to the bottom of the grid, the grid fetches all lines and after that the value is again 25.
any ideas how to solve this problem

thanks
Axel

XE on AS400 SP16, CO on AS400, Citrix Clients



Post Extras: Print Post   Remind Me!   Notify Moderator  
tpw_nz
member


Reged: 01/17/01
Last on: 04/18/14
Posts: 61
Loc: New Zealand
Re: Get Max Grid Rows
new [Re: Axel]       #22456 - 10/10/01 04:19 AM

Axel,

Try turning on the grid option "Disable Page at a time Processing".

By default when a grid loads it loads the number of rows that can be displayed plus a few more. This is to prevent long grid loading times when there is a lot of data.

Disabling page at a time processing means the grid will load will rows, possibly delaying displaying the screen because of the amount of data that needs to be loaded.

XE - SP15.1 - Update 2
Oracle 8.1.6
Sun Solaris 8

--------------------
Various release/OS/DB


Post Extras: Print Post   Remind Me!   Notify Moderator  
Axel
member


Reged: 12/06/00
Last on: 10/10/01
Posts: 7
Re: Get Max Grid Rows
new [Re: tpw_nz]       #22457 - 10/10/01 04:30 AM

Thanks,

that's it....you solved my problem ;-)

Axel

XE on AS400 SP16, CO on AS400, Citrix Clients



Post Extras: Print Post   Remind Me!   Notify Moderator  
Zoltan_Gyimesi
member


Reged: 10/27/00
Last on: 03/21/14
Posts: 4256
Loc: Budapest, Hungary
Re: Get Max Grid Rows
new [Re: Axel]       #22476 - 10/10/01 12:28 PM

Hi Axel,

Trevor's hint is right but if you have a lot of records then disabling the "Page at a Time" processing has performance disadvantage as well for the user who runs the application as well for concurrent users and running UBEs.

If your logic enables, you can place your default setting into the Write Grid Line-Before event (Form Event)instead of disabling the "Page at a Time" processing. In this case you do not have to construct a while loop using Get Max Grid Row and Get Grid Row system functions, further you can spare the two row counter variables also, so this is simpler solution and hasn't performance disadvantage.

If you are not sure, that this solution can work for you then please let us know more about your current situation, e.g.:

1.) What is the type of your Form?
2.) What kind of information required to generate default value? E.g. is all information available when a record fetched from the DB?
3.) Do you want to re-run your logic after the grid has been populated? E.g. when something changed on the header part of the form?
4.) Do you want to set default value for all record or just which appear in the grid?

Please, let us know could it work for you or not. Thanks.

Regards,
Zoltán


B7332 SP11, ESU 4116422, Intel NT4, SQL 7 SP1
(working with B7321, B7331, XE too)

--------------------
- XE UPDATE 2 SP22, Intel NT4, SQL 2000
- B9 (8.93B1)
- was/is working with B7321, B7331, B7332 too


Post Extras: Print Post   Remind Me!   Notify Moderator  
teddym
member


Reged: 11/19/01
Last on: 11/28/06
Posts: 11
Loc: Canada
Re: Get Max Grid Rows
new [Re: Zoltan_Gyimesi]       #26519 - 01/14/02 11:40 AM

Hi Zoltan, (re:(post#22476/re:22452))

I realize that this reply is from a long time post but I just came across the same problem and I was wondering if you could explain further the alternative to disabling the "Page-at-a-time" option. I am trying to create an app similiar to "P0911Z1" but want to display the number and total amount records that have been retrieved. I have tried disabling the page-at-a-time option and you are right when you wrote that that could affect performance. This is just a test app that I am trying to create so no rush on this one. Oh yeah, this is my first post to the list.

Thanks,
Ted





Post Extras: Print Post   Remind Me!   Notify Moderator  
Zoltan_Gyimesi
member


Reged: 10/27/00
Last on: 03/21/14
Posts: 4256
Loc: Budapest, Hungary
Re: Get Max Grid Rows
new [Re: teddym]       #26590 - 01/15/02 10:17 AM

Hi Ted,

First, welcome to the JDEList Forums!

I hope, you won't forget to attach your system configuration informations nex times to your posts.

I checked P0911Z1 on our XE and it has 3 forms. I am not sure want you want to do exeactly. I suppose you do not want to insert all rows from the Business View and want to insert Total rows, am I right?

Let's see:

1.) You can issue a SuppressGridLine system function call (Grid category) in the GridRecord in the GridRecordIsfetched form event when you do not want the record to be inserted into the grid. Of course, you can accumulate its values to your totals.

2.) If you have only one level totaling then accumulate your total in the grid buffer (GB prefixed elements in the ER). You can use the ClearGridBuffer and and InsertGridBufferRow system function (both are in Grid category). With the first you can initialize the totals, with the second you can insert it into the grid at the right place.

3.) If you have more level of totaling then you can create ER variables (the best to choose Form scope for later flexibility of coding) to store the totals on the different levels. When you encounters a point when you have to insert the total then move the valuse from the variables to the GridBuffer and InsertGridBufferRow.

An other solution can be to use a "dummy" business view and suppress all automatical fetches: use SuppressFind system function (General category) and set the Options appropriatly on the Properties window of he Form. Code your own logic to fetch the records and populating the grid in the ButtonClicked event of the Find button. If you want an automatical Find on entry then you can issue a PressButton(HC Find) in the PostDialogIsInitialized event.

An other hint is that you can set different font and colour for your total rows (e.g. including diffent for each level too).

Coding totaling, mainly multi level totaling has several tricks and traps. Here are some for you:

1.) Creating a logic to detect the first level breaks.
2.) How to detect level breaks.
3.) Higher level breaks have to trigger all lower level breaks starting from the lowest.
4.) Managing the totals after the last row has been fetched.
5.) Minimizing the code placing the different level of break logic into the ButtonPressed event of different hidden buttons simulating something "subroutine" and each level triggers only the immediattely lowest level.
6.) Disableing the QBE lines to disable for the users to change the sequence on the grid which generally cause malfunction of the logic (level breaks are tightly tied to a supposed sequence of the records).
7.) etc.

Hope, could be a bit of help for you.

Good luck,

Zoltán

P.S.: What kind of form do you have to use? Do you want Update/Delete/Add capabilities (or some of them) on your form?

B7332 SP11, ESU 4116422, Intel NT4, SQL 7 SP1
(working with B7321, B7331, XE too)

--------------------
- XE UPDATE 2 SP22, Intel NT4, SQL 2000
- B9 (8.93B1)
- was/is working with B7321, B7331, B7332 too


Post Extras: Print Post   Remind Me!   Notify Moderator  
teddym
member


Reged: 11/19/01
Last on: 11/28/06
Posts: 11
Loc: Canada
Re: Get Max Grid Rows
new [Re: Zoltan_Gyimesi]       #26668 - 01/16/02 07:18 AM

Hi Zoltán,

Thanks for the reply, haven't tried it yet though. I'll keep you posted.

Ted
JDE OneWorld B733, SP16.1



Post Extras: Print Post   Remind Me!   Notify Moderator  
Pages: 1


Extra information
0 registered and 41 anonymous users are browsing this forum.

Moderator:  Sef, ekempter, Christian Audet, jdecnc 

Print Thread

Forum Permissions
      You cannot start new topics
      You cannot reply to topics
      HTML is disabled
      UBBCode is enabled

Rating:
Thread views: 1979

Rate this thread

Jump to

JDELIST Support | Privacy statement JDELIST.com

*
UBB.threads™ 6.4.1

 .: IIP 5.4.5 by David Lozier ©2003 :. 
Distributed by ThreadsDev.com

The legal restrictions and terms of use applicable to this site are available here.
Use of this site signifies your agreement to the terms of use.
JDELIST is NOT affiliated with JD Edwards® & Company, Oracle or Peoplesoft. Contents of this site are neither
endorsed nor approved by JD Edwards® & Company, Oracle or Peoplesoft.

This page best viewed with Netscape 4 or Microsoft Explorer 4 or above in 800 x 600 resolution.