Session is an object, it can be null, so if you want to use its value, please check the session first, and even the session's value is not a integer value.
I suggest you to do like this:
int? i = Session["s"] == null ? null : Parser.ParseInt(Session["s"].ToString());