Silverlight Event Log in Isolated Storage

偶尔善良 提交于 2019-12-23 03:22:02

问题


Has anyone written an event log that uses Isolated Storage in Silverlight 3? Any suggestions on implementing one?

Specific questions:

  1. Should I keep a stream writer open, or should I open,write, and close for each entry?
  2. How should I remove items from the log atomically?

回答1:


I heard clog from codeplex is pretty good although it targets wcf, i read on codeproject about about a log4net approach that works for silverlight, although both of these log 2 wcf services, im sure with a bit of tweaking you can modify this to write to isolated storage




回答2:


Crypto Logger supports Silverlight apps and libraries and it can log to its UI console via TCP, to isolated storage and also to the Browser Console (like Firebug in FireFox) or the in-built one in IE8.




回答3:


From the MSDN article on IsolatedStorageSettings and IsolatedStorageFile

Thread Safety

Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.



来源:https://stackoverflow.com/questions/1579260/silverlight-event-log-in-isolated-storage

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!