Show Extra Messages when search no records found

This public forum is for user-to-user discussions of ASP.NET Maker. Note that this is not support forum.
Post Reply
kmteetsa
User
Posts: 2

Show Extra Messages when search no records found

Post by kmteetsa »

May I know how to show extra messages/text comment when search no records found?


MichaelG
User
Posts: 1132

Post by MichaelG »

You can check for TotalRecords and add a message if necessary in the Page_Render server event of the list page. For example:

if (TotalRecords <= 0)
WarningMessage = "...";


kmteetsa
User
Posts: 2

Post by kmteetsa »

Hi,
What if I have two Ext. Search under AND condition and the TotalRecords meant zero search results from the default value.
I am still not able to get TotalRecords from Page_Render. Would you mind giving me more clues on the script?


MichaelG
User
Posts: 1132

Post by MichaelG »

You can add codes to show TotalRecords in Page_Render. For example:

WarningMessage = "Total records: " + Convert.ToString(TotalRecords);

You can also run your project with Visual Studio so that you can add a break point to the codes to see why it is not working.


Post Reply