You are getting a catch block triggered, but you don’t know what the source of the error was Menu > Debug > Windows > Exception Settings Turn on “Common Language Runtime Exceptions” Now you will get a break on the line where the exception occurs
All posts by
Verifying DateTime
Convert string to DateTime without erroring on fail
if
If with load of a return value into a variable Ensure you enclose the assignment in brackets or it won’t work correctly
UTC
Convert To Universal Time Format String Converting a DateTime to this format allows you to avoid local date time format issues when passing DateTime values between systems. Then just use Convert::ToDateTime to convert it back.
Inconsistent accessibility: field type is less accessible than field
Example error message: Inconsistent accessibility: field type ‘MyPublicClass’ is less accessible than field ‘MyPublicObject.MyPublicStaticClassObject’ We often use a public static class ApMain in our projects: Within this we create other objects as public static, so they can be accessed throughout the app: These can then be accessed using: If you get this error when you […]
xaml.cs Does Not Exist in Current Context Error
Seems to be a VS bug whereby in some instances adding or renaming an object in the xaml file causes “Does Not Exist in Current Context Error” when using the object in the .xaml.cs file. Looking online it seems to be something that plagues lots of devs… Compiles OK but Intellisense red lining the object […]
File path is too long
When building, particularly for release versions, VS can add a lot of characters to paths with its output files and if you end up with a path over 260 characters you can get build errors caused by the path being too long (file inaccessible etc errors). A solution is to enable long file path support […]
Multidimensional arrays
2 Dimensional Arrays Or as a jagged array Getting length of each part of an array Example usage
Determing an objects Type
Async HTTP Get
Global objects Send Request Check for response