I checked with UInterger instead of integer, it doesn't change.
Here is my test code in VB :
Sub TestMC(ByVal SearchStr As String)
'==============
Dim MCA, MJVersion, MJPlaylists, MJSchList, MJFields, CurPLPtr, CurFilePtr, FileList As Object
Dim i, MJNbPlaylists, NbFilePlayList As UInteger
Dim Trouve As Boolean
Dim PLName, FLName, LName As String
' First try to get an already running Mediacenter
On Error Resume Next
MCA = GetObject(, "MediaJukebox Application")
If Err.Number = 429 Then
'Then, create a new Mediacenter
On Error GoTo 0
MCA = CreateObject("MediaJukebox Application")
Else
If Err.Number <> 0 Then
MsgBox("Erreur chargement MediaCenter #" + CStr(Err.Number) + " / " + Err.Description)
End If
End If
On Error GoTo 0
MJVersion = MCA.getversion()
'Put version in the VBForm
Form1.Version.Text = MJVersion.Version
MJFields = MCA.getFields()
'Put NbField in the VBForm
Form1.NbField.Text = MJFields.GetNumberFields
MJPlaylists = MCA.GetPlaylists()
'Put NbPlaylist in the VBForm
Form1.NbPlaylist.Text = MJPlaylists.GetNumberPlaylists()
MJNbPlaylists = MJPlaylists.GetNumberPlaylists()
CurPLPtr = MJPlaylists.GetPlaylist(0)
PLName = CurPLPtr.Name
FileList = CurPLPtr.GetFiles()
NbFilePlayList = FileList.GetNumberFiles()
'check if GetFile works with 0
CurFilePtr = FileList.GetFile(0)
FLName = CurFilePtr.Name
'check if GetFile works with i = 0
i = 0
CurFilePtr = FileList.GetFile(i)
FLName = CurFilePtr.Name
'check if GetPlaylist works with 0
CurPLPtr = MJPlaylists.GetPlaylist(0)
LName = CurPLPtr.Name
'check if GetPlaylist works with i = 0
i = 0
Trouve = False
Do
CurPLPtr = MJPlaylists.GetPlaylist(i)
If CurPLPtr.Name = "NeedInfoDB" Then Trouve = True
i = i + 1
Loop Until i = MJNbPlaylists - 1 Or Trouve
MJSchList = MCA.Search(SearchStr)
'Put GetNumberFiles of Search in the VBForm
Form1.NbTrouve.Text = MJSchList.GetNumberFiles()
End Sub