General information
Category:
Forms & Form designer
No. The select is only ran prior to the init of the Grid. A little more info may help. I have a table that keeps up with timekeeping. The records contain a job number, day of week the job no. was used, and time spent on the job no. I then run the select statement to create a cross tab query that tabulates the days of the week as column headings and groups the job no.'s into rows. Usually we only work 5 days a week. However there has to be provisions for Saturday and Sunday work. In my grid I have columns that list Sat/Sun. with their control source set to respective columns generated by the crosstab. But if no time is entered for Sat or Sun the crosstab won't generate these columns. Therfore leaving to grid no control source for these columns. When I first ran the form I got an error that Sat did not exist. So I put a dummy field in the crosstab with a value of 0. I added an ON Error command in the init of the grid to run a routine to look in this field if Sat was empty. However, now the Sat column picks up data(the last column of the crosstab) no matter what I try. I have removed the On Error, removed all the control source code eccept "ThisForm.Grid1.Column11.ControlSource = 'mysuc.sat'" and I don't get an error even though there is no mysuc.sat. Thanks again.
Previous
Next
Reply
View the map of this thread
View the map of this thread starting from this message only
View all messages of this thread
View all messages of this thread starting from this message only