Recent

Author Topic: Problem creating variable to display page count  (Read 308 times)

joceravolo

  • Newbie
  • Posts: 3
Problem creating variable to display page count
« on: September 13, 2019, 11:17:48 pm »
Hi Guys,

I am new to this and I am using Codetyphon 6.8.
I want to create a variable to display the page count in this format:
Page X
I created a variable with this expression 'Page ' + inttostr(PageNo)
That gives me an error that it expects string but is getting boolean.
I can't find samples for the reports. That would help.

Thanks in advance,

Joe.

Handoko

  • Hero Member
  • *****
  • Posts: 3188
  • My goal: build my own game engine using Lazarus
Re: Problem creating variable to display page count
« Reply #1 on: September 14, 2019, 06:44:15 am »
Hello joceravolo,
Welcome to the forum.

You don't need to create a variable for it. Double click on the frReport component and do these:

1. Click the insert rectangle object (on the left toolbar) and click on the location you want to put it
2. Put this:
Page [PAGE#] in the text editor
3. Click the OK button to close the editor


Note:
This Lazarus/FPC forum, not CodeTyphon.
« Last Edit: September 14, 2019, 06:47:21 am by Handoko »

joceravolo

  • Newbie
  • Posts: 3
Re: Problem creating variable to display page count
« Reply #2 on: October 28, 2019, 08:34:08 pm »
Thanks Handoko.
But on Dephi I use variables extensively.
Not only for page number, most of the times I use variable made from the database fields to accomplish different things.

GAN

  • Full Member
  • ***
  • Posts: 230
Re: Problem creating variable to display page count
« Reply #3 on: October 29, 2019, 06:23:21 am »
Lazarus 1.8.4 FPC 3.0.4 Linux Mint Mate 17.2 x86_64 GTK-2
Zeos 7.1.3 - Sqlite 3.8.2

Foro Lazarus en español http://forum.lazarus.freepascal.org/index.php/board,73.0.html