Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
VB Form vs VBA UserForm problems...
I come from a VBA environment where I am used to doing things like
abstracting away UI elements like moving items in a listbox up or down with items... into some DLL that i make with a ListOrderer class which you use by passing references to the listbox control and all of the up/down buttons. Now that I am writing some things in VB6, I found that I cannot simply just export my VBA (designed in Excel) forms and import them into VB6 Forms. Why do these form objects appear in the "Designers" portion of the TreeView rather than the "Forms" portion. So, I started designing a VB6 form, and hoped that it could use the same ListOrderer class that I used in the VBA form. Unfortunately, VB6 does not use MSForms controls, but rather uses VB controls. VB controls have different methods, properties, etc! That is one problem I don't understand, but I can get over it. It means i'd have to design a new ListOrderer for VB6. So I did that. Unfortunately, it gave me an error saying that "A property or method call cannot include a reference to a private object, either as an argument or as a return value" when I made the arguments to the ListOrderer class VB.Listbox and VB.Button. So i simply changed them to Object and hoped it would work. However, it still doesn't work because when i try to use the ListOrderer (which is compiled in a separate DLL) in the Standard EXE Form i am trying to make, it gives me this error again. I looked online for some descriptions of the error and I found the following MSDN link: http://msdn.microsoft.com/library/de...ary/en-us/vbco... According to this, I can't pass VB controls to DLLs PERIOD! What is that? How do you guys abstract UI functionality like drag and drop items between two listboxes or automatically sync'ing a form's controls (with set tag properties) to a custom object's properties? Any help in response to any of my questions above would be greatly appreciated. Thanks. |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
VB Form vs VBA UserForm problems...
Hi,
Now that I am writing some things in VB6, I found that I cannot simply just export my VBA (designed in Excel) forms and import them into VB6 Forms. Why do these form objects appear in the "Designers" portion of the TreeView rather than the "Forms" portion. Instead of posting this to all the office development newsgroups, you might get a better response from the Visual Basic newsgroups, such as public.vb.controls Regards Stephen Bullen Microsoft MVP - Excel Professional Excel Development The most advanced Excel VBA book available www.oaltd.co.uk/ProExcelDev |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
VB Form vs VBA UserForm problems... | Excel Programming | |||
VB Form vs VBA UserForm problems... | Excel Programming | |||
userform problems | Excel Programming | |||
userform problems | Excel Programming | |||
userform problems | Excel Programming |