Hello again everybody, It's the rookie, back with more questions. I was trying very hard to solve these problems myself, but if anyone can help please do.
I am working on subclassing the cifcombobox, to make it based on a view instead of a table. I am working with the example posted by Jose Constant from message 3865. I created a view (v_agreecombo) with the cid field and a character field from one of my tables. I created the agreecomboDE and v_agreecombo as cdynamicviewcursor in adataenv.prg. I created a bizobj which loads the v_agreecombo. I have over written the init(), requery() and gotfocus() using Jose's example. I have the following property values: BoundColumn = 1 (corresponding to the cid column) ColumnCount = 2 ColumnWidths = 0, 100 RowSource = v_agreecombo RowSourceType = 2 - Alias Style = 0 - Dropdown combo calias = v_agreecombo cfield = agreenum clookupalias = v_agreecombo clookupfield = v_agreecombo.agreenum (character field, 2nd column) ldisplayinitialvalue = .T.
I have the following problems: 1. The form flows right from activate to destroy, and simply flashes by, I would like it to stay around for a while, or until I want it to destroy anyway. I set breakpoints in various spots to see what was happening, and compared it to a previous form,, but I cannot tell what is different.
2. With breakpoints set, I can play with the form before it destroys. The initial value is the first agreenum in the view, so far so good. When I choose a value from the list, the cid value becomes the display value. I want the agreenum value to remain there instead.
3. I am not able to type in a value into the combo box. I was expecting to be able to type in characters, and have the list requeried with each keypress. So, if I know the first few digits of an agreenum, I could key them in, and then search the list for the specific record to choose.
Again, I know I am missing something, but I hope You can show me the way.
One thing that was really puzzling me was exactly how does one set an index to a view? I know how to order the view, but how do you set index to a view, and where?
Devman mdevlin .at. ajdebruin .D.O.T com
©2000 Mike Devlin |