<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Error while copying content to a stream in C# in Discuss Dropbox Developer &amp; API</title>
    <link>https://www.dropboxforum.com/t5/Discuss-Dropbox-Developer-API/Error-while-copying-content-to-a-stream-in-C/m-p/713156#M3618</link>
    <description>&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Rephoto_0-1694539131433.png" style="width: 400px;"&gt;&lt;img src="https://www.dropboxforum.com/t5/image/serverpage/image-id/40475i5533CE5ECD5D78B3/image-size/medium?v=v2&amp;amp;px=400" role="button" title="Rephoto_0-1694539131433.png" alt="Rephoto_0-1694539131433.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;I changed the code and there weren't any errors but the Entries returned all had a status of fales.&lt;BR /&gt;Can you tell me where I'm going wrong?&lt;BR /&gt;Thanks&lt;/P&gt;</description>
    <pubDate>Tue, 12 Sep 2023 17:19:19 GMT</pubDate>
    <dc:creator>Rephoto</dc:creator>
    <dc:date>2023-09-12T17:19:19Z</dc:date>
    <item>
      <title>Error while copying content to a stream in C#</title>
      <link>https://www.dropboxforum.com/t5/Discuss-Dropbox-Developer-API/Error-while-copying-content-to-a-stream-in-C/m-p/713028#M3608</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;PRE&gt;&lt;SPAN class=""&gt;I encountered the problem "Error while copying content to a stream" when executing the above code. Is there any way to fix it?&lt;/SPAN&gt;&lt;/PRE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;try&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &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gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;/SPAN&gt;&lt;SPAN&gt;byte&lt;/SPAN&gt;&lt;SPAN&gt;[] &lt;/SPAN&gt;&lt;SPAN&gt;buffer&lt;/SPAN&gt; &lt;SPAN&gt;=&lt;/SPAN&gt; &lt;SPAN&gt;new&lt;/SPAN&gt; &lt;SPAN&gt;byte&lt;/SPAN&gt;&lt;SPAN&gt;[&lt;/SPAN&gt;&lt;SPAN&gt;chunkSize&lt;/SPAN&gt;&lt;SPAN&gt;];&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;/SPAN&gt;&lt;SPAN&gt;string&lt;/SPAN&gt; &lt;SPAN&gt;sessionId&lt;/SPAN&gt; &lt;SPAN&gt;=&lt;/SPAN&gt; &lt;SPAN&gt;null&lt;/SPAN&gt;&lt;SPAN&gt;;&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;/SPAN&gt;&lt;SPAN&gt;var&lt;/SPAN&gt; &lt;SPAN&gt;tasks&lt;/SPAN&gt; &lt;SPAN&gt;=&lt;/SPAN&gt; &lt;SPAN&gt;new&lt;/SPAN&gt; &lt;SPAN&gt;List&lt;/SPAN&gt;&lt;SPAN&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN&gt;Task&lt;/SPAN&gt;&lt;SPAN&gt;&amp;gt;();&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;/SPAN&gt;&lt;SPAN&gt;for&lt;/SPAN&gt;&lt;SPAN&gt; (&lt;/SPAN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/SPAN&gt;&lt;SPAN&gt;using&lt;/SPAN&gt; &lt;SPAN&gt;var&lt;/SPAN&gt; &lt;SPAN&gt;memStream&lt;/SPAN&gt; &lt;SPAN&gt;=&lt;/SPAN&gt; &lt;SPAN&gt;new&lt;/SPAN&gt; &lt;SPAN&gt;MemoryStream&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;buffer&lt;/SPAN&gt;&lt;SPAN&gt;, &lt;/SPAN&gt;&lt;SPAN&gt;0&lt;/SPAN&gt;&lt;SPAN&gt;, &lt;/SPAN&gt;&lt;SPAN&gt;byteRead&lt;/SPAN&gt;&lt;SPAN&gt;);&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;/SPAN&gt;&lt;SPAN&gt;if&lt;/SPAN&gt;&lt;SPAN&gt; (&lt;/SPAN&gt;&lt;SPAN&gt;idx&lt;/SPAN&gt; &lt;SPAN&gt;==&lt;/SPAN&gt; &lt;SPAN&gt;0&lt;/SPAN&gt;&lt;SPAN&gt;)&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; {&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;/SPAN&gt;&lt;SPAN&gt;var&lt;/SPAN&gt; &lt;SPAN&gt;result&lt;/SPAN&gt; &lt;SPAN&gt;=&lt;/SPAN&gt; &lt;SPAN&gt;await&lt;/SPAN&gt; &lt;SPAN&gt;_client&lt;/SPAN&gt;&lt;SPAN&gt;.&lt;/SPAN&gt;&lt;SPAN&gt;Files&lt;/SPAN&gt;&lt;SPAN&gt;.&lt;/SPAN&gt;&lt;SPAN&gt;UploadSessionStartAsync&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;body&lt;/SPAN&gt;&lt;SPAN&gt;: &lt;/SPAN&gt;&lt;SPAN&gt;memStream&lt;/SPAN&gt;&lt;SPAN&gt;);&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;/SPAN&gt;&lt;SPAN&gt;sessionId&lt;/SPAN&gt; &lt;SPAN&gt;=&lt;/SPAN&gt; &lt;SPAN&gt;result&lt;/SPAN&gt;&lt;SPAN&gt;.&lt;/SPAN&gt;&lt;SPAN&gt;SessionId&lt;/SPAN&gt;&lt;SPAN&gt;;&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; }&lt;/SPAN&gt;&lt;/DIV&gt;&lt;BR /&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;/SPAN&gt;&lt;SPAN&gt;else&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; {&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;/SPAN&gt;&lt;SPAN&gt;var&lt;/SPAN&gt; &lt;SPAN&gt;cursor&lt;/SPAN&gt; &lt;SPAN&gt;=&lt;/SPAN&gt; &lt;SPAN&gt;new&lt;/SPAN&gt; &lt;SPAN&gt;UploadSessionCursor&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;sessionId&lt;/SPAN&gt;&lt;SPAN&gt;, (&lt;/SPAN&gt;&lt;SPAN&gt;ulong&lt;/SPAN&gt;&lt;SPAN&gt;)(&lt;/SPAN&gt;&lt;SPAN&gt;chunkSize&lt;/SPAN&gt; &lt;SPAN&gt;*&lt;/SPAN&gt; &lt;SPAN&gt;idx&lt;/SPAN&gt;&lt;SPAN&gt;));&lt;/SPAN&gt;&lt;/DIV&gt;&lt;BR /&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;/SPAN&gt;&lt;SPAN&gt;if&lt;/SPAN&gt;&lt;SPAN&gt; (&lt;/SPAN&gt;&lt;SPAN&gt;idx&lt;/SPAN&gt; &lt;SPAN&gt;==&lt;/SPAN&gt; &lt;SPAN&gt;numChunks&lt;/SPAN&gt; &lt;SPAN&gt;-&lt;/SPAN&gt; &lt;SPAN&gt;1&lt;/SPAN&gt;&lt;SPAN&gt;)&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; {&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;/SPAN&gt;&lt;SPAN&gt;await&lt;/SPAN&gt; &lt;SPAN&gt;Task&lt;/SPAN&gt;&lt;SPAN&gt;.&lt;/SPAN&gt;&lt;SPAN&gt;WhenAll&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;tasks&lt;/SPAN&gt;&lt;SPAN&gt;);&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;/SPAN&gt;&lt;SPAN&gt;await&lt;/SPAN&gt; &lt;SPAN&gt;_client&lt;/SPAN&gt;&lt;SPAN&gt;.&lt;/SPAN&gt;&lt;SPAN&gt;Files&lt;/SPAN&gt;&lt;SPAN&gt;.&lt;/SPAN&gt;&lt;SPAN&gt;UploadSessionFinishAsync&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;cursor&lt;/SPAN&gt;&lt;SPAN&gt;, &lt;/SPAN&gt;&lt;SPAN&gt;new&lt;/SPAN&gt; &lt;SPAN&gt;CommitInfo&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;toPathDropbox&lt;/SPAN&gt;&lt;SPAN&gt;), &lt;/SPAN&gt;&lt;SPAN&gt;body&lt;/SPAN&gt;&lt;SPAN&gt;: &lt;/SPAN&gt;&lt;SPAN&gt;memStream&lt;/SPAN&gt;&lt;SPAN&gt;);&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; }&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;/SPAN&gt;&lt;SPAN&gt;else&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; {&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;/SPAN&gt;&lt;SPAN&gt;tasks&lt;/SPAN&gt;&lt;SPAN&gt;.&lt;/SPAN&gt;&lt;SPAN&gt;Add&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;_client&lt;/SPAN&gt;&lt;SPAN&gt;.&lt;/SPAN&gt;&lt;SPAN&gt;Files&lt;/SPAN&gt;&lt;SPAN&gt;.&lt;/SPAN&gt;&lt;SPAN&gt;UploadSessionAppendV2Async&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;cursor&lt;/SPAN&gt;&lt;SPAN&gt;, &lt;/SPAN&gt;&lt;SPAN&gt;body&lt;/SPAN&gt;&lt;SPAN&gt;: &lt;/SPAN&gt;&lt;SPAN&gt;memStream&lt;/SPAN&gt;&lt;SPAN&gt;));&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp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p;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; }&lt;/SPAN&gt;&lt;/DIV&gt;&lt;/DIV&gt;</description>
      <pubDate>Tue, 12 Sep 2023 09:54:11 GMT</pubDate>
      <guid>https://www.dropboxforum.com/t5/Discuss-Dropbox-Developer-API/Error-while-copying-content-to-a-stream-in-C/m-p/713028#M3608</guid>
      <dc:creator>Rephoto</dc:creator>
      <dc:date>2023-09-12T09:54:11Z</dc:date>
    </item>
    <item>
      <title>Re: Error while copying content to a stream in C#</title>
      <link>https://www.dropboxforum.com/t5/Discuss-Dropbox-Developer-API/Error-while-copying-content-to-a-stream-in-C/m-p/713086#M3609</link>
      <description>&lt;P&gt;What line is that occurring on? Please print the full exception and stack trace for reference.&lt;/P&gt;</description>
      <pubDate>Tue, 12 Sep 2023 14:15:18 GMT</pubDate>
      <guid>https://www.dropboxforum.com/t5/Discuss-Dropbox-Developer-API/Error-while-copying-content-to-a-stream-in-C/m-p/713086#M3609</guid>
      <dc:creator>Greg-DB</dc:creator>
      <dc:date>2023-09-12T14:15:18Z</dc:date>
    </item>
    <item>
      <title>Re: Error while copying content to a stream in C#</title>
      <link>https://www.dropboxforum.com/t5/Discuss-Dropbox-Developer-API/Error-while-copying-content-to-a-stream-in-C/m-p/713111#M3610</link>
      <description>&lt;P&gt;I get an error on this line: &lt;SPAN class=""&gt;"await Task.WhenAll(tasks);"&lt;BR /&gt;&lt;/SPAN&gt;Is there any way fix it?&lt;BR /&gt;Thanks&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Rephoto_0-1694531520382.png" style="width: 400px;"&gt;&lt;img src="https://www.dropboxforum.com/t5/image/serverpage/image-id/40468iD8C156D4CD5F8F76/image-size/medium?v=v2&amp;amp;px=400" role="button" title="Rephoto_0-1694531520382.png" alt="Rephoto_0-1694531520382.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 12 Sep 2023 15:15:26 GMT</pubDate>
      <guid>https://www.dropboxforum.com/t5/Discuss-Dropbox-Developer-API/Error-while-copying-content-to-a-stream-in-C/m-p/713111#M3610</guid>
      <dc:creator>Rephoto</dc:creator>
      <dc:date>2023-09-12T15:15:26Z</dc:date>
    </item>
    <item>
      <title>Re: Error while copying content to a stream in C#</title>
      <link>https://www.dropboxforum.com/t5/Discuss-Dropbox-Developer-API/Error-while-copying-content-to-a-stream-in-C/m-p/713114#M3611</link>
      <description>&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Rephoto_0-1694531911221.png" style="width: 400px;"&gt;&lt;img src="https://www.dropboxforum.com/t5/image/serverpage/image-id/40469i2BFB8A7E0D594DE1/image-size/medium?v=v2&amp;amp;px=400" role="button" title="Rephoto_0-1694531911221.png" alt="Rephoto_0-1694531911221.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;This is another error you may encounter&lt;/P&gt;</description>
      <pubDate>Tue, 12 Sep 2023 15:19:08 GMT</pubDate>
      <guid>https://www.dropboxforum.com/t5/Discuss-Dropbox-Developer-API/Error-while-copying-content-to-a-stream-in-C/m-p/713114#M3611</guid>
      <dc:creator>Rephoto</dc:creator>
      <dc:date>2023-09-12T15:19:08Z</dc:date>
    </item>
    <item>
      <title>Re: Error while copying content to a stream in C#</title>
      <link>https://www.dropboxforum.com/t5/Discuss-Dropbox-Developer-API/Error-while-copying-content-to-a-stream-in-C/m-p/713127#M3612</link>
      <description>&lt;P&gt;Thanks for sharing the additional information. It looks like this is related to you trying to start multiple tasks within the loop without awaiting them, leading to the stream being closed (due to the iteration continuing and moving on to the next piece of the file) before it can be used.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Exactly how you structure your code/tasks is up to you, but to get this working I suggest awaiting each append task, instead of using tasks.Add and Task.WhenAll.&lt;/P&gt;</description>
      <pubDate>Tue, 12 Sep 2023 15:53:17 GMT</pubDate>
      <guid>https://www.dropboxforum.com/t5/Discuss-Dropbox-Developer-API/Error-while-copying-content-to-a-stream-in-C/m-p/713127#M3612</guid>
      <dc:creator>Greg-DB</dc:creator>
      <dc:date>2023-09-12T15:53:17Z</dc:date>
    </item>
    <item>
      <title>Re: Error while copying content to a stream in C#</title>
      <link>https://www.dropboxforum.com/t5/Discuss-Dropbox-Developer-API/Error-while-copying-content-to-a-stream-in-C/m-p/713128#M3613</link>
      <description>&lt;P&gt;Hi &lt;a href="https://www.dropboxforum.com/t5/user/viewprofilepage/user-id/1744622"&gt;@Rephoto&lt;/a&gt;,&lt;/P&gt;&lt;P&gt;When you're starting upload session, you use the default type - sequential session, but when actual upload gets on you're trying concurrent upload. Decide what you want actually.&lt;/P&gt;&lt;P&gt;Hope this gives direction.&lt;/P&gt;</description>
      <pubDate>Tue, 12 Sep 2023 15:53:48 GMT</pubDate>
      <guid>https://www.dropboxforum.com/t5/Discuss-Dropbox-Developer-API/Error-while-copying-content-to-a-stream-in-C/m-p/713128#M3613</guid>
      <dc:creator>Здравко</dc:creator>
      <dc:date>2023-09-12T15:53:48Z</dc:date>
    </item>
    <item>
      <title>Re: Error while copying content to a stream in C#</title>
      <link>https://www.dropboxforum.com/t5/Discuss-Dropbox-Developer-API/Error-while-copying-content-to-a-stream-in-C/m-p/713131#M3614</link>
      <description>&lt;P&gt;I want to increase their upload speed, is there any other way? Thanks&lt;/P&gt;</description>
      <pubDate>Tue, 12 Sep 2023 15:56:18 GMT</pubDate>
      <guid>https://www.dropboxforum.com/t5/Discuss-Dropbox-Developer-API/Error-while-copying-content-to-a-stream-in-C/m-p/713131#M3614</guid>
      <dc:creator>Rephoto</dc:creator>
      <dc:date>2023-09-12T15:56:18Z</dc:date>
    </item>
    <item>
      <title>Re: Error while copying content to a stream in C#</title>
      <link>https://www.dropboxforum.com/t5/Discuss-Dropbox-Developer-API/Error-while-copying-content-to-a-stream-in-C/m-p/713134#M3616</link>
      <description>&lt;P&gt;&lt;a href="https://www.dropboxforum.com/t5/user/viewprofilepage/user-id/1744622"&gt;@Rephoto&lt;/a&gt;, Start concurrent upload session and upload every peace of data in its own context (so no any reference gets lost). &lt;img class="lia-deferred-image lia-image-emoji" src="https://www.dropboxforum.com/html/@41457EF40051AFF130FDBFE21B496926/emoticons/1f609.png" alt=":winking_face:" title=":winking_face:" /&gt;&lt;/P&gt;&lt;P&gt;Good luck.&lt;/P&gt;</description>
      <pubDate>Tue, 12 Sep 2023 16:01:10 GMT</pubDate>
      <guid>https://www.dropboxforum.com/t5/Discuss-Dropbox-Developer-API/Error-while-copying-content-to-a-stream-in-C/m-p/713134#M3616</guid>
      <dc:creator>Здравко</dc:creator>
      <dc:date>2023-09-12T16:01:10Z</dc:date>
    </item>
    <item>
      <title>Re: Error while copying content to a stream in C#</title>
      <link>https://www.dropboxforum.com/t5/Discuss-Dropbox-Developer-API/Error-while-copying-content-to-a-stream-in-C/m-p/713137#M3617</link>
      <description>&lt;P&gt;&lt;a href="https://www.dropboxforum.com/t5/user/viewprofilepage/user-id/1744622"&gt;@Rephoto&lt;/a&gt; If you wish to optimize your upload process, please refer to the Performance Guide: &lt;A href="https://developers.dropbox.com/dbx-performance-guide" target="_blank"&gt;https://developers.dropbox.com/dbx-performance-guide&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;That offers some ways you may be able to improve your effective overall upload speed. For example, there are batching and parallelization features you can use.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;For instance, as Здравко noted, the default upload session type is "sequential", but you can use "concurrent" to upload file pieces in parallel. That would require you to make some more changes to your code to properly send those pieces in parallel though.&lt;/P&gt;</description>
      <pubDate>Tue, 12 Sep 2023 16:03:53 GMT</pubDate>
      <guid>https://www.dropboxforum.com/t5/Discuss-Dropbox-Developer-API/Error-while-copying-content-to-a-stream-in-C/m-p/713137#M3617</guid>
      <dc:creator>Greg-DB</dc:creator>
      <dc:date>2023-09-12T16:03:53Z</dc:date>
    </item>
    <item>
      <title>Re: Error while copying content to a stream in C#</title>
      <link>https://www.dropboxforum.com/t5/Discuss-Dropbox-Developer-API/Error-while-copying-content-to-a-stream-in-C/m-p/713156#M3618</link>
      <description>&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Rephoto_0-1694539131433.png" style="width: 400px;"&gt;&lt;img src="https://www.dropboxforum.com/t5/image/serverpage/image-id/40475i5533CE5ECD5D78B3/image-size/medium?v=v2&amp;amp;px=400" role="button" title="Rephoto_0-1694539131433.png" alt="Rephoto_0-1694539131433.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;I changed the code and there weren't any errors but the Entries returned all had a status of fales.&lt;BR /&gt;Can you tell me where I'm going wrong?&lt;BR /&gt;Thanks&lt;/P&gt;</description>
      <pubDate>Tue, 12 Sep 2023 17:19:19 GMT</pubDate>
      <guid>https://www.dropboxforum.com/t5/Discuss-Dropbox-Developer-API/Error-while-copying-content-to-a-stream-in-C/m-p/713156#M3618</guid>
      <dc:creator>Rephoto</dc:creator>
      <dc:date>2023-09-12T17:19:19Z</dc:date>
    </item>
    <item>
      <title>Re: Error while copying content to a stream in C#</title>
      <link>https://www.dropboxforum.com/t5/Discuss-Dropbox-Developer-API/Error-while-copying-content-to-a-stream-in-C/m-p/713161#M3619</link>
      <description>&lt;P&gt;&lt;a href="https://www.dropboxforum.com/t5/user/viewprofilepage/user-id/1744622"&gt;@Rephoto&lt;/a&gt;, What are you doing? Batch is used when you want to upload multiple files at once, not to split one file upload and do pieces upload simultaneous!!! Use concurrent upload session to do that.&lt;/P&gt;</description>
      <pubDate>Tue, 12 Sep 2023 17:28:53 GMT</pubDate>
      <guid>https://www.dropboxforum.com/t5/Discuss-Dropbox-Developer-API/Error-while-copying-content-to-a-stream-in-C/m-p/713161#M3619</guid>
      <dc:creator>Здравко</dc:creator>
      <dc:date>2023-09-12T17:28:53Z</dc:date>
    </item>
    <item>
      <title>Re: Error while copying content to a stream in C#</title>
      <link>https://www.dropboxforum.com/t5/Discuss-Dropbox-Developer-API/Error-while-copying-content-to-a-stream-in-C/m-p/713164#M3620</link>
      <description>&lt;P&gt;Oh sorry,&lt;BR /&gt;I will investigate further :((&lt;/P&gt;</description>
      <pubDate>Tue, 12 Sep 2023 17:31:55 GMT</pubDate>
      <guid>https://www.dropboxforum.com/t5/Discuss-Dropbox-Developer-API/Error-while-copying-content-to-a-stream-in-C/m-p/713164#M3620</guid>
      <dc:creator>Rephoto</dc:creator>
      <dc:date>2023-09-12T17:31:55Z</dc:date>
    </item>
    <item>
      <title>Re: Error while copying content to a stream in C#</title>
      <link>https://www.dropboxforum.com/t5/Discuss-Dropbox-Developer-API/Error-while-copying-content-to-a-stream-in-C/m-p/713269#M3622</link>
      <description>&lt;P&gt;&lt;a href="https://www.dropboxforum.com/t5/user/viewprofilepage/user-id/422790"&gt;@Здравко&lt;/a&gt;Hi, I tried again with the code below to upload small files (e.g. 10, 20MB). But the result just failed. :))&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Rephoto_0-1694572154700.png" style="width: 400px;"&gt;&lt;img src="https://www.dropboxforum.com/t5/image/serverpage/image-id/40483i771B9E1F04DD21E7/image-size/medium?v=v2&amp;amp;px=400" role="button" title="Rephoto_0-1694572154700.png" alt="Rephoto_0-1694572154700.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 13 Sep 2023 02:31:22 GMT</pubDate>
      <guid>https://www.dropboxforum.com/t5/Discuss-Dropbox-Developer-API/Error-while-copying-content-to-a-stream-in-C/m-p/713269#M3622</guid>
      <dc:creator>Rephoto</dc:creator>
      <dc:date>2023-09-13T02:31:22Z</dc:date>
    </item>
    <item>
      <title>Re: Error while copying content to a stream in C#</title>
      <link>https://www.dropboxforum.com/t5/Discuss-Dropbox-Developer-API/Error-while-copying-content-to-a-stream-in-C/m-p/713353#M3623</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://www.dropboxforum.com/t5/user/viewprofilepage/user-id/1744622"&gt;@Rephoto&lt;/a&gt;&amp;nbsp;wrote:&lt;BR /&gt;&lt;P&gt;&lt;a href="https://www.dropboxforum.com/t5/user/viewprofilepage/user-id/422790"&gt;@Здравко&lt;/a&gt;Hi, I tried again with the code below to &lt;FONT color="#008000"&gt;&lt;STRONG&gt;upload&lt;/STRONG&gt;&lt;/FONT&gt; small files (e.g. 10, 20MB). But the result just failed. :))&lt;/P&gt;&lt;P&gt;...&lt;/P&gt;&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;Hm..&lt;img class="lia-deferred-image lia-image-emoji" src="https://www.dropboxforum.com/html/@9AD39CA637682E9616FBE31CDAF1B6C4/emoticons/1f914.png" alt=":thinking_face:" title=":thinking_face:" /&gt; Probably I miss something, but where in your code you did upload files actually? 🧐 I cannot figure out where is this place/codeline. Please point out where you pass your files content to. Also don't forget that you should close every single session before finishing - so to be ready for finish! &lt;img class="lia-deferred-image lia-image-emoji" src="https://www.dropboxforum.com/html/@41457EF40051AFF130FDBFE21B496926/emoticons/1f609.png" alt=":winking_face:" title=":winking_face:" /&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Add: When you have some error, don't forget to post the actual error/unexpected result content too. There is valuable information describing the error.&lt;/P&gt;</description>
      <pubDate>Wed, 13 Sep 2023 12:17:11 GMT</pubDate>
      <guid>https://www.dropboxforum.com/t5/Discuss-Dropbox-Developer-API/Error-while-copying-content-to-a-stream-in-C/m-p/713353#M3623</guid>
      <dc:creator>Здравко</dc:creator>
      <dc:date>2023-09-13T12:17:11Z</dc:date>
    </item>
    <item>
      <title>Re: Error while copying content to a stream in C#</title>
      <link>https://www.dropboxforum.com/t5/Discuss-Dropbox-Developer-API/Error-while-copying-content-to-a-stream-in-C/m-p/713392#M3624</link>
      <description>&lt;P&gt;&lt;a href="https://www.dropboxforum.com/t5/user/viewprofilepage/user-id/422790"&gt;@Здравко&lt;/a&gt;&amp;nbsp;&lt;BR /&gt;Oh, So I'm missing the file upload part. But I don't know which one to use?&lt;/P&gt;</description>
      <pubDate>Wed, 13 Sep 2023 14:38:08 GMT</pubDate>
      <guid>https://www.dropboxforum.com/t5/Discuss-Dropbox-Developer-API/Error-while-copying-content-to-a-stream-in-C/m-p/713392#M3624</guid>
      <dc:creator>Rephoto</dc:creator>
      <dc:date>2023-09-13T14:38:08Z</dc:date>
    </item>
    <item>
      <title>Re: Error while copying content to a stream in C#</title>
      <link>https://www.dropboxforum.com/t5/Discuss-Dropbox-Developer-API/Error-while-copying-content-to-a-stream-in-C/m-p/713401#M3625</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://www.dropboxforum.com/t5/user/viewprofilepage/user-id/1744622"&gt;@Rephoto&lt;/a&gt;&amp;nbsp;wrote:&lt;BR /&gt;&lt;P&gt;&lt;a href="https://www.dropboxforum.com/t5/user/viewprofilepage/user-id/422790"&gt;@Здравко&lt;/a&gt;&amp;nbsp;&lt;BR /&gt;Oh, So I'm missing the file upload part. But I don't know which one to use?&lt;/P&gt;&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;In general, you should use&amp;nbsp;&lt;A title="Append more data to an upload session" href="https://dropbox.github.io/dropbox-sdk-dotnet/gh-pages/obj/api/Dropbox.Api.Files.Routes.FilesUserRoutes.html#Dropbox_Api_Files_Routes_FilesUserRoutes_UploadSessionAppendV2Async_Dropbox_Api_Files_UploadSessionCursor_System_Boolean_System_String_System_IO_Stream_" target="_blank" rel="noopener"&gt;UploadSessionAppendV2Async&lt;/A&gt; method to upload stream' data. In such case you can combine the batch with big files upload either sequential or concurrent. When you know that only small files are going to upload, using single call of&amp;nbsp;UploadSessionStartAsync to prepare a session (together with data upload and close) may be more suitable (instead of using UploadSessionStartBatchAsync - neither data can be uploaded nor closing it).&lt;/P&gt;&lt;P&gt;Let's hope this clarifies matter.&lt;/P&gt;</description>
      <pubDate>Wed, 13 Sep 2023 15:01:54 GMT</pubDate>
      <guid>https://www.dropboxforum.com/t5/Discuss-Dropbox-Developer-API/Error-while-copying-content-to-a-stream-in-C/m-p/713401#M3625</guid>
      <dc:creator>Здравко</dc:creator>
      <dc:date>2023-09-13T15:01:54Z</dc:date>
    </item>
    <item>
      <title>Re: Error while copying content to a stream in C#</title>
      <link>https://www.dropboxforum.com/t5/Discuss-Dropbox-Developer-API/Error-while-copying-content-to-a-stream-in-C/m-p/713426#M3626</link>
      <description>&lt;P&gt;&lt;a href="https://www.dropboxforum.com/t5/user/viewprofilepage/user-id/422790"&gt;@Здравко&lt;/a&gt;, Thank &lt;img class="lia-deferred-image lia-image-emoji" src="https://www.dropboxforum.com/html/@EFBB0D9BEFBFC06F5ACF7F310FB3A68B/emoticons/1f60d.png" alt=":smiling_face_with_heart_eyes:" title=":smiling_face_with_heart_eyes:" /&gt;&lt;BR /&gt;Can I do it like this? But it gives me an exception ""Error while copying content to a stream." arrival&lt;/P&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;await&lt;/SPAN&gt; &lt;SPAN&gt;_client&lt;/SPAN&gt;&lt;SPAN&gt;.&lt;/SPAN&gt;&lt;SPAN&gt;Files&lt;/SPAN&gt;&lt;SPAN&gt;.&lt;/SPAN&gt;&lt;SPAN&gt;UploadSessionFinishAsync&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;finish&lt;/SPAN&gt;&lt;SPAN&gt;, &lt;/SPAN&gt;&lt;SPAN&gt;memStream&lt;/SPAN&gt;&lt;SPAN&gt;);&lt;/SPAN&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Rephoto_0-1694620928952.png" style="width: 400px;"&gt;&lt;img src="https://www.dropboxforum.com/t5/image/serverpage/image-id/40494i3FD4EDEA19BBA090/image-size/medium?v=v2&amp;amp;px=400" role="button" title="Rephoto_0-1694620928952.png" alt="Rephoto_0-1694620928952.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 13 Sep 2023 16:03:54 GMT</pubDate>
      <guid>https://www.dropboxforum.com/t5/Discuss-Dropbox-Developer-API/Error-while-copying-content-to-a-stream-in-C/m-p/713426#M3626</guid>
      <dc:creator>Rephoto</dc:creator>
      <dc:date>2023-09-13T16:03:54Z</dc:date>
    </item>
    <item>
      <title>Re: Error while copying content to a stream in C#</title>
      <link>https://www.dropboxforum.com/t5/Discuss-Dropbox-Developer-API/Error-while-copying-content-to-a-stream-in-C/m-p/713428#M3627</link>
      <description>&lt;P&gt;&lt;a href="https://www.dropboxforum.com/t5/user/viewprofilepage/user-id/1744622"&gt;@Rephoto&lt;/a&gt;, Why are you trying to upload the same stream twice? &lt;img class="lia-deferred-image lia-image-emoji" src="https://www.dropboxforum.com/html/@9AD39CA637682E9616FBE31CDAF1B6C4/emoticons/1f914.png" alt=":thinking_face:" title=":thinking_face:" /&gt; Previously you skipped upload at all, now just opposite! &lt;img class="lia-deferred-image lia-image-emoji" src="https://www.dropboxforum.com/html/@FBF7D2AB59A0D6E861EBF6A36F93B7E2/emoticons/1f642.png" alt=":slightly_smiling_face:" title=":slightly_smiling_face:" /&gt;&lt;/P&gt;&lt;P&gt;Something else: Why you skipped finishing the all sessions in batch? In such a way, there is no optimization! Even more - you can do the same with a single call. &lt;img class="lia-deferred-image lia-image-emoji" src="https://www.dropboxforum.com/html/@41457EF40051AFF130FDBFE21B496926/emoticons/1f609.png" alt=":winking_face:" title=":winking_face:" /&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 13 Sep 2023 16:10:30 GMT</pubDate>
      <guid>https://www.dropboxforum.com/t5/Discuss-Dropbox-Developer-API/Error-while-copying-content-to-a-stream-in-C/m-p/713428#M3627</guid>
      <dc:creator>Здравко</dc:creator>
      <dc:date>2023-09-13T16:10:30Z</dc:date>
    </item>
    <item>
      <title>Re: Error while copying content to a stream in C#</title>
      <link>https://www.dropboxforum.com/t5/Discuss-Dropbox-Developer-API/Error-while-copying-content-to-a-stream-in-C/m-p/713433#M3628</link>
      <description>&lt;P&gt;Why are you trying to upload the same stream twice?&lt;/P&gt;&lt;P&gt;Previously you skipped upload at all, now just opposite!&lt;BR /&gt;...&lt;BR /&gt;&lt;a href="https://www.dropboxforum.com/t5/user/viewprofilepage/user-id/422790"&gt;@Здравко&lt;/a&gt;&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;So after I run the UploadSessionStartAsync command, how do I finish uploading to dropbox? &lt;img class="lia-deferred-image lia-image-emoji" src="https://www.dropboxforum.com/html/@9AD39CA637682E9616FBE31CDAF1B6C4/emoticons/1f914.png" alt=":thinking_face:" title=":thinking_face:" /&gt; Thanks&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 13 Sep 2023 16:22:49 GMT</pubDate>
      <guid>https://www.dropboxforum.com/t5/Discuss-Dropbox-Developer-API/Error-while-copying-content-to-a-stream-in-C/m-p/713433#M3628</guid>
      <dc:creator>Rephoto</dc:creator>
      <dc:date>2023-09-13T16:22:49Z</dc:date>
    </item>
    <item>
      <title>Re: Error while copying content to a stream in C#</title>
      <link>https://www.dropboxforum.com/t5/Discuss-Dropbox-Developer-API/Error-while-copying-content-to-a-stream-in-C/m-p/713436#M3629</link>
      <description>&lt;P&gt;If you want to just upload a single small file and that's all, using &lt;A title="Create a new file with the contents provided in the request" href="https://dropbox.github.io/dropbox-sdk-dotnet/gh-pages/obj/api/Dropbox.Api.Files.Routes.FilesUserRoutes.html#Dropbox_Api_Files_Routes_FilesUserRoutes_UploadAsync_Dropbox_Api_Files_UploadArg_System_IO_Stream_" target="_blank" rel="noopener"&gt;UploadAsync&lt;/A&gt; is the bast. In such a way you create session, upload and close the content and finish the upload - all in this single call. Here is no any optimization. In your last code snippet you make it rather slower - 2 calls instead of one.&lt;/P&gt;&lt;P&gt;If you want to make multiple files upload at once and optimize the process of finish, you can use &lt;A title="This route helps you commit many files at once into a user's Dropbox" href="https://dropbox.github.io/dropbox-sdk-dotnet/gh-pages/obj/api/Dropbox.Api.Files.Routes.FilesUserRoutes.html#Dropbox_Api_Files_Routes_FilesUserRoutes_UploadSessionFinishBatchAsync_Dropbox_Api_Files_UploadSessionFinishBatchArg_" target="_blank" rel="noopener"&gt;UploadSessionFinishBatchAsync&lt;/A&gt; as you have it done already (or rather tried to use).&lt;/P&gt;&lt;P&gt;That's it. Clarify to yourself what actually you want to do.&lt;/P&gt;</description>
      <pubDate>Wed, 13 Sep 2023 16:37:06 GMT</pubDate>
      <guid>https://www.dropboxforum.com/t5/Discuss-Dropbox-Developer-API/Error-while-copying-content-to-a-stream-in-C/m-p/713436#M3629</guid>
      <dc:creator>Здравко</dc:creator>
      <dc:date>2023-09-13T16:37:06Z</dc:date>
    </item>
  </channel>
</rss>

