开发者

SQL Viewstate in Delphi ASP.Net - How to override PageStatePersister

I am following this example of storing the view state in the database. However, I have come to the end of the page and its asking me to override a property .. I have no idea how to achi开发者_JAVA百科eve this in delphi. Can someone point me in the right direction?

I am using a Masterpage setup and .NET 2.0

View State in DB

EDIT: For more information, this is what I have tried:

TDefault = class(System.Web.UI.Page)
   //Code excluded
public
   function GetPageStatePersister: PageStatePersister; 
   property PageStatePersister: PageStatePersister read GetPageStatePersister;
end;

But the code inside GetPageStatePersister isn't called.

Thanks.


Ok, managed to sort this out. Using .NET Reflecter I dug through the System.Web.UI.Page assembly and found that the function is called get_PageStatePersiter so I have just done:

function get_PageStatePersister: PageStatePersister; override;
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜