PDA

View Full Version : The IListSource does not contain any data sources



tazekar
چهارشنبه 02 مهر 1382, 07:01 صبح
سلام
آقا من هر موقع که میخوام datagrid.databind کنم این خطا رو میده :



The IListSource does not contain any data sources.
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

Exception Details: System.Web.HttpException: The IListSource does not contain any data sources.

مثلا برای این کد :


this.DataGrid1.CurrentPageIndex=e.NewPageIndex;
this.DataGrid1.DataBind();


اما برای بعضی از فرمهام هم درست کار میکنه .
لطفا دلیلش رو بهم بگین .

Vahid_Nasiri
چهارشنبه 02 مهر 1382, 11:35 صبح
شما واقعا فکر می کنید با دیدن دو خط از کد کسی می تواند جواب بدهد؟

جواب شما:
http://www.eggheadcafe.com/forums/Forumsearchbranch.asp?THREADID=4694&INTID=6

tazekar
چهارشنبه 02 مهر 1382, 11:39 صبح
شما دست میفرمایید . اما منظور من اینه که بطور کلی هر موقع که میخوام اطلاعات رو با دیتاگرید bind کنم این اتفاق میافته .