Blog

Page 188 of my articles, tutorials, and thoughts

Latest Articles

Cover Image for What"s the difference between StaticResource and DynamicResource in WPF?
.net

What"s the difference between StaticResource and DynamicResource in WPF?

Published on September 2, 2023

# Understanding the Difference between StaticResource and DynamicResource in WPF šŸ”šŸ–„ļø Have you ever wondered what's the deal with the StaticResource and DynamicResource keywords when using resources in WPF? šŸ¤” You're not alone! It can be confusing to fig

Cover Image for Asynchronously wait for Task<T> to complete with timeout
c#.net

Asynchronously wait for Task<T> to complete with timeout

Published on September 2, 2023

# šŸ• Asynchronously Waiting for Task&lt;T&gt; to Complete with Timeout Waiting for a `Task&lt;T&gt;` to complete with a timeout can be a tricky task, especially when we want to display a message to the user or request cancellation after a certain time. šŸ¤”

Cover Image for What is the difference between Nullable<T>.HasValue or Nullable<T> != null?
c#.netnull

What is the difference between Nullable<T>.HasValue or Nullable<T> != null?

Published on September 2, 2023

# What's the Difference Between `Nullable<T>.HasValue` and `Nullable<T> != null`? šŸ¤” So you've come across this debate in your coding adventures: Should you use `Nullable<T>.HasValue` or `Nullable<T> != null` to check if a nullable value has a non-null va

Cover Image for "An attempt was made to load a program with an incorrect format" even when the platforms are the same
.net

"An attempt was made to load a program with an incorrect format" even when the platforms are the same

Published on September 2, 2023

# šŸš€ "An attempt was made to load a program with an incorrect format" - Demystifying the Error 🧩 So, you're calling functions from a 32-bit unmanaged DLL on a 64-bit system, but you're constantly getting the dreaded "BadImageFormatException: An attempt w

Cover Image for What is the proper way to rethrow an exception in C#?
c#exception.net

What is the proper way to rethrow an exception in C#?

Published on September 2, 2023

# The Proper Way to Rethrow an Exception in C# šŸ‘‹ Welcome to my tech blog! Today, we're diving into an important question in C#: what is the proper way to rethrow an exception? šŸ¤” We'll explore two common approaches and discuss which one is better. Let's

Cover Image for How do I remove diacritics (accents) from a string in .NET?
.netstring

How do I remove diacritics (accents) from a string in .NET?

Published on September 2, 2023

# Removing Diacritics (Accents) from a String in .NET šŸ’„ Are you trying to convert strings with French accents to plain text without losing the intended characters? šŸ˜• Look no further! In this guide, we'll explore the best methods for removing diacritics

Cover Image for HashSet vs. List performance
collectionshashlist.netperformance

HashSet vs. List performance

Published on September 2, 2023

# šŸ“ HashSet vs. List Performance: Which One Wins the Race? Are you also wondering where the break-even point lies between the search performance of `HashSet<T>` and `List<T>`? šŸ¤” Don't worry, we've got you covered! In this blog post, we'll address common

Cover Image for How to verify that method was NOT called in Moq?
c#.net

How to verify that method was NOT called in Moq?

Published on September 2, 2023

# šŸ•µļøā€ā™€ļø How to Verify that a Method Was NOT Called in Moq šŸ•µļøā€ā™‚ļø Do you ever find yourself in a situation where you need to make sure that a specific method was **not** called while using Moq? šŸ¤” It's not uncommon for us to overlook this requirement, but

Cover Image for How do I fix the Visual Studio compile error, "mismatch between processor architecture"?
.net

How do I fix the Visual Studio compile error, "mismatch between processor architecture"?

Published on September 2, 2023

šŸ“ **Tech Blog** šŸ–„ļø šŸ“Œ **Title:** How to Fix the Visual Studio Compile Error: "Mismatch Between Processor Architecture" šŸ“… **Published on:** [insert date] šŸ—Øļø **Author:** [insert name] --- šŸ‘‹ Hey there, fellow developer! šŸ‘Øā€šŸ’» Are you struggling wi

Blog | Matheus Mello