❔ Object reference set to null
With the code shown I am trying to grab the showtimeID the user selected and use it to figure out the seating size of the theatre to ensure the total tickets selected by the user don't exceed the seating size
4 Replies
I keep getting object reference set to null and I can't seem to figure out why
request is the method placeholder
You should be getting a warning that
showTime
might be null
Are you sure there are any items where the ID matches request.ShowTimeId
?The error should give you a stacktrace that point to the exact line the error is thrown at. Could you point out where that is? There's not much context to work with here.
Was this issue resolved? If so, run
/close
- otherwise I will mark this as stale and this post will be archived until there is new activity.