© 2026 Hedgehog Software, LLC

TwitterGitHubDiscord
More
CommunitiesDocsAboutTermsPrivacy
Search
Star
Setup for Free
C#C
C#•4y ago•
36 replies
LukeZurg22

Minor Error Handling ; TryGetValue returning null [Answered]

I have a method that is designed to check through a series of dictionaries and compare the output keys and values. An if-statement is meant to check for any value that could not be gotten with a TryGetValue and instead do something else, but despite that check being there it spits an error exclaiming it could not get a value out to begin with.
C# banner
C#Join
We are a programming server aimed at coders discussing everything related to C# (CSharp) and .NET.
61,871Members
Resources

Similar Threads

Was this page helpful?
Recent Announcements

Similar Threads

empty regex groups returning true from TryGetValue??
C#CC# / help
4y ago
Exception/NULL/Error handling advice.
C#CC# / help
4y ago
Error Handling vs Type Enforcement [Answered]
C#CC# / help
4y ago