• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 231
  • Last Modified:

Uninitialised Guids

Hi,

how can i programmatically tell if a Guid has been intialised?
0
cossy74
Asked:
cossy74
  • 2
1 Solution
 
DarkoLordCommented:
Do you mean something like this?

if (guid != null)
{
 // all good
}
0
 
cossy74Author Commented:
DarkoLord: that would only work if you could initialise the Guid to null, which i cannot
0
 
DarkoLordCommented:
How can you use it without it being initalized/assigned then?
0
 
Bob LearnedCommented:
if (guid != Guid.Empty)
{
}

Bob
0

Featured Post

Vote for the Most Valuable Expert

It’s time to recognize experts that go above and beyond with helpful solutions and engagement on site. Choose from the top experts in the Hall of Fame or on the right rail of your favorite topic page. Look for the blue “Nominate” button on their profile to vote.

  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now