Jump to content

Help! C# Plugin Error!

Recommended Posts

Hello, I am Lightning strike. I recently found an Error, I followed the code I got from BoltBait's tutorial, I recently understanded how C# works with Paint.net. I then made a plugin in Visual Studio Express Edition 2013, The Errors are as follows: "Error 1 The name 'LayerBlendModeUtil' does not exist in the current context" and also "Error 2 The name 'LayerBlendMode' does not exist in the current context", even though I know what they mean, I havn't an idea on how to fix this, could someone give me instructions or something tho help?

Edited by Lightning Strike

Many Thanks - Lightning strike:mouth:

Link to comment
Share on other sites

You must add a reference to PaintDotNet.Data.DLL in order to use the LayerBlendModeUtil class.


Plugin Pack | PSFilterPdn | Content Aware Fill | G'MICPaint Shop Pro Filetype | RAW Filetype | WebP Filetype

The small increase in performance you get coding in C++ over C# is hardly enough to offset the headache of coding in the C++ language. ~BoltBait


Link to comment
Share on other sites

The VS template probably referenced the older DLLs (from paint.net 3.5.11). You'll need to point the references to the new DLL's for paint.net 4.x.  Find these in the Solutions Explorer pane under References.  If you see small yellow warning triangles against the four PaintDotNet.* entries, you'll need to update the path to these references.


Right click on 'References' and select 'add Reference...'


In the window that appears,  select the 'Browse' tab and navigate to (Computer)  C:/Program Files/Paint.NET/


double-click on PaintDotNet.Base.dll


Repeat the process for the other three DLL's: PaintDotNet.Core.dll, PaintDotNet.Data.dll, PaintDotNet.Effect.dll


Link to comment
Share on other sites

  • 3 weeks later...

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Create New...