Compact Framework Non Culture Specific Exception Messages - exception

I have created an application in Compact Framework 2.0
This application is being used in many various counties and cultures.
My Issue is that any and all exceptions are logged, but they are appearing in the culture of the device, in some cases this means i am unable to read them.
Any help or suggestions will be appreciated
Thanks

See this link for details.
System.SR.dll assembly, which contains the error strings, is not present in the .NET CF redistributable, so you are probably logging a message that it says that a resource assembly isn't found (in a number of different languages). You could install the English assembly in users phones, but this is not recommended. You need to find a different debugging method and not rely on exception messages in users phones.

Related

cannot find member on object of runtimetype

I am currently working on a legacy web app which uses newtonsoft.json.dll version 1.3.0 and vb.net.
I added four new fields in the application. This source code is shared by another application and it posts into my application and it breaks it.
See image for error.
[]
The error is:
Could not find member x on object of type runtimetype.
The stacktrace breaks at:
newtonsoft.json.jsonserializer.setobjectmember(jsonreader reader,object target, type targettype, string membername)
I did some research. The folks reportedly solved such an issue by upgrading DLL version and didn't have a direct solution to fixing it via code change. I know its very old and the application is high impact any upgrade has huge ripple. However they are planning a rewrite of the application.
Can someone please share any ideas that i should pursue in order to solve this?.
I am expected to make it quick and under pressure.
https://smugmugc3.codeplex.com/workitem/10024
My problem is very similar to what is described in the link above.
I am going to upgrade my version of json converter after convincing my boss and I see that is the only way out of this problem.
After which I will update this thread if I find issues.

MvvmCross-based application is unable to load design-time view model

I've found a topic describing NullReferenceException in Windows Phone designer, however I believe this is a somewhat different issue, since it happens in all platforms and not related to MvvmCross plugins.
Designer (VS2012, Store/WP8/WPF apps) works fine for earlier versions of MvvmCross. I tried to compile a version that corresponds to 3.0.6 NuGet packages, and I can see that design-time model is loaded in all platforms.
Recent MvvmCross version causes all designer to raise NULL reference exception ("Object reference not set to an instance of an object") on all platforms.
Attempt to debug a VS instance didn't help: the call stack doesn't say much, and there is no MvvmCross code there.
The error is not related to the actual view/view model: I can remove all controls from the view, and the error is stil raised. The view model constructor code is never reached.
So it looks like there's some MvvmCross code (not from MvxView) that is unsuccessfully executed in at design-time. I wonder if this is a known issue and/or if there is a workaround to get designer work.
UPDATE. I created a GitHub issue with steps to reproduce the problem: https://github.com/slodge/MvvmCross/issues/347
This question moved to GitHub where there was lots of discussion and a few samples - https://github.com/slodge/MvvmCross/issues/347
From these samples, I believe we concluded the Nuget release 3.0.8.1 :
supports time data based on Blend-generated XML data files
supports design-time data based on simple C# classes
does not support design-time data where the data uses MvvmCross MvxViewModel as a base class
It isn't entirely obvious that developers should want to do the third thing (designtime data isn't real data?), but given that the overall MvvmCross manifesto broadly speaking aims to enable developers and to give them choice, then future MvvmCross will make this easier in the future.
In the meantime, if anyone wants to initialise objects at design-time, then there are a few helper classes around to enable this.
For example, the color plugin (and a small part of MvvmCross IoC) can be made available in the design-time environment using the MvxColorDesignTimeHelper - see:
https://github.com/slodge/MvvmCross/issues/323 (linked to MvvmCross throws NullReferenceException in Windows Phone Designer)
https://github.com/slodge/MvvmCross/blob/TibetBinding/Plugins/Cirrious/Color/Cirrious.MvvmCross.Plugins.Color.WindowsPhone/MvxColorDesignTimeHelper.cs
https://github.com/slodge/MvvmCross/blob/TibetBinding/CrossCore/Cirrious.CrossCore.WindowsPhone/Platform/MvxDesignTimeHelper.cs

Are there any general purpose exception-handling frameworks for capturing and managing exceptions?

We have a system built on MarkLogic, Java / GlassFish. We need some kind of system that could capture thrown exceptions from any of those three subsystems, and then provide a nice web-based reporting interface where exceptions could be viewed, prioritized, marked done. We use JIRA.com in the cloud so if there was any way to integrate with that, it would be nice. Prefer open source or inexpensive.
I'm not sure whether a Java-based system would accomodate our MarkLogic errors, so I believe we need something that is language-agnostic.
Thanks.
If you are communicating with MarkLogic using a MarkLogic "HTTP appserver" (as opposed to XCC or WebDAV), then you can use the error handler configuration as a choke point for catching unhandled exceptions. I've never tried this, but, in theory, in the error handler, you could make an http request and send them anywhere you want.
See http://docs.marklogic.com/5.0doc/docapp.xqy#display.xqy?fname=http://pubs/5.0doc/xml/dev_guide/appserver-control.xml%2387072
If you are using XCC, then there are other places to put choke points in your Java code.
MarkLogic writes exceptions by default to the Data/Logs/ErrorLog.txt file. Application code within MarkLogic can use xdmp:log, or trace() to log messages to the same file. The file can be accessed quite easily through file-system if GlassFish is running on the same host., It can also be disclosed through an App Server within MarkLogic with some custom XQuery code.
GlassFish itself appears to be a Java EE platform. I expect it to do logging using something like Log4J. The logging messages in the ErrorLog and the Log4J log will likely not be formatted identically, but basic properties should be there, like date/time, and error message. Log4J logging can be set to write to a log file as well. You could consume it in a similar way as the ErrorLog.
I am not aware of any error reporting web-interface for such logging, but I believe JIRA provides an HTTP API, which can be used to push information into it.

Handling Policy based exception using MS Entlib 5.0

I would want to learn about MS Entlib 5.0. Frankly I have no idea what it is. Please provide me the links to start exploring. Then I Would have to evaluate whether the following requirements can be met using MS Entlib 5.0
1.Policy based exception handling & logging into both file and DB
2.Capability to enable detailed logging through trace/debug.
3Capability to overwrite business exception raised from stored proc or BO with a localized exception message for UI display
Please provide your valuable inputs on the above requirements.
Thanks in Advance,
Manasa
Manasa, EntLib can help with all 3 scenarios you inquired about.
EntLib is a collection of pluggable application blocks that address cross-cutting concerns, such as logging, exception management, data access, data validation etc. EntLib is configuration-driven (supporting both external configuration sources and programmatic config via fluent interface). It's a mature library which is currently in its 5th release and is built by Microsoft patterns & practices group.
I recommend you start with the Enterprise Library Developer's Guide, in particular Chapters 1, 3 and 4. Then proceed with the Hands-On Labs. Based on your requirements, you would want to explore the Logging and Exception Handling set of exercises.
Additional resources can be found at:
MSDN EntLib Dev Center is the home page where all final releases and documentation can be
found.
EntLib Community Site - includes preview releases, ongoing work, community forum, issue database and other useful resources.

Enterprise Library Exception Handling application blocks

Where can I find some good examples on
1) How to configure Enterprise Library Exception Handling application blocks and
2) How to Log an exception error messages to a text file
(I am using VS2008 asp.net3.5, C# to develop a web application
and uses Enterprise library 4.1 for Exception Handling and Error logging )
Thank you all in advance
Take a look at the hands-on labs for Entlib 4.1. They include lots of examples on how to use the blocks, including the exception block.
As mentioned, The Hands on Labs are a good place to start. You could also take a look at the Quick Starts. When you install the source code you have the option of installing the Quick Starts. There is an ExceptionHandlingWithLoggingQuickStart project there that you would probably find useful.