Questions tagged [.net-interactive]

.NET interactive is a group of CLI tools and APIs that enable users to create interactive experiences across the web, markdown, and notebooks.

13 questions
3
votes
1 answer

How to include project references in .NET Interactive Notebooks?

Using NET 6 I have the following project structure: nuget.config project.code-workspace - Core Core.csproj - Api Api.csproj - Sim notebook.ipynb Where notebook.ipynb is for now just: #i "nuget:https://api.nuget.org/v3/index.json" #r…
Miguel Moura
  • 36,732
  • 85
  • 259
  • 481
3
votes
1 answer

Cannot plot inline plotly charts in Jupyter Notebook using C#

Hello I am trying to plot a chart in Jupyter Notebook. I have been following this tutorial. I am using the following nuget packages to read a data and then plot it using plotly So I have this block of code which produces a scatter plot, var chart =…
Murtaza
  • 413
  • 1
  • 3
  • 13
2
votes
1 answer

vscode .net interactive notebooks to display latex

I have been looking for a way to display latex in vscode .Net interactive notebooks, but I've had no luck. on my C# .Net interactive Code Cell I have #r "nuget: AngouriMath.Interactive, 1.3.0" using AngouriMath.Interactive; using AngouriMath; Entity…
2
votes
1 answer

.NET Interactive - how to change collection output size

I'm using .NET Interactive notebook inside VS Code and want to change the number of printed out elements: var x = Enumerable.Range(0,21); x.Display(); Only first 20 element are shown in the the output: Can I somehow increase the size of output?
1
vote
1 answer

How do I allow for copying data to clipboard from .NET Interactive (Polyglot) Notebooks?

I am working in .NET Interactive (aka Polyglot) Notebooks in F# (but I believe the same would apply to C#). In my code, I am running functions that ultimately produce an F# list of floating point values, or alternatively might be an F# list of…
Eugene
  • 125
  • 1
  • 1
  • 8
1
vote
0 answers

Vscode .net interactive notebooks hide code when exporting to HTML

How do I hide the code cell when exporting .net interactive notebooks in visual studio code? For instance, I'd like to export the output, which is the latex display part of the example above, while excluding the actual code cell from being…
1
vote
1 answer

NET interactive notebook, cannot use System.Text.Json

I am evaluating NET interactive notebooks. I downloaded the VS code extension and created a dib notebook file. Following this example on how to include packages, I am getting a 401 unauthenticated response when trying to use System.Text.Json... Tbh,…
baouss
  • 1,312
  • 1
  • 22
  • 52
0
votes
0 answers

RazorInteractive in polyglot notebooks: "Error: System.ArgumentException: An item with the same key has already been added. Key: img"

I'm trying to output some HTML in a polyglot notebook using RazorInteractive. Here's the cell contents currently: #!razor

Hi

This errors with: Error: System.ArgumentException: An item with the same key has already been added. Key: img at…
Ian Newson
  • 7,679
  • 2
  • 47
  • 80
0
votes
0 answers

net interactive notebook - show list as single grid

This was working for me on a different computer. It used to display everything in a single grid but now each item is expandable. Formatter.Register(t => t ? @"

YES

" : @"
Derek
  • 7,615
  • 5
  • 33
  • 58
0
votes
1 answer

How to construct connect mssql command with variable in Polyglot Notebook

How to construct a magic connect command with variable? For example with a variable value as myserver. #!value --name sqlserver myserver #!share sqlserver --from value string sqlconnstr = $"Server={sqlserver}; Initial Catalog=mydb; Persist Security…
Travis
  • 111
  • 2
0
votes
0 answers

Hyperlinks in a code cell output in NET Interactive Notebooks

When using NET Interactive Notebooks, is there a way to make the links in the output of a code cell clickable? For example: var a = new [] {"https://www.stackoverflow.com", "https://example.com"}; a
tymtam
  • 31,798
  • 8
  • 86
  • 126
0
votes
1 answer

vscode interactive notebooks nuget directory error

I was trying to include a nuget package in my C# cell, like the example below: #r "nuget: PackageIWantToInclude" when suddenly, I got a similar error like this: Error: PackageManagement Error 3217 The source directory 'D:\MyLocalDirectory' not…
0
votes
3 answers

Issue with F# Plotly.NET chart descriptions

I'm trying to plot a line chart with a description, using the first method identified in https://plotly.net/00_2_display-options.html. While the code runs, and the chart is correctly plotted, I can't see the description. Here's the code block: let…
fython
  • 11
  • 2