Hi,
i have this problem...
after i install my program on a "clean" system, an error has occur after i press a "Open Button" on my program.
(ActiveX component can't create object(429))
"Open Button"
I have this file in my program..Code:Private Sub cmdOpen1_Click() On Error GoTo Error_Handler Dim strFileNames As Variant Dim i As Integer strFileNames = Split(GetFiles, Chr(0)) With List1 If UBound(strFileNames) > 0 Then Preview1.Caption = strFileNames(0) For i = 1 To UBound(strFileNames) List1.AddItem strFileNames(i) Next Else .AddItem strFileNames(0) End If End With With List12 If UBound(strFileNames) > 0 Then Preview1.Caption = strFileNames(0) For i = 1 To UBound(strFileNames) List12.AddItem strFileNames(0) Next Else .AddItem "" End If End With Error_Handler: Resume Next End Sub Public Function GetFiles(Optional ByVal sTitle As String = "Open files...") As String Dim sFilenames As String Dim cdlOpen As Object On Error GoTo ProcError Set cdlOpen = CreateObject("MSComDlg.CommonDialog") With cdlOpen .CancelError = True .Filter = "All Supported files (*.dat;*.avi;*.mp3;*.wav;*.mpg;*.wma;*.rmvb;*.m2p;*.wmv;*.mov;*.divx)|*.dat;*.avi;*.mp3;*.wav;*.mpg;*.wma;*.rmvb;*.m2p;*.wmv;*.mov;*.divx" .FilterIndex = 1 .DialogTitle = sTitle .MaxFileSize = &H7FFF .flags = &H4 Or &H800 Or &H40000 Or &H200 Or &H80000 .ShowOpen sFilenames = .FileName End With ProcExit: GetFiles = sFilenames Set cdlOpen = Nothing Exit Function ProcError: If Err.Number = &H7FF3 Then Resume Next MsgBox Err.Description & "(" & Err.Number & ")", vbExclamation, "Open error" sFilenames = "" Resume ProcExit End Function
ActiveX Control:
MSCOMCTL32.OCX
Comdlg32.ocx
MSCOMTL.OCX
COMCTL32.OCX
can some one tell me how to solve it?




Reply With Quote