NextPVR Forums
  • ______
  • Home
  • New Posts
  • Wiki
  • Members
  • Help
  • Search
  • Register
  • Login
  • Home
  • Wiki
  • Members
  • Help
  • Search
NextPVR Forums Public NextPVR Other Clients Old Stuff (legacy) NextPVR Enhanced Web Admin (NEWA) v
« Previous 1 … 24 25 26 27 28 … 47 Next »
Search Patch

 
  • 0 Vote(s) - 0 Average
Search Patch
UncleJohnsBand
Offline

Posting Freak

U.S.A.
Posts: 5,643
Threads: 258
Joined: Feb 2005
#1
2008-06-21, 04:14 AM (This post was last modified: 2008-06-24, 10:57 PM by UncleJohnsBand.)
This is a patch to address a bug that difdiffer reported in the build 75 thread.

Check it out and let me know your results.

Edit....removed this patch...read further down for 20080624_01 patch.
Intel Core i7 @ 4.00GHz Skylake 14nm
ASUSTeK COMPUTER INC. Z170-DELUXE
Windows 10 Pro x64
PVR Software: NPVR 5.1.1
SiliconDust HDHomeRun HDHR5-4US Connect Quatro 4 Channel Tuner
Roku Ultra
2 PCH A-100's
difdiffer
Offline

Junior Member

Posts: 12
Threads: 1
Joined: May 2008
#2
2008-06-24, 08:50 AM (This post was last modified: 2008-06-24, 08:57 AM by difdiffer.)
I am not quite sure what your adjusted code exactly does. But it did not fix the problem I described.

Looking at the code I could make a change myself to make it work. Please review the code addition I made, and mybe you can see if you need to incroporate this in a smarter way (probably), or if I made any oversights. (My additions are in BOLD)

Basically the idea is that once program.getEndTime() is passed the 23:59 mark it becomes (on a new date) 00:00. Than the program.getEndTime(). is allways smaller than endTime, but in fact it is larger, because the date is left out of the equation. I am not programmer enough to walk through your code (not do I have the time) but comparing time and date together as one string should solve the problem.

+++++CODE++++++++++++


//Check to see if the programmme needs to fall between the two times
if (startTime.ToString("HH:mm") != "01:01" && endTime.ToString("HH:mm") != "01:01")
{
int Cmpr1 = String.Compare(startTime.ToString("HH:mm"),program.getStartTime().ToString("HH:mm"));
int Cmpr2 = String.Compare(endTime.ToString("HH:mm"),program.getEndTime().ToString("HH:mm"));
if (Cmpr1 > 0 || Cmpr2 < 0)
{
showProgram = false;
}
int Cmpr3 = String.Compare(program.getEndTime().ToString("HH:mm"),program.getStartTime().ToString("HH:mm"));
if (Cmpr3 < 0)
{
showProgram = false;
}
difdiffer
Offline

Junior Member

Posts: 12
Threads: 1
Joined: May 2008
#3
2008-06-24, 10:39 AM (This post was last modified: 2008-06-24, 11:07 AM by difdiffer.)
I have put some time in it, and this looks better. Please give me your comments:


if (showProgram)
{
//Check to see if the passed in times need to be looked at
if (startTime.ToString("HH:mm") != "01:01" || endTime.ToString("HH:mm") != "01:01")
{
//Check to see if the programmme needs to fall between the two times
if (startTime.ToString("HH:mm") != "01:01" && endTime.ToString("HH:mm") != "01:01")
{
int Cmpr1 = String.Compare(startTime.ToString("HH:mm"),program.getStartTime().ToString("HH:mm"));
int Cmpr2 = String.Compare(endTime.ToString("HH:mm"),program.getEndTime().ToString("HH:mm"));

//Check to see if the start time is smaller than the end time (Requested recording period falls within 1 day )
if (String.Compare(startTime.ToString("HH:mm"),endTime.ToString("HH:mm")) < 0)
{
//Check to see if the programmme end time is greater than the start time (program starts and ends within the same day)
if (String.Compare(program.getEndTime().ToString("HH:mm"),program.getStartTime().ToString("HH:mm")) > 0)
{
if (Cmpr1 > 0 || Cmpr2 < 0)
{
showProgram = false;
}
}
//Else the programmme end time is smaller than the start time (Prgramme passes the 24:00 mark, passing over to the next day)
else
{
showProgram = false;
}
}
//Requested recording period passes the 24:00 mark, covering more than 1 day)
else
{
//Check to see if the programmme end time is greater than the start time (program starts and ends within the same day)
if (String.Compare(program.getEndTime().ToString("HH:mm"),program.getStartTime().ToString("HH:mm")) > 0)
{
//When the programme falls within 1 day the end time of the search should be smaller. If not, the programme falls completely within the following day, making part of the valid search result.
if (Cmpr2 < 0)
{
if (Cmpr1 > 0 )
{
showProgram = false;
}
}
}
//Else the programmme end time is smaller than the start time (Prgramme passes the 24:00 mark, passing over to the next day)
else
{
if (Cmpr1 > 0 || Cmpr2 < 0)
{
showProgram = false;
}
}
}
}
else
UncleJohnsBand
Offline

Posting Freak

U.S.A.
Posts: 5,643
Threads: 258
Joined: Feb 2005
#4
2008-06-24, 10:56 PM
Seems to be working...attached updated patch for people to try it out.

There is identical coding in the auto-search area of ewa which I will need to patch as well....or refactor that code to use this core search engine code....

Anyone willing to test this please do....the more people testing the more comfortable I'll be.....search has always been the most tedious thing to tweak.

Post any results here.
Intel Core i7 @ 4.00GHz Skylake 14nm
ASUSTeK COMPUTER INC. Z170-DELUXE
Windows 10 Pro x64
PVR Software: NPVR 5.1.1
SiliconDust HDHomeRun HDHR5-4US Connect Quatro 4 Channel Tuner
Roku Ultra
2 PCH A-100's
UncleJohnsBand
Offline

Posting Freak

U.S.A.
Posts: 5,643
Threads: 258
Joined: Feb 2005
#5
2008-07-09, 03:34 AM
Has anyone other than myself and difdiffer tested this search patch?
Intel Core i7 @ 4.00GHz Skylake 14nm
ASUSTeK COMPUTER INC. Z170-DELUXE
Windows 10 Pro x64
PVR Software: NPVR 5.1.1
SiliconDust HDHomeRun HDHR5-4US Connect Quatro 4 Channel Tuner
Roku Ultra
2 PCH A-100's
difdiffer
Offline

Junior Member

Posts: 12
Threads: 1
Joined: May 2008
#6
2008-10-23, 12:39 PM
Hi Uncle,

I have tried to update to release 77, but the search updates I made do not function correctly in that version.

E.G. if I search for a name and put start time range to 5PM till 11PM i find nothing, and the data is there 4 sure. Also when I update with your patch here (and a later version) it does not work.

However, if I use my own code, it works fine. Any clues?

Cheers
UncleJohnsBand
Offline

Posting Freak

U.S.A.
Posts: 5,643
Threads: 258
Joined: Feb 2005
#7
2008-10-24, 02:52 AM
difdiffer Wrote:Hi Uncle,

I have tried to update to release 77, but the search updates I made do not function correctly in that version.

E.G. if I search for a name and put start time range to 5PM till 11PM i find nothing, and the data is there 4 sure. Also when I update with your patch here (and a later version) it does not work.

However, if I use my own code, it works fine. Any clues?

Cheers

Have you compared the code that is in the build and what you are using?
Intel Core i7 @ 4.00GHz Skylake 14nm
ASUSTeK COMPUTER INC. Z170-DELUXE
Windows 10 Pro x64
PVR Software: NPVR 5.1.1
SiliconDust HDHomeRun HDHR5-4US Connect Quatro 4 Channel Tuner
Roku Ultra
2 PCH A-100's
« Next Oldest | Next Newest »

Users browsing this thread: 1 Guest(s)



Possibly Related Threads…
Thread Author Replies Views Last Post
  Episode search missing in 4.2.4 UncT 4 3,095 2019-03-08, 06:08 PM
Last Post: UncT
  NEWA Auto-Search Command Line Interface (CLI) UncleJohnsBand 40 37,539 2018-05-09, 12:50 AM
Last Post: jksmurf
  EPGEventDisplay - Adding web search link sle118 0 2,017 2015-11-02, 03:11 PM
Last Post: sle118
  Auto-Search? snagglewest 11 5,154 2014-12-17, 01:46 PM
Last Post: UncleJohnsBand
  How to search only for programs or episodes marked as (* New *) jfestrada 2 1,760 2014-02-27, 03:31 AM
Last Post: UncleJohnsBand
  Null search strings in episode search ... softfoot 1 1,469 2013-11-27, 03:32 AM
Last Post: UncleJohnsBand
  IE11 Patch UncleJohnsBand 0 1,378 2013-11-12, 04:41 AM
Last Post: UncleJohnsBand
  episode search, don't get it - not working ? KRA 17 6,147 2012-10-28, 12:28 AM
Last Post: UncleJohnsBand
  Blow up when trying to Record an item from the Search results wtg 2 1,708 2012-08-10, 09:15 PM
Last Post: wtg
  TreeView no longer working in Advanced Search wtg 6 2,327 2012-04-28, 03:40 PM
Last Post: UncleJohnsBand

  • View a Printable Version
  • Subscribe to this thread
Forum Jump:

© Designed by D&D, modified by NextPVR - Powered by MyBB

Linear Mode
Threaded Mode