Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
CreateObject Error? Is it a known bug?
Message
From
24/04/1998 22:24:03
 
 
To
24/04/1998 18:11:12
General information
Forum:
Visual FoxPro
Category:
Forms & Form designer
Miscellaneous
Thread ID:
00094559
Message ID:
00094834
Views:
22
>>After create a form will a combox with to show the field list,
>>For Do Form Version, It work fine!
>>
>>But for CreateObject Version, it prompt to assign table on selection
>>the working table. Why??
>>
>>2nd, If I open other forms and got another selection area,
>>then open this form. The FIeld list do not change as my desire!!
>>
>>Even I code it will change table, the field do nothing!

* This is the cboField.Init Procedure, rowsourcetype=0 in form designer!
* ... successful to open table, even assign to
* Grid Recordsource!

with thisform
  .cbofield.rowsourcetype = 0
  .cbofield.rowsource = []
Select (alltrim(.cboTable.value))
  .cbofield.rowsourcetype = 8 && field
  .cbofield.rowsource = alltrim(.cboTable.value)
EndWith
>>
>>The above with cause coding do not work!!!!
>>But Work in Do Form Version!!! Why?!?!?!?
>>Any Suggestion or Precausion can I do?!
>>>_<"
>
>If you save a form with tables in the DE as a class, the class does not preserve the DE (.vcx forms have no DE). So when instanciating forms from vcxs, you have open the tables manually. You are being prompted for a table becuase there is no table in the form.

Pls see the above coding again. This is already the .Init Procedure!!
After I add that 'Select' line, everything work fine again!!

I wonder That CboField takes the Current Working Area into Field and ignore any change on .RowSource statement!!!!
So, on CboTable.INteractivechange, I also add the Select statement
before assign the rowsourcetype to 8!!!
Then, it work the same as 'Do Form' Version!

But I claim it is a VFP bug as some coding will be IGNORE!!
Just like the IMEMODE problem in Grid Control!!

This must make me cry if the program DO NOT WORK ACCORDING TO MY INSTRUCTION!
This problem is more worst than the #253 problem on listbox!!
The weak wait for chance, The strong bid for chance,
The clever notch up chance, but The merciful give you chance.
Previous
Reply
Map
View

Click here to load this message in the networking platform