Buzzsaw Developer

Posts: 14
Registered: ‎02-02-2005
Message 1 of 1 (140 Views)

AddFile Method

140 Views, 0 Replies
01-19-2006 09:32 AM
Hi everybody,

I have seen several examples on how to use the AddFile method. I have tried using it with both the PPFILE and PPPROJECT objects unsucessfully. One difference I noticed between two examples was the use of the ServerLocation property. It is unclear whether this needs to be set on the PPFILE object. There is no documentation on this. I thought that if you are using PPFILE.AddFile or PPPROJECT.AddFile, the destination is know based on on their ServerLocation properties. Here is some sample code using both objects, does anyone have any ideas what's wrong?

Private Sub upload_test_Click()

Dim buzzsawSession As New PPSession
Dim buzzsawFolder As New PPFOLDER
Dim localFile As New PPFILE
Dim buzzawProject As New PPPROJECT

buzzsawSession.LogIn username.Text, password.Text, webfolders.Text ''' access values in controls on form

Set buzzsawFolder = buzzsawSession.GetResource("/southwest_region/colorado/archive") 'folder
Set buzzawProject = buzzsawSession.GetResource("/southwest_region/colorado") 'project

localFile.LocalPath = "t:\drawings\filelist.txt" = "filelist.txt"
localFile.ServerLocation = buzzawProject.ServerLocation + "archive" ''' have tried with and without BOOM no work!

buzzsawFolder.AddFile localFile 'CRASHES

localFile.ServerLocation = buzzawProject.ServerLocation

buzzawProject.AddFile localFile
buzzawProject.Upload 'CRASHES

Set buzzawProject = Nothing
Set buzzsawFolder = Nothing
Set localFile = Nothing

Set buzzsawSession = Nothing

End Sub


You are not logged in.

Log into access your profile, ask and answer questions, share ideas and more. Haven't signed up yet? Register

Welcome to the new Autodesk Community!
If this is your first visit, click here to get started and make the most of the Community. Let us know what you think of the new experience in the Community Feedback Forum.

Need installation help?

Start with some of our most frequented solutions to get help installing your software.

New Buzzsaw Category!

The Buzzsaw forum has moved into it's very own category page, and can no longer be found within the Additional Product Forums.

Ask the Community