Devon Posted March 20, 2018 Report Share Posted March 20, 2018 This is converted code from a project. It is a basic combo box loading routine. The cbo.RowSource is an MSDATASRC an the rst is the created / converted ADORecordSetHelper. They aren't compatible! Okay so what can I assign in code to make this work? Link to comment Share on other sites More sharing options...
Mobilize.Net Staff OlmanQuesada Posted March 21, 2018 Mobilize.Net Staff Report Share Posted March 21, 2018 Hi Devon, the cbo is a Activex Combobox, so it's not a .Net control. Because of that, the RowSource property cannot be assigned to a .Net class. At this point there are two alternatives: 1. Change the AxDataCombo by a .Net control. In that case it would be compatible with other .Net classes/components. This have to be done in a manual fashion as currently the VBUC does not automatically convert that control to a .Net one. 2. Migrate the vb6 code using ADODB via Com Interop (see attached file). By doing this, all classic adodb code willnot be converted to ADO.Net, so the cbo.RowSource and the rst object may be compatible. However, as you're converting your code to .Net my suggestion would be the option 1. Regards, OlmanQ Link to comment Share on other sites More sharing options...
Recommended Posts
Please sign in to comment
You will be able to leave a comment after signing in
Sign In Now