What version of VFP?
The Grid is ReadOnly, meaning the ComboBox is strictly to display a string?

Tracy


-----Original Message-----
From: [EMAIL PROTECTED]
Sent: Wednesday, July 19, 2006 12:09 PM
Subject: Error 5: In a grid with a combobox


I have a view that has 8 columns, The first one is a combobox, the rest are
check boxes.

The grid has a bldGrid method that is called when it is initialized to place
the appropiate controls in the grid. It also has a setgrid routine to set up
column widths, controlsources, activecontrols, etc. (Also called from the
init.)

The issue is this. I run the query that gets the view information, then
refresh the grid. (The grid's recordsource is specified to the view.)

The combobox's rowsource is an sql query, rowsourcetype 3. During the
gotfocus event of the combo a requery and a refresh of the combobox is
done.Prior to leaving the combobox gotfocus event, I make sure the
underlying view is selected. Also, the combobox's controlsource is the
underlying field in the view.

The grid is readonly by default.

If I do the following, I get the error, "5 Record is out of range", every
time. Click on the combobox, then click on one of the checkboxes. The minute
I click a checkbox, the error occurs, and in the debugger it states that it
is in the GridMouseDown event.

Now, if I remove the combo box, from the column and just use a textbox,
there is no issue, no errors etc. Therefore it must be something in my
combobox... but what?

TIA,
Mike




_______________________________________________
Post Messages to: [email protected]
Subscription Maintenance: http://leafe.com/mailman/listinfo/profox
OT-free version of this list: http://leafe.com/mailman/listinfo/profoxtech
** All postings, unless explicitly stated otherwise, are the opinions of the 
author, and do not constitute legal or medical advice. This statement is added 
to the messages for those lawyers who are too stupid to see the obvious.

Reply via email to