GeekInterview.com
  I am new, Sign me up!
 
GeekInterview.com  >  Interview Questions  >  Data Warehousing  >  Cognos
Go To First  |  Previous Question  |  Next Question 
 Cognos  |  Question 136 of 180    Print  
what is the difference between the render variable and the style variable?

  
Total Answers and Comments: 3 Last Update: March 17, 2009     Asked by: sathyajagadeesh 
  
 Sponsored Links

 
 Best Rated Answer

No best answer available. Please pick the good answer available or submit your answer.
January 29, 2008 01:59:19   #1  
sivakumar.bora Member Since: August 2007   Contribution: 7    

RE: what is the difference between the render variable and the style variable?
Render Variable: - Specify a variable based on which object can be conditionally rendered.

Style Variable: - Specify a variable based on which object can be

conditionally styled.


 
Is this answer useful? Yes | No
January 29, 2008 01:59:43   #2  
sivakumar.bora Member Since: August 2007   Contribution: 7    

RE: what is the difference between the render variable and the style variable?
Render Variable: - Specify a variable based on which object can be conditionally rendered.

Style Variable: - Specify a variable based on which object can be

conditionally styled.


 
Is this answer useful? Yes | No
March 17, 2009 06:24:48   #3  
cognosvij Member Since: March 2009   Contribution: 1    

RE: what is the difference between the render variable and the style variable?


Render Variable: - Specify a variable based on which object can be conditionally rendered.


Style Variable: - Specify a variable based on which object can be conditionally styled.

Example for Style Variable

In a report in a list if u want to display every alternate row with particular color
in this case
1) create a data item with name running-count with function "running-count" on particular unique column
2) now create one more data item as mod with functon "mod" on that running-count data item
3)create a boolean varibale with expression mod 1
4)go to the page select List column Body style
5)In properties pane select Style Variable as boolean variable
6)click on YES variable and set its Foreground color as RED
7)click on No variable and set its Foreground color as Yellow
now run the report



Example for Render Variable

if the case is like you want to see the particular page in HTML or PDF or CSV format then
1)Create 3 pages in your report
2)every page conatins some specific data
3)name these pages as HTML PDF CSV
4)create a String vaiable with 3 values as HTML PDF and CSV
5)now in string variable put expression as .....
case

when ReportOutput() 'HTML' then 'HTML'
when ReportOutput() 'PDF' then 'PDF'
when ReportOutput() 'CSV' then 'CSV'
end

6)now go the page named HTML and select page object
7)in properties pane click on Render Variable select that string variable
8)check only HTML check box value for HTML page
9)repeat step No. 6 to step No.8 for remaining 2 pages.

now run the report :-)


hope it will answer your question .


regards
vij



 
Is this answer useful? Yes | No


 
Go To Top


 Sponsored Links

 
About Us -  Privacy Policy -  Terms and Conditions -  Contact -  Ask Question -  Propose Category -  Site Updates 

Copyright © 2005 - 2009 GeekInterview.com. All Rights Reserved

Page copy protected against web site content infringement by Copyscape