This is a migrated thread and some comments may be shown as answers.

How can i display left spaces in Fields

5 Answers 133 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
Saima Gul
Top achievements
Rank 1
Saima Gul asked on 18 Mar 2010, 08:24 PM
Hi
My data contain some spaces in fields . Actually i want to show rows with indentation. For example i have created a parent account and its child accounts. i want to show childs to be indented right by adding spaces in it so that it is clear for user to increase readability of report. data is ok in query result but when i try to view it in report all rows are left aligned omitting spaces which i have added in row data.
How can i get this? I want report shows data like this
Assets
Current Assets
Bank Accounts
UBL
Cash Accounts
Other Assets
Liability
Short Term

5 Answers, 1 is accepted

Sort by
0
Saima Gul
Top achievements
Rank 1
answered on 19 Mar 2010, 07:40 AM
I solved my problem by this method
Previously i was using blank space in my query like 
Select accountno,space(accountdepth)+accounttitle from acc
i replace it with this one

Select accountNo, replicate(' ',accountDepth)+accountTitle from acc

and my problem is solved in the sense that it looks ok on screen 
0
Saima Gul
Top achievements
Rank 1
answered on 29 Apr 2010, 09:44 AM
By using above mentioned technique it looks ok on screen
but if i try to print this report it shows   which i have added in my query. Is there any soln of this problem that it looks same on screen and in print too?
0
Kori
Top achievements
Rank 2
answered on 07 Dec 2010, 05:30 PM
I'm also having this issue. I can replace the spaces with &nbsp and it will make the report look okay, but if I go to export the report - it literally prints out the &nbsp's.

-- Kori
0
Kori
Top achievements
Rank 2
answered on 07 Dec 2010, 05:34 PM
Oops, just figured it out - wrap any mono-spaced section with <pre></pre> and it will view correctly in the report viewer and not print the html when you export it.

-- Kori
0
Saima Gul
Top achievements
Rank 1
answered on 28 Jan 2011, 06:15 AM
Hi Kori
I can not understand where to place <pre> tag as if i used it in expression it returns error 'An error has occured while processing Report '':
Incorrect syntax near '<'.' if i place it in query it still return this error
Can you plz explain how can i do that i shall be gratefull to you
Tags
General Discussions
Asked by
Saima Gul
Top achievements
Rank 1
Answers by
Saima Gul
Top achievements
Rank 1
Kori
Top achievements
Rank 2
Share this question
or