Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Grids problem

Status
Not open for further replies.

syangloo

Programmer
Aug 23, 2000
17
MY
Hello, i new in this forum and the programming area also, I hope your can help me to solve the grids problem/how to make it work. I need to display a table in a grids, i build it with builder. The purpose of this grids is display like appointment schedule. Now when i run the form / grids it display the last record in the table at the grid. How can i make it display the record -IF the table.date same as today date and record will display with sorting by the time? How to refersh the grids from time to time for checking new record add in?
 
syangloo

Assuming TABLE.date to be a date field, in the .Init event of the grid put:-

LOCATE FOR TABLE.date = DATE()

Ensure the TABLE.date is indexed

GRID.Refresh() will refresh the grid - how are you adding records?

Chris
 
Thank Chris, the Date problem is solve.
If i using the pageframe for this appointment schedule, 1st for the grid display, 2nd for the user to add in or edit the appointment time.


Below is my runtime clock running on the form, Can i add in the GRID.Refresh() in the statement. Are it refresh the grids every second?
IF THISFORM.Time.Value != Time()
THISFORM.Time.Value = Time()
* Grid.refresh()
ENDIF
 
syangloo

Put THISFORM.pgf1.Page1.Grid.Refresh() in the Activate event of the page with the grid.

Chris
 
syangloo

Thanks for your thanks.

Now it's working you might care to replace THISFORM.pgf1.Page1.Grid.Refresh() with THIS.Grid.Refresh() in the Activate event of the page with the grid.

Chris
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top