Solved

MS Project 2003 Application.filesearch runtime error 1004

Posted on 2011-02-25
4
800 Views
Last Modified: 2013-11-15
I have a problem with MS project.
When running MS P local the application.filesearch works great.
But when running MSP via Citrix Atlas desktop it gives runtime error 1004?

Can anybody help?


Kind regards

Eric
Sub Realisation_Week_Schedule()
' Macro Realisation_Week_Schedule
' Macro Recorded Fri 15.01.10 14:45 by EUROPE\252218.
   Dim y As Variant
    Dim fLdr As String, Fil As String, FPath As String
     
    y = "Realisation*.xls"

    '**********************************************************************
     'fLdr = BrowseForFolderShell

        fLdr = "V:\Data\Livelink\" & Environ("UserName") & "\OTlocal\Livelink\Workbin"
    
     '**********************************************************************
    With Application.FileSearch
        .NewSearch
        .LookIn = fLdr
        .SearchSubFolders = True
        .FileName = y


        On Error GoTo 0
        If .Execute() > 0 Then
            For i = 1 To .FoundFiles.Count
                Fil = .FoundFiles(i)
                 'Get file path from file name
                FPath = Left(Fil, Len(Fil) - Len(Split(Fil, "\")(UBound(Split(Fil, "\")))) - 1)
                If Left$(Fil, 1) = Left$(fLdr, 1) Then
                    If CBool(Len(Dir(Fil))) Then Kill Fil
                
                End If
            Next i
        End If
    End With
     
  
    
    ViewApply Name:="01. SABIC Gantt Chart"
    FilterApply Name:="&All Tasks"
    OutlineShowAllTasks
    'CalculateAll
    ViewApply Name:="61. SABIC Realisation week schedule"
    SelectTaskColumn Column:="Work", Additional:=6
    EditCopy
    
Set objIEApp = CreateObject("InternetExplorer.Application")

objIEApp.Navigate "http://livelink.intranet.europe.sabic.com/Livelink/llisapi.dll?func=Edit.Edit&nodeid=96421372&nexturl=%2FLivelink%2Fllisapi%2Edll%3Ffunc%3Dll%26objId%3D96421372%26objAction%3Dbrowse%26sort%3Dname"

objIEApp.Visible = True

Set objIEApp = Nothing
    
End Sub

Open in new window

0
Comment
Question by:Eric Zwiekhorst
  • 2
4 Comments
 
LVL 19

Expert Comment

by:basraj
Comment Utility
Is it happening for all the users? If only one user, then please recreate the Citrix profile and check again.
0
 
LVL 6

Author Comment

by:Eric Zwiekhorst
Comment Utility
It is happening to all users
0
 
LVL 19

Accepted Solution

by:
basraj earned 500 total points
Comment Utility
I think the problem is Citrix server is not able to reach the files as you mentioned in above code. Can you try the code directly on the server and fix there first?
0

Featured Post

IT, Stop Being Called Into Every Meeting

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

Join & Write a Comment

At the beginning of the year, the IT world was taken hostage by the shareholders of LogMeIn. Their free product, which had been free for ten years, all of the sudden became a "pay" product. Now, I am the first person who will say that software maker…
Citrix XenDesktop 7.6 Citrix Policies Graphics
Learn how to create and modify your own paragraph styles in Microsoft Word. This can be helpful when wanting to make consistently referenced styles throughout a document or template.
Access reports are powerful and flexible. Learn how to create a query and then a grouped report using the wizard. Modify the report design after the wizard is done to make it look better. There will be another video to explain how to put the final p…

771 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

10 Experts available now in Live!

Get 1:1 Help Now