cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
The Discovery Summit 2025 Call for Content is open! Submit an abstract today to present at our premier analytics conference.
Get the free JMP Student Edition for qualified students and instructors at degree granting institutions.
Choose Language Hide Translation Bar
View Original Published Thread

Display Text at center of the Page in Journal

OneNorthJMP
Level V

How do i able to display Text at center of the page in Journal? 

 

Names Default To Here( 1 );
Clear Symbols();
Clear Log();
Close All( Data Tables, NoSave );
Close All( Journals, NoSave );

nw = New Window( "Reports",
	<<Journal,
	hlb = H List Box(
		lub = Lineup Box( N Col( 1 ) )
	)
);

lub << Append( tb = Text Box( "Updated on : " || Short Date( Today() ) ));
tb << Set Font Size( 50 ) << Set Font Style( "Bold" ) << Justify Text( "Center" );
tb << set width(1000) << set wrap(1000);

Reports = Current Journal();
Reports << Set page setup( margins( 0.1, 0.1, 0.1, 0.1 ), scale( 0.8 ), portrait( 0 ), paper size( "A4" ) );

Reports << get page setup();
Reports << SavePDF("DSA_report.pdf");

The layout that i intended like picture below. 

Inkedcenter page_LI.jpg

1 ACCEPTED SOLUTION

Accepted Solutions
tom_abramov
Level V


Re: Display Text at center of the Page in Journal

//With colors for better understanding
nw = New Window( "Reports",
	<<Journal,
	hlb = H List Box( Spacer Box(<<Color(red)), V List Box( Spacer Box(<<Color(blue)), hlb2 = H Center Box(), Spacer Box(<<Color(green)) ), Spacer Box(<<Color(yellow)) )
);

hlb2 << Append( tb = Text Box( "Updated on : " || Short Date( Today() ) ) );
tb << Set Font Size( 10 ) << Set Font Style( "Bold" );


//Without colors
nw = New Window( "Reports",
	<<Journal,
	hlb = H List Box( Spacer Box(), V List Box( Spacer Box(), hlb2 = H Center Box(), Spacer Box() ), Spacer Box() )
);

hlb2 << Append( tb = Text Box( "Updated on : " || Short Date( Today() ) ) );
tb << Set Font Size( 10 ) << Set Font Style( "Bold" );

View solution in original post

2 REPLIES 2
tom_abramov
Level V


Re: Display Text at center of the Page in Journal

//With colors for better understanding
nw = New Window( "Reports",
	<<Journal,
	hlb = H List Box( Spacer Box(<<Color(red)), V List Box( Spacer Box(<<Color(blue)), hlb2 = H Center Box(), Spacer Box(<<Color(green)) ), Spacer Box(<<Color(yellow)) )
);

hlb2 << Append( tb = Text Box( "Updated on : " || Short Date( Today() ) ) );
tb << Set Font Size( 10 ) << Set Font Style( "Bold" );


//Without colors
nw = New Window( "Reports",
	<<Journal,
	hlb = H List Box( Spacer Box(), V List Box( Spacer Box(), hlb2 = H Center Box(), Spacer Box() ), Spacer Box() )
);

hlb2 << Append( tb = Text Box( "Updated on : " || Short Date( Today() ) ) );
tb << Set Font Size( 10 ) << Set Font Style( "Bold" );
OneNorthJMP
Level V


Re: Display Text at center of the Page in Journal

So, we can make use of the spacer box and adjust it manually. I thought there are other way to do it. Thanks for input.