Giter Site home page Giter Site logo

Comments (4)

mikhail-barg avatar mikhail-barg commented on June 22, 2024 1

Just one thing, the program does not write into the existing RichTextBox but creates a new one.
I read it can be related to the declaration of the logger but i do declarate him after the InitilizeComponent.

Actually it's related to initialization of the logging configuration, and it may happen earlier. For example if you create other loggers.

To solve this, call NLog.Windows.Forms.RichTextBoxTarget.ReInitializeAllTextboxes(this) after InitilizeComponent() and before logging anything to this target. This would tell configuration to search for new controls in this form.

from nlog.windows.forms.

ClementHuart avatar ClementHuart commented on June 22, 2024 1

Thanks a lot
All is working

Clément Huart

from nlog.windows.forms.

mikhail-barg avatar mikhail-barg commented on June 22, 2024

The warning is not a harmful one, it just says that Nlog.xsd has no info on RichTextBox, which is really true.

This by itself should not cause any problems to you. What are the problems you are experiencing? Also, you have internal logging set to log internal warnings to nlog-internal.log which is nice. Could you please check if this file contains anything?

from nlog.windows.forms.

ClementHuart avatar ClementHuart commented on June 22, 2024

I restarted with a blank projet from zero and this time it works. No explanation...

Just one thing, the program does not write into the existing RichTextBox but creates a new one.
I read it can be related to the declaration of the logger but i do declarate him after the InitilizeComponent.

from nlog.windows.forms.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.