This topic is locked

Search value

2/11/2011 2:31:44 AM
PHPRunner General questions
U
unp author

How can I create an initial search value when I start on one side with the opportunity to elect a new search value for Report in phprunner V5.2 and v5.3

Ex: I have a field with name 'Date' in format YYYY-MM-DD. I want to see my report where 'Date' >= 'To day'

How can I make it?

Sergey Kornilov admin 2/11/2011

Assuming that date field name is 'datefield' add the following to the search page JavaScript OnLoad event.

var ctrl = Runner.getControl(pageid, 'datefield');

var d = new Date();

ctrl.setValue(d);

$('#srchOpt1datefield').val('More than');

V
vanbortelDevClub member 2/22/2011



Assuming that date field name is 'datefield' add the following to the search page JavaScript OnLoad event.


I have a similar request but the suggested code will not work for me.

My code is:

var ctrl = Runner.getControl(pageid, 'Order_Date');

var d = now();

ctrl.setValue(d);

$('#srchOpt_1_Order_Date').val('More than');
Also, when this code is inserted I get the following error when I click on a child table link from the list page.
Fatal error: Cannot redeclare class eventclass_My_Quotes in C:\xampp\htdocs\vbpilot_out_53\include\My_Quotes_events.php on line 65
Thank you for any help

Sergey Kornilov admin 2/22/2011

Make sure you add this code to Javascript OnLoad event of corresponding page.
If this doesn't help post your application to Demo Account and open a ticket at http://support.xlinesoft.com sending your Demo Account URL. 'Demo Account' button can be found on the last screen in the program.