Jump to content

Recommended Posts

Posted
Which perameter do I need to set to remove the 0 NUMBER OF RECORDS IN TABLE text a user would see when running a procedure that generates no output I still want users to see the -TYPE text as I want them to know when the procedure finishes.
Posted

Hi Leif

Welcome to myibi. It is a great forum to get answers to your development questions

SET EMPTYREPORT = ON should solve your problem. You can add this line of code to the server profile so you dont have to put it in each fex

Posted

Maybe you want SET MESSAGE. For example, this code:

SET MESSAGE = OFF

 

TABLE FILE ggsales

PRINT UNITS BY SEQ_NO

WHERE SEQ_NO EQ 0

END

-RUN

 

-TYPE ----------------------------------------

-TYPE | |

-TYPE | Report complete, no data to display. |

-TYPE | |

-TYPE ----------------------------------------

 

Produces the output:

Posted

Perhaps even better, you can use HTMLFORM.

TABLE FILE ggsales

PRINT UNITS BY SEQ_NO

WHERE SEQ_NO EQ 0

END

-RUN

-IF &RECORDS GT 0 THEN GOTO ReportDisplays;

 

-HTMLFORM BEGIN

<!DOCTYPE html>

<html>

<head>

<style>

.container { height: 200px;

position: relative;

border: 3px solid green;

}

.center { margin: 0;

position: absolute;

top: 50%;

left: 50%;

transform: translate(-50%, -50%);

}

</style>

</head>

<body>

<div class="container">

<div class="center">

<p>Report complete. No output to show.</p>

</div>

</div>

</body>

</html>

-HTMLFORM END

 

-ReportDisplays

 

This would show:

 

image.png805329 4.7 KB

 

Or really, with HTML, most anything you could think of.

Posted

david.beagan:

 

-HTMLFORM BEGIN .container { height: 200px; position: relative; border: 3px solid green; } .center { margin: 0; position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); }

Report complete. No output to show. -HTMLFORM END

 

 

I went with your solution as we are running the procedure in a portal and having the nicely formatted output was exactly what I should have been doing from the start.

Thank you

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
  • Create New...