Click here to see the SAS code.
Click here to see the example.


The drilldown in this example is *not* done in the traditional sas way,
and this technique only works with the dev=activex and dev=java 
SAS graphs that are rendered on the "client side" (ie, drawn on the 
fly, in the user's web browser).

In this technique, in your ODS statement you tell it "Drilldownmode"="Script"
and tell it the name of your javascript function -- for dev=activex, you
also need a few more parameters than you did with dev=java ...

 ODS HTML file=odsout

And then you script out your "javascript" code at the bottom of your 
sas job using sas 'put' statements.  Note that it's very easy to 
get confused because the put statement needs it's set of quotes and
semicolon, and the javascript might also have quotes and semicolons.
Here is the java script at the bottom of my sas job ...

   ods html close;
   ods listing;
   data _null_ ;
   file odsout mod; 
   put ' ' ;
   *** you will have to look in my actual sas job to see this code...
   run ;

Similar to using a Drillpattern, the only variables from your data
that you can use to construct your drilldown strings are ones that
you are actually using in the graph or maps (in plots & charts, that's 
basically category, response, and group variables - in maps that's id 
and response variables).

Back to Samples Index