|
-
Mar 14th, 2001, 02:11 AM
#1
Thread Starter
Lively Member
Is it wise to use ActiveX DLL's to store information of a GUI? What I mean is, is it OK to store Forms in a DLL file and open them through methods?
If not, how about in Active X EXE's?
If still no, what would be the best way to store GUI's modularly so that when I want to update it, I do not have to change the whole thing?
thank you
-
Mar 14th, 2001, 08:56 AM
#2
Fanatic Member
Why not
I display forms in ActiveX DLL's all the time and don't have any problems.
What exactly are you concerned about?
-
Mar 14th, 2001, 07:15 PM
#3
Thread Starter
Lively Member
I get this error.
Title: Component Request Pending
An action cannot be completed because a component (whatever the DLL) is not responding. Choose "Switch To" to activate the component and correct the problem.
this is the code:
-> the DLL (Test.DLL)
' in the DLL, I have a form (Form1) and a class module (Module1)
'Form1
'I have 1 command button for Form1
Private Sub Command1_Click
msgBox ("Hello World")
End Sub
'Module1
Public Sub Show
Form1.Show
End Sub
-> the EXE Project
'I have 1 form ProjForm and 1 command button CommandProj
Private Sub CommandProj_Click
Dim Message As New Test.Module1
Message.Show
End Sub
Please help if you could.
* thanks *
-
Mar 14th, 2001, 11:42 PM
#4
Lively Member
manofprayer are u sure that u'r dll has been really converted to a file with the extension .dll ?...since sometimes it'll go for "make project" and even though u can refer it from a client form u'll get the error u have mentioned...so try again to convert it into dll and refer it again in the client side...all the best.
-
Mar 15th, 2001, 02:10 AM
#5
Fanatic Member
Modal
In your DLL you should instantiate Form1 rather than just showing it. Also, try showing it modally.
i.e.
Dim frm As Form1
Set frm = New Form1
frm.Show vbModal
-
Mar 15th, 2001, 02:52 AM
#6
Lively Member
There is no need for instancing the form since i tried the exact code of manofprayer and is working fine!!
-
Mar 15th, 2001, 03:02 AM
#7
Fanatic Member
Oh Contrare!
It's always a good idea to instantiate your forms so you always know when you use a form whether it is a new instance or a previously existing instance.
manofprayer,
Does your form eventually get displayed (even if you have to click on 'Switch To'? I only ask as there is a timeout setting which dictates how long a project waits for a response from a component after a request has been made. This defaults to 0 but can be changed...
I actually can't remember how to change it now but it can be done, honest!
-
Mar 15th, 2001, 05:56 PM
#8
Thread Starter
Lively Member
semi-Success!!!
first t answer your question:
- yes, when you click the 'Switch To ...' the Form does gets displayed.
something strange:
-when I tried it out at home, 'coz you said it works, I noticed something different from the properties of the DLL that I've created at the office and the one I did at home. I noticed that the 'Unattended Execution' check box is disabled at home (and to let you know, my program worked well at home) and here in the office it was enabled!
- do you have an answer for this?
thank you.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|