423,850 Members | 1,069 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 423,850 IT Pros & Developers. It's quick & easy.

run-time automation error library not registred

P: 8
I try to list the contents of folder by usinng the FileSystemObject Library the
run-time error '-2147319779(8002801d)'; automation error library not registred
is appears but i use the same application in another computer and its run
i check the reference microsoft scripting runtime
the code
Expand|Select|Wrap|Line Numbers
  1. Dim FSO As New FileSystemObject
  2. Dim FileInFolder As Files
  3. Dim FileName As File
  4. Dim I As Integer
  5. Dim FolderInPath As String
  6. Private Sub Command1_Click()
  7.  
  8.     Set FileInFolder = FSO.GetFolder("C:\Program Files\NowSMS\SMS-IN").Files
  9.  
  10.     For Each FileName In FileInFolder
  11.         List1.AddItem FileName
  12.         DoEvents
  13.     Next
  14.  
  15.     For I = 0 To List1.ListCount - 1
  16.           FolderInPath = Replace(List1.List(I), "C:\Program Files\NowSMS\SMS-IN\", App.Path & "\CopyOf(SMS-IN)\" & "(" & I & ")")
  17.           FSO.CopyFile List1.List(I), FolderInPath, False
  18.     Next I
  19.  
  20. End Sub
Jul 30 '07 #1
Share this Question
Share on Google+
4 Replies


Expert 5K+
P: 8,435
Perhaps the Microsoft Scripting Runtime library is not installed on the target computer?
Jul 31 '07 #2

P: 8
Perhaps the Microsoft Scripting Runtime library is not installed on the target computer?
its installed in the system32 (SCRRUN.DEP and scrrun.dll)
Jul 31 '07 #3

P: 8
thanks i find the problem its the library not registred and i used the (start => run)
(regsvr scrrun.dll) command to register the scrrun library

Deco
Jul 31 '07 #4

Expert 5K+
P: 8,435
thanks i find the problem its the library not registred and i used the (start => run)
(regsvr scrrun.dll) command to register the scrrun library
Great! Glad to hear you've got it sorted out.
Jul 31 '07 #5

Post your reply

Sign in to post your reply or Sign up for a free account.