cancel
Showing results for 
Search instead for 
Did you mean: 

Runtime set Width of crystal formula or text object

Former Member
0 Kudos

Hi ,

I am trying to set runtime width of the Textobject or formula but it does not work

Take blank Report

in detail section put one Textobject. insert very long text which expand more than one page. set Textobject can grow

Now set its width ZERO.

now i want width of the Textobject on first page is different and rest of the page different

so i put following formula on its size and position's width

if PageNumber = 1 then 7200 else 11520

but it does not work

it shows same width in all the page means 7200 in all the page

while i want on first page 7200 and rest of the page 11520

Any idea..

Thanks

Kalpesh

Accepted Solutions (0)

Answers (1)

Answers (1)

Former Member
0 Kudos

If you read the online help for Size and Position | Width

it states: "Use the Width box to change an object's horizontal width. You can create a conditional formula in the Formula Workshop to adjust width. Do this when you want an object to have a different width BASED ON ITS VALUE.

The type of units (inches or centimeters) you enter in these boxes is determined by your operating system settings."

So it seems that "its value" does not mean being dependant upon a page number value.

Former Member
0 Kudos

Hi,

i got what you said but if i want to change that width box value runtime depends on page then how can i change ?

on first page i want to compress my text and other page i dont

How can i do that ?

That widthbox has formula button over there thats actuall WidthAdujustment its not Actual width.

Means whaterver value you pass runtime to that formula its adding that formula value + Box Value

Means design time BoxValue is 1 inch and i want width runtime 2 inch and i pass value as 2 inch so final output should be 2 inch only but its 3 inch (1 inch box value + 2 inch formula value)

My Requirement is to make text box 2 inch on first page and rest of all the page 5 inch how can i do that ?

Kalpesh

Former Member
0 Kudos

In that case, put the 2" and 5" boxes on the first page,

hide the 2" from page 2 on

Make the 5" invisible on the first page.

Starting with page 2, make the 5" visible.

The Panda

Former Member
0 Kudos

Its good idea but not working.

Because in my text box there is long comment so second page comment should start at then end of the first page.

in this case it will not work.

your second page will start from the beginning

but i am so suprise you can set the X position like

if you want X position on first page different and rest of the page different at run time that works fine but not width

Thanks

Kalpesh

Former Member
0 Kudos

Try putting the same field (text object) into two different sections with each having a different width.

Then conditionally suppress one section or the other based on which width you want.

Former Member
0 Kudos

It works OK but as i mentioned in my previous comment

First page show comment in 2" and second show in 5" but

Second page should start from the first page's end but its start from the begining

Thanks

kalpesh