Use Markdig from PowerShell #180

Open
opened 2026-01-29 14:29:39 +00:00 by claunia · 0 comments
Owner

Originally created by @datenschieber on GitHub (Jan 18, 2018).

I am trying to use Markdig from PowerShell. Addtype .\Markdig.dll runs without problems. The type [Markdig.Markdown] is available afterwards.

The problem is that I am not able to create a Markdig object. New-Object Markdig.Markdown fails with error message New-Object : A constructor was not found. Cannot find an appropriate constructor for type Markdig.Markdown.

[Markdig.Markdown].GetConstructor() says Cannot find an overload for "GetConstructor" and the argument count: "0".. It seems that Markdig.Markdown doesn't provide usable constructors.

Please provide a hint or an example for how to use Markdig from PowerShell. At the end I want to develop a PowerShell module that encapsulates Markdig with appropriate PowerShell advanced functions.

Originally created by @datenschieber on GitHub (Jan 18, 2018). I am trying to use Markdig from PowerShell. `Addtype .\Markdig.dll` runs without problems. The type `[Markdig.Markdown]` is available afterwards. The problem is that I am not able to create a Markdig object. `New-Object Markdig.Markdown` fails with error message `New-Object : A constructor was not found. Cannot find an appropriate constructor for type Markdig.Markdown.` `[Markdig.Markdown].GetConstructor()` says `Cannot find an overload for "GetConstructor" and the argument count: "0".`. It seems that Markdig.Markdown doesn't provide usable constructors. Please provide a hint or an example for how to use Markdig from PowerShell. At the end I want to develop a PowerShell module that encapsulates Markdig with appropriate PowerShell advanced functions.
claunia added the question label 2026-01-29 14:29:39 +00:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/markdig#180