INTERACT FORUM
Windows => Plug-in Development => Topic started by: RhinoBanga on December 07, 2003, 02:01:21 am
-
Getting an error in v9.1.315 when using MJFieldAutomation in C++ so I knocked up this small VB sample showing the problem.
Private Sub Form_Load()
Dim myMJ As MediaJukebox.MJAutomation
Set myMJ = GetObject(, "MediaJukebox Application")
If Err.Number = 429 Then
Set myMJ = CreateObject("MediaJukebox Application")
End If
Dim myFields As MediaJukebox.MJFieldsAutomation
Set myFields = myMJ.GetFields
Dim myField As MediaJukebox.MJFieldAutomation
For loop1 = 0 To myFields.GetNumberFields
Set myField = myFields.GetField(loop1)
MsgBox myField.GetName(True)
Next
End Sub
I get the following error when executing the MsgBox function:
Wrong number of arguments or invalid property assignment
Can anyone get this working?
If not can we have it fixed in v9.1 please.
-
Yeah - exact same crash here for me with the tester I just did :(
-
Is your MC TLB 18,432 bytes? (if not, grab the one from the next build)
-
It already is that size:
18.0 KB (18,432 bytes)
And the date is 14th/November/2003.
-
I just tried the functionality with the latest version of MC (10.0.73). It works on my computer. So, I updated the TLB file in MC's install directory.
Install next build of MC (10.0.74) to get the latest TLB file and please try again. It should work.
Regards,
Nikolay
-
I was getting the same problem with the Zones automation interface. It turned out that my computer had two copies of the "media center.tlb" file on it. The older one was registered and it did not have these newer interfaces defined.
I used a TLB registration utility from VBAccelerator (see link below) to manually select and register the TLB file located in the: "C:\Program Files\J River\Media Center " directory.
(FYI, the older TLB file on my system was in the: "C:\Program Files\J River\Media Jukebox" directory)
http://www.vbaccelerator.com/home/VB/Utilities/Type_Library_Registration_Utility/VB6_Register_TypeLib_Utility.asp (http://www.vbaccelerator.com/home/VB/Utilities/Type_Library_Registration_Utility/VB6_Register_TypeLib_Utility.asp)
Good Luck !
Thanks,
Robert