|
Rank: Advanced Member
Groups: Administrators, Registered
Joined: 8/13/2004 Posts: 2,669 Location: Canada
|
Can you post the entire method, both modified so it works and modified so it doesnt. Jim -your feedback is helpful to other users, thank you!-your feedback is helpful to other users, thank you!
|
|
Rank: Member
Groups: Registered
Joined: 2/23/2014 Posts: 24
|
I think what happened is the page loading twice. The first time around when the search button clicked it goes through select and execute the right statement, then its reload master page and comeback to the search page and start load again, this time its resets to initial state, so drop list cboQueryType get reset too. So I think that my problem, I have to figure out why that happened. Thank for you help, Alex ag
|
|
Rank: Advanced Member
Groups: Administrators, Registered
Joined: 8/13/2004 Posts: 2,669 Location: Canada
|
Ah, so let me explain something here. The SearchBox is able to be used on the same page as SearchResult, but ALSO on separate pages. So to enable that, how it works is like this; when you click the search button, the page postsback (which is when you got the value of cboQueryType that you wanted), and then during that postback, the SearchBox control redirects to the page with SearchResult on it (for you this is the same page). So then it loads the page again, but this time, you have no cboQueryType value. One solution would be store cboQueryType's value in a Session variable, and pick it up when the page loads. Sorry this caught you out - I can see that it could be confusing. Jim -your feedback is helpful to other users, thank you!-your feedback is helpful to other users, thank you!
|
|
Rank: Member
Groups: Registered
Joined: 2/23/2014 Posts: 24
|
Thanks, Jim The session variable did the trick. Alex ag
|
|
Rank: Member
Groups: Registered
Joined: 2/23/2014 Posts: 24
|
Hi Jim, My plugin stop working and throw this error: Unable to cast object of type 'Keyoti.SearchEngine.DataAccess.IndexableSourceRecords.WebsiteBasedIndexableSourceRecord' to type 'System.Net.HttpWebResponse'. When I execute this statement below: lastResponseLastModified = (CType(e.ActionData.Data, HttpWebResponse)).LastModified Please let me know if you have any idea what is going on. Thanks. alex ag
|
|
Rank: Member
Groups: Registered
Joined: 2/23/2014 Posts: 24
|
Hi Jim I've got another question for you. I implemented the sort buttons as in the Demo that you provided. This sorted only the page of the result. How to sort entire result? Thanks, Alex ag
|
|
Rank: Advanced Member
Groups: Administrators, Registered
Joined: 8/13/2004 Posts: 2,669 Location: Canada
|
Sorry it's a deficiency in the example code - because these variables won't last when the page posts back to go to the next page of results Code: Dim sortByDate As Boolean = False Dim sortDirection As SortDirection = SortDirection.Descending
So the solution is to replace them with Session variables also. 1. Comment out the code above 2. Where ever those vars are used, replace them with a Session variable, eg. Code: Protected Sub sortDownBT_Click(ByVal sender As Object, ByVal e As System.EventArgs)
Session("sortByDate") = True
Session("sortDirection") = sortDirection.Descending
Sr1.InvalidateChildControlHierarchy()
End Sub
and so on. Hope you can follow what I mean, as VB.NET isn't my first lang. Best Jim -your feedback is helpful to other users, thank you!-your feedback is helpful to other users, thank you!
|
|
Rank: Member
Groups: Registered
Joined: 2/23/2014 Posts: 24
|
Hi Jim, That what is happened with plugin, every time indexing process try to index .css or .dll or .mdb plugin is throwing error. How can I avoid to index those file extensions. Is there config file I can specify. Thanks, Alex ag ag
|
|
Rank: Advanced Member
Groups: Administrators, Registered
Joined: 8/13/2004 Posts: 2,669 Location: Canada
|
Alex would you mind starting a new topic with this question, that way it can be helpful to other users. Thanks -your feedback is helpful to other users, thank you!-your feedback is helpful to other users, thank you!
|
|