Custom Data Visualizers

I have seen the Custom Data Visualizers and I attempted to create one but I found the sample to be extremely lacking (or perhaps I am thinking lightyears ahead of the plans of the VS.NEt team again)

A sample of what I wanted to do was I wanted to be able to build into vs.net such that the data visualizer for something like a hashtable. would have an extra row. And when this row was expanded it would display 2 columns. Column 1 would show all of the keys and column 2 would show each object associated with the key. A more advanced sample would allow one to expand the object used as a key or the object used as the value. (I somehow get the feeling this latter item may be nearly impossible).

Another thing I would like to do would be to add a treeview to represent certain data.

Am I aiming at something that is easily feasible in VS 2k5 - and if so what would be a good place to start reading up on how to do something like this.



Answer this question

Custom Data Visualizers

  • Dan1

  • Kakurady


    [assembly: DebuggerVisualizer(
        typeof(Bitmap),
        Target = typeof(Bitmap),
        Description = "birmapVisualizer")]

     


    I think like this ;)


  • therock

    My question was about Existing Data types not about new data types. 
  • deepakleo2003

    Will have to take a look at it and see howe well that works but that seems to be the same thing that I am trying to do.
    It looks like
            Target = typeof(Bitmap), Description = "Image Viewer")]
    was the key information I was missing.

  • Scoper

    If u want to use custom dictionary class or your custom hashtable...

    u have to implement the ISerializable interface... and

    a constructor in your class with info and context parametters...

    and a method as GetObjectData(info,context)

    I have done my visualizer for my custom classes..

    u can use any control in your visualizer...
    for example an image control to show the byte[]


  • Custom Data Visualizers