Symantec Developer Group

 View Only
  • 1.  How do you run a report with custom parameters in NS7 using the ASDK

    Posted Oct 13, 2010 06:54 PM

    In NS6 it was possible to run most reports using the ASDK even when the report had custom parameters e.g.

    <MyReportGuid>, "DeviceName=MyServer,Domain=symantec.com".

    However in NS7 it appears next to impossible to achieve this. The ReportManagementService web service still has the same call "RunReportWithParameters", but it appears to require a different syntax to allow it to accept the custom parameters specified.



  • 2.  RE: How do you run a report with custom parameters in NS7 using the ASDK
    Best Answer

    Posted Oct 18, 2010 03:08 PM

    The format hasn't changed between NS 6 and NS 7. The second argument to RunReportWithParameters is a string that uses name value pairs. To use the custom parameters you must know what those parameters are and put those in the name value pair separated with commas:

    "param1=value, param2=value2, param3=value3"

    Like the following:

    parameterString = "From=2008-10-02T00:00:00, Name=%, Result Type=0, To=2008-10-15T00:00:00"

    The names can be either the parameter or the parameter description. The same will apply with any report, it just requires knowledge of the reports parameters so they can be properly passed.

    However, I believe there may have been a bug with this in earlier 7.0 versions of the ASDK which have only recently been corrected. I am attempting to verify this at this time. I will repost when I have verified.
     



  • 3.  RE: How do you run a report with custom parameters in NS7 using the ASDK

    Posted Oct 18, 2010 03:50 PM

    OK, I just verified that passing in parameters to a report does work as expected. So I need some additional information from you.

    - What version of the ASDK are you using? As I mentioned, there were some problems with passing parameters that appears to be fixed.

    - What version of the SMP are you using? Probably less of an issue but we need to make sure that the correct assemblies are in place.

    - Is the report you're using one of ours or is it your own custom report?

    - If the report is your own, can your reproduce your difficulty on one of our reports? If so, can you send me the parameter string you are using?