Topic
  • 5 replies
  • Latest Post - ‏2014-08-26T17:48:33Z by OpherB
Sundet
Sundet
8 Posts

Pinned topic Cognos Functions Used with Javascript and Object Model

‏2014-08-25T14:16:40Z |

I've been searching for a list of Cognos functions that are used with via Javascript.  I have only found GetRV().  Is there a complete list of functions?  Where can I find the object model for Cognos?

  • OpherB
    OpherB
    807 Posts

    Re: Cognos Functions Used with Javascript and Object Model

    ‏2014-08-25T19:43:18Z  

    The Cognos model is not browser-centric, so Javascript, which is a browser-embedded technology, will not work.

    If you want to write any code into the Cognos environment, you'll have to buy the SDK and code in Visual Basic or a variant of C which is supported.

    More details can be found here: http://www.ibm.com/developerworks/data/library/cognos/development/how_to/page565.html

    Good luck,
    Opher

     

  • Sundet
    Sundet
    8 Posts

    Re: Cognos Functions Used with Javascript and Object Model

    ‏2014-08-25T20:12:38Z  
    • OpherB
    • ‏2014-08-25T19:43:18Z

    The Cognos model is not browser-centric, so Javascript, which is a browser-embedded technology, will not work.

    If you want to write any code into the Cognos environment, you'll have to buy the SDK and code in Visual Basic or a variant of C which is supported.

    More details can be found here: http://www.ibm.com/developerworks/data/library/cognos/development/how_to/page565.html

    Good luck,
    Opher

     

    Hello Opher,

    Thanks for responding.  I created an HTML item and use "<input type='Button' value="Export"  onclick="javascript:gCognosViewer.getRV().viewReport('spreadsheetML')">" to create a button.  The result of pushing the button will be an Excel spreadsheet.  I'm pretty certain that getRV() is a Cognos function.  Am I wrong?  If so, where can I find other functions like getRV()?

  • OpherB
    OpherB
    807 Posts

    Re: Cognos Functions Used with Javascript and Object Model

    ‏2014-08-25T22:30:57Z  
    • Sundet
    • ‏2014-08-25T20:12:38Z

    Hello Opher,

    Thanks for responding.  I created an HTML item and use "<input type='Button' value="Export"  onclick="javascript:gCognosViewer.getRV().viewReport('spreadsheetML')">" to create a button.  The result of pushing the button will be an Excel spreadsheet.  I'm pretty certain that getRV() is a Cognos function.  Am I wrong?  If so, where can I find other functions like getRV()?

    Ah. I thought you wanted to do things "inside" the report, like selecting chart objects and editing labels.

    Check out Appendix H of the Report Studio User Guide.

    This document may help, too: http://public.dhe.ibm.com/software/dw/dm/cognos/upgrade_and_migration/bi/upgrading_javascript_applications.pdf

    Regards,
    Opher

     

  • Sundet
    Sundet
    8 Posts

    Re: Cognos Functions Used with Javascript and Object Model

    ‏2014-08-26T13:24:10Z  
    • OpherB
    • ‏2014-08-25T22:30:57Z

    Ah. I thought you wanted to do things "inside" the report, like selecting chart objects and editing labels.

    Check out Appendix H of the Report Studio User Guide.

    This document may help, too: http://public.dhe.ibm.com/software/dw/dm/cognos/upgrade_and_migration/bi/upgrading_javascript_applications.pdf

    Regards,
    Opher

     

    I'm using Cognos Report Studio 10.1.1.  I want to do as much as I can.  Appendix H of the user guide for Cognos 10.2 mentions some functions.  Are they compatible with Report Studio 10.1.1?  I couldn't find any of the functions in: http://public.dhe.ibm.com/software/data/cognos/documentation/docs/en/10.1.1/ug_cr_rptstd.pdf.  In addition, I couldn't find the function GetRV() in the documentation for Report Studio 10.2 or an explanation of the object model.  I know that I am not prohibited from using GetRV() becuase I have used it.  Do you know of any other resources?

  • OpherB
    OpherB
    807 Posts

    Re: Cognos Functions Used with Javascript and Object Model

    ‏2014-08-26T17:48:33Z  
    • Sundet
    • ‏2014-08-26T13:24:10Z

    I'm using Cognos Report Studio 10.1.1.  I want to do as much as I can.  Appendix H of the user guide for Cognos 10.2 mentions some functions.  Are they compatible with Report Studio 10.1.1?  I couldn't find any of the functions in: http://public.dhe.ibm.com/software/data/cognos/documentation/docs/en/10.1.1/ug_cr_rptstd.pdf.  In addition, I couldn't find the function GetRV() in the documentation for Report Studio 10.2 or an explanation of the object model.  I know that I am not prohibited from using GetRV() becuase I have used it.  Do you know of any other resources?

    This is the main page for BI Proven Practices: http://www.ibm.com/developerworks/analytics/bi.html#bapp

    You can use this as a starting point to search for documents that step through how to do various things.

    From that page I selected "Reporting" and then "Scripting" and got these results: http://www.ibm.com/developerworks/views/analytics/libraryview.jsp?sort_by=Title&sort_order=1&show_abstract=true&show_all=false&search_flag=true&product_by=Cognos&topic_by=All%20Topics&type_by=All%20Types&search_by=cognosppreportingscriptingtechniques&Submit.x=0&Submit.y=0

    You may find useful information there.

    Good luck,
    Opher