C# Object reference not set to an instance of an object.

一、问题

  Object reference not set to an instance of an object. (你调用的对象是空的)

二、解决问题

  1. 在使用 c# 的查询时,先筛选后在关联其他表。
  2. 在查询时先 pageby 在 orderby 导致。
原文地址:https://www.cnblogs.com/gzbit-zxx/p/10870312.html