@@ -383,25 +383,25 @@ module ChartExtensions =
383383
384384
385385 /// Show chart in browser
386- static member ShowWithDescription ( d : string ) ( ch : GenericChart ) =
386+ static member ShowWithDescription ( show : bool ) ( d : string ) ( ch : GenericChart ) =
387387 let guid = Guid.NewGuid() .ToString()
388388 let html = GenericChart.toEmbeddedHtmlWithDescription d ch
389389 let tempPath = Path.GetTempPath()
390390 let file = sprintf " %s .html" guid
391391 let path = Path.Combine( tempPath, file)
392392 File.WriteAllText( path, html)
393- System.Diagnostics.Process.Start( path) |> ignore
393+ if show then System.Diagnostics.Process.Start( path) |> ignore
394394
395395
396396 /// Saves chart in a specified file name and shows it in the browser. The caller is responsible for full path / filename / extension.
397- static member ShowFileWithDescription ( fullFileName : string ) ( d : string ) ( ch : GenericChart ) =
397+ static member ShowFileWithDescription ( show : bool ) ( fullFileName : string ) ( d : string ) ( ch : GenericChart ) =
398398 let html = GenericChart.toEmbeddedHtmlWithDescription d ch
399399 File.WriteAllText( fullFileName, html)
400- System.Diagnostics.Process.Start( fullFileName) |> ignore
400+ if show then System.Diagnostics.Process.Start( fullFileName) |> ignore
401401
402402
403403 /// Show chart in browser
404- static member Show ( ch : GenericChart ) = Chart.ShowWithDescription " " ch
404+ static member Show ( ch : GenericChart ) = Chart.ShowWithDescription true " " ch
405405
406406
407407 /// Show chart in browser
0 commit comments