|
|
It need not be an HTTP URL. SMB file paths (\\server\share\file.txt or
c:\file.txt) are also supported with BITS 2.0. But the requirement is that
you need to pass the full path to the files. Relative paths are not
accepted.
http://msdn.microsoft.com/library/en-us/bits/bits/ibackgroundcopyjob_addfile.asp
--
Narayana Mahankali
Microsoft, BITS
This posting is provided "As Is" with no warranties, and confers no rights.
Use of included script samples are subject to the terms specified at
www.microsoft.com/info/cpyright.htm">http://www.microsoft.com/info/cpyright.htm
"Phil Wilson" <Phil.Wilson@xxxxxxxxxxxxxx> wrote in message
news:OC0ZdFqdFHA.796@xxxxxxxxxxxxxxxxxxxxxxx
> The code doesn't look right to me because the first parameter to AddFile
> is typically a URL (starting with http etc), but you're passing a
> filename. It can be a file URL, but you're talking about "remote" as if
> it's an internet connection.
> --
> Phil Wilson [MVP Windows Installer]
> ----
> "Mustafa B." <mbuyukkaya@xxxxxxxxx> wrote in message
> news:1118648397.201700.217590@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
>> Hi,
>> I am trying to transfer 2000+ tif documents from a remote file server.
>> When I try to add a file to the job I get an "The parameter is
>> incorrect" error. Any ideas,
>>
>> thanks in advance
>>
>> Mustafa.
>>
>> here is a snippet from my code:
>>
>> private void CreateJob(string jobName, string[] localFileName ,
>> string[] sourceFileName)
>> {
>> try
>> {
>> if(sourceFileName.Length > 0)
>> {
>> this._bitsjob = this._bitsman.CreateJob(jobName + " started at " +
>> DateTime.Now.ToString());
>>
>> // this._bitsjob.Priority = JobPriority.Foreground;
>> // this._bitsjob.NoProgressTimeout = this._job.NoProgressTimeout;
>> // this._bitsjob.MinimumRetryDelay = this._job.MinimumRetryDelay;
>>
>> for(int i=0;i<sourceFileName.Length;i++)
>> {
>> if(!this.DoesFileExists(localFileName[i]))
>> {
>> this._bitsjob.AddFile(localFileName[i],sourceFileName[i]);
>> }
>> }
>>
>> this._bitsjob.ResumeJob();
>> }
>> }
>> }
>>
>
>
|
|