Friday, August 5, 2016

Tips and Tricks with SharePoint and the Chart web part

Add an Annotation

  1. Get to the chart's Advanced Settings.
  2. At left, in the Select an Element panel, click Annotations.  Above the settings panel, you'll see Annotation Menu.  The dropdown will be empty if you haven't configured an annotation yet.   The settings panel will also be empty, since there is no annotation to configure yet. Look to the right of this dropdown for the little "+" symbol.
  3. Click this "+" symbol.  This will create a new generic annotation.  It will appear above left of your chart, "Annotation1".  The Settings panel will also be refresh and now display a number of settings that you can configure.  You'll be working with the Anchor and Position groups of settings.
    Note on positioning: the coordinates here are always relative, from 0 - 100, starting from the top left corner of the chart. In other words, positive Y is down and positive X is to the right.
  4. Scroll down to the Position group.  Notice that the X and Y settings are both 0.  These coordinates are associated with the top left corner of the annotation box.  Change Y to be 50, and then click somewhere else.  The change is implemented immediately.  The annotation box has been moved down vertically to the center of the Y axis.
  5. Now adjust the X and Y settings as desired.  The next thing you can add is a pointer.  This pointer will start at the annotation box and reach to any point on the graph you want.  To configure pointer settings, you need to scroll back up to the Anchor group.
  6. In the AnchorX and AnchorY settings, enter the X and Y values of where you would like the pointer to stop.  It will start at the annotation box and end where you want it to end.  The start of the pointer will automatically adjust depending on whether the end value is to the right, left, above or below the annotation box.  Adjust the settings as desired.  The next value to adjust is the Text value, which is the actual text you want displayed in the annotation box.
  7. Scroll down to the Appearance group, and then a bit more until you see the Text setting.  It will appear just above the MapArea group.  By default, this setting will be "Annotation1" if this is the first annotation you are adding.  If your message is long, it will stretch out the annotation box.  You can adjust the width and height of this box, and text will automatically wrap as necessary.
  8. Scroll down to the Position group.  Edit the Height and Width settings as desired.  Lastly, you can adjust the way in which the text is presented in the annotation box - left,right justified, centered, etc.  By default, it will be centered.  Let's change this to left-justified.
  9. Scroll to the top, look for the Alignment settings, and change it to TopLeft.  At present, the annotation box has the pointer coming from the bottom middle.  I would like it to come from the right side.  To do this, I need to move the annotation to the left enough, and that requires further adjustment of the X and Y settings in the Position group.
  10. When you are done, click the Finish button at the bottom of the page.  At any time, to return to this annotation, get to the Advanced Settings dialog, select Annotations from the Select and Element panel, and then select the appropriate annotation from the dropdown.


No comments: