New Posts New Posts RSS Feed: LogWriter
  FAQ FAQ  Forum Search   Calendar   Register Register  Login Login

LogWriter

 Post Reply Post Reply
Author
gregweb View Drop Down
DevForce MVP
DevForce MVP
Avatar

Joined: 10-Sep-2009
Location: Clearwater, Fl
Posts: 253
Post Options Post Options   Quote gregweb Quote  Post ReplyReply Direct Link To This Post Topic: LogWriter
    Posted: 12-Dec-2012 at 2:17pm
The LogFns in TempHire don't seem to be putting out anything to my Output window. Is there a switch somewhere? Am running in Debug.

Greg
Back to Top
mgood View Drop Down
IdeaBlade
IdeaBlade
Avatar

Joined: 18-Nov-2010
Location: Emeryville, CA
Posts: 583
Post Options Post Options   Quote mgood Quote  Post ReplyReply Direct Link To This Post Posted: 12-Dec-2012 at 2:36pm
Greg,
The release build of the Cocktail assemblies does not log to the output window. That code gets optimized away by the compiler. You have two options. You can create your own custom logger as described here:

http://drc.ideablade.com/devforce-2012/bin/view/Documentation/custom-logger

and then log using LogFns.TraceWriteLine and LogFns.TraceWriteLineIf. The tracing methods work in the release build. 

The second option is to build the debug Cocktail assemblies from the source code yourself and reference them from your code. 
Back to Top
gregweb View Drop Down
DevForce MVP
DevForce MVP
Avatar

Joined: 10-Sep-2009
Location: Clearwater, Fl
Posts: 253
Post Options Post Options   Quote gregweb Quote  Post ReplyReply Direct Link To This Post Posted: 12-Dec-2012 at 3:53pm
Got it, thanks.

Greg
Back to Top
gregweb View Drop Down
DevForce MVP
DevForce MVP
Avatar

Joined: 10-Sep-2009
Location: Clearwater, Fl
Posts: 253
Post Options Post Options   Quote gregweb Quote  Post ReplyReply Direct Link To This Post Posted: 12-Dec-2012 at 3:56pm
By the way, I enjoyed watching all the Temp Hire videos that you and Ward did - it was very helpful to see a high level walkthrough of a very sophisticated framework.
Back to Top
nihique View Drop Down
Newbie
Newbie


Joined: 15-Dec-2012
Posts: 2
Post Options Post Options   Quote nihique Quote  Post ReplyReply Direct Link To This Post Posted: 15-Dec-2012 at 4:04pm
Hi Marcel,

I am doing Cocktail tutorial HappyHour and it looks very good, but I have same problem like Greg - cannot see messages in output window when using Nuget package. Is there a way how to still use Nuget and get them? They dont have to be in output window, I very much prefer custom logfile, so I can view it on second monitor...

I cannot/don't want overwrite packages manually, this is very nasty and it will not work for other team members - we are using nuget package download on build.
Back to Top
mgood View Drop Down
IdeaBlade
IdeaBlade
Avatar

Joined: 18-Nov-2010
Location: Emeryville, CA
Posts: 583
Post Options Post Options   Quote mgood Quote  Post ReplyReply Direct Link To This Post Posted: 16-Dec-2012 at 12:15am
In addition to installing your own TraceLogger as described above you can install your own logger for Caliburn.Micro by assiging it to LogManager.GetLog.
 
You can use the DefaultDebugLogger as guidance for how to implement a logger for Caliburn.Micro.
 
Back to Top
nihique View Drop Down
Newbie
Newbie


Joined: 15-Dec-2012
Posts: 2
Post Options Post Options   Quote nihique Quote  Post ReplyReply Direct Link To This Post Posted: 16-Dec-2012 at 8:56am
thank you, I am using debug builds for now
Back to Top
mgood View Drop Down
IdeaBlade
IdeaBlade
Avatar

Joined: 18-Nov-2010
Location: Emeryville, CA
Posts: 583
Post Options Post Options   Quote mgood Quote  Post ReplyReply Direct Link To This Post Posted: 16-Dec-2012 at 9:24am
Great. I rarely need the diagnostics output, but if I do I simply override the assemblies in my local packages folder with the debug assemblies. That way nothing has to change in the projects and the build server will continue to build against the release assemblies.
Back to Top
 Post Reply Post Reply

Forum Jump Forum Permissions View Drop Down