Create DOT/GraphViz diagram using C# / .Net
vargraph=newDotGraph("MyGraph");vardirectedGraph=newDotGraph("MyDirectedGraph",true);varmyNode=newDotNode("MyNode"){// Set all available propertiesShape=DotNodeShape.Ellipse,Label="My node !",FillColor=DotColor.Lightgrey,FontColor=DotColor.Black,Style=DotNodeStyle.Default,Height=0.5f};// Add the node to the graphgraph.Add(myNode);// Create an arrow with node namesvarmyArrow=newDotArrow("myNode1","myNode2");// Create an arrow with node objectsvarmyArrow=newDotArrow(myNode1,myNode2){// Set all available propertiesArrowHeadShape=DotArrowShape.Normal;};// Add the arrow to the graphgraph.Add(myArrow);// Indented versionvardot=graph.Compile(false);// Minified versionvardot=graph.Compile();// Save it to a fileFile.WriteAllText("myFile.dot",dot);