Search:

Type: Posts; User: Chris001

Page 1 of 13 1 2 3 4

Search: Search took 0.12 seconds.

  1. VS 2010 Keeping track of Item index with Virtual ListView

    I've written a FileDownloader class to download files via a separate thread. The progress of each download is shown in a ListView with VirtualMode enabled.

    Everything works perfectly fine, the...
  2. Replies
    0
    Views
    1,151

    [RESOLVED] Fixing a memory leak

    Hi, let me first say that I normally program in VB. I need to download videos/streams via the RTMP protocol. This is quite a complicated protocol, so I found a C# library here that has been directly...
  3. Re: List(of Class) used for Virtual Listview updates itself

    Oh, you're right. The class is a reference type and not value type. I feel silly now :blush:
  4. [RESOLVED] List(of Class) used for Virtual Listview updates itself

    Hi, I have a weird problem or maybe it's just me. I'm connected to a server on a separate thread that continuously sends updates. I'm using a ConcurrentDictionary(Integer, Class) to store/update the...
  5. Replies
    1
    Views
    4,288

    VS 2013 Re: Creating ZIP file with password.

    Sorry, but the ZipFile class does not allow you to create password protected ZIP archives. You can use DotNetZip to do that.
  6. Re: Buffer downloaded data before writing it to disk

    I see what you mean now. Perfect, thank you very much.
  7. Re: Buffer downloaded data before writing it to disk

    I thought about that as well, but the problem is that the user must be able to cancel the download. RTSP_Read blocks and that's fine, because all the code runs on a separate thread, but cancelling...
  8. [RESOLVED] Buffer downloaded data before writing it to disk

    Hi, I'm using a library written in C to download data via RTSP/RTMP protocols. With two or three downloads at once it works fine, but with ten-plus downloads at once the hard drive starts to...
  9. Re: Cancelled Message not showing in BackgroundWorker RunWorkerCompleted routine

    You must check if the CancellationPending property is True and then set the e.Cancel property to True as well.
    ...
  10. Replies
    4
    Views
    1,531

    Re: Checking if Winzip is password protected

    Yes, you are right. The ZipArchive class does not support passwords. Sorry :blush:



    I've modified the function to read the "end of central directory record" first, which contains the offset to...
  11. Replies
    4
    Views
    1,531

    Re: Checking if Winzip is password protected

    If you want know if a ZIP archive is password protected, then you must check each file in the ZIP archive. Some files in the ZIP archive might be password protected and other files not.

    Here's a...
  12. Replies
    21
    Views
    8,262

    Re: Parsing a large json string

    OICU812, thank you very much. I was already very happy with 25ms, but less than 10ms is excellent. Putting the regex in a text file resource is a great idea. I never thought about that. It's a lot...
  13. Replies
    21
    Views
    8,262

    Re: Parsing a large json string

    Thank you. The only problem I have now, is that when for example the "age" is missing, the "addess" cannot be found. The "city" is shown in the 'Address' column and the "country" is shown in the...
  14. Replies
    21
    Views
    8,262

    Re: Parsing a large json string

    If I understand correctly, you mean traverse through the byte array to find the beginning (position) of each user and then use Substring to extract each users data from the JSON?

    After thinking...
  15. Replies
    21
    Views
    8,262

    Re: Parsing a large json string

    I just tested ident's code and it is about 12ms faster than my Regex for parsing the username. I also tried to split on double curly brackets, looping through the string array and then use a function...
  16. Replies
    21
    Views
    8,262

    Re: Parsing a large json string

    For example, JSON.NET and SimpleJSON. They convert JSON to objects, but they read one character at a time (quotation marks, brackets, colons, commas, etc), which is the proper way of parsing JSON,...
  17. Replies
    21
    Views
    8,262

    [RESOLVED] Parsing a large json string

    Every few minutes I'm downloading data from a server returned in json, which is a few MiB in size. All the json parsers out there are very slow, because they loop over every character in the string....
  18. VS 2010 Re: Looking for a replacement of the BlockingCollection class.

    You're right, it does require quite a bit of code. I'm not exactly a multi-threading expert, so I hoped that somebody with a lot more knowledge about multi-threading had written a class, before .NET...
  19. VS 2010 [RESOLVED] Looking for a replacement of the BlockingCollection class.

    Hi, I'm currently using the BlockingCollection class for my Producer/Consumer code and it works perfectly, except it uses a ridiculous amount of memory. The maximum capacity has been set to 10 and...
  20. VS 2010 Re: Uploading files in chunks with multiple threads (Producer/Consumer)

    Thanks ident, but this server uses a different protocol and I need to do everything myself.

    I didn't know that the ThreadPool is obsolete. I'm using the System.Threading.Tasks namespace now.

    ...
  21. VS 2010 [RESOLVED] Uploading files in chunks with multiple threads (Producer/Consumer)

    Hi, I'm creating a console application and I'm looking for the best way to upload files in chunks to a server with multiple connections (10 connections maximum). The files are uploaded as strings and...
  22. Re: How to optimize ListView control to work faster?

    Are you sure that the problem is with the ListView and not with the way how you retrieve the data from the database or perhaps some other problem?

    Simply loading 5000 items into the ListView with...
  23. Replies
    2
    Views
    2,754

    Re: Unrar dll sample code

    If you download the UnRar.dll from the WinRar website, then there are various examples included in C, C#, Delphi, Perl, Pascal, MASM, VB and VB6.
  24. Re: WebClient DownloadFileAsync with resume support

    Try to right-click on the link and select "Save Link As...", "Save Target As..." or something like that, depending on which browser you use.
  25. Replies
    20
    Views
    5,047

    VS 2012 Re: HttpWebRequest using sockets

    Here's an example that should get you started.

    http://msdn.microsoft.com/en-us/library/system.net.sockets.socket.aspx
  26. Re: WebClient DownloadFileAsync with resume support

    Yes, you are free to do with it whatever you want.
  27. Replies
    2
    Views
    2,220

    VS 2012 Re: WebClient PostData Error

    I think your problem is the url.

    In your WebClient code you navigate to :http://www.192.com/businesses/advanced/

    In your WebRequest code you navigate to:...
  28. Thread: FTP problem

    by Chris001
    Replies
    8
    Views
    2,800

    Re: FTP problem

    You must add the filename to the first parameter as well.


    Using WC As New WebClient
    WC.Credentials = New NetworkCredential("Username", "Password")
    ...
  29. Replies
    7
    Views
    2,164

    Re: Listview with progressbar error

    You shouldn't use a ListView if you want to add ProgressBars. A ListView is not a container control. You should use a DataGridView instead. If you do want to add ProgressBars to the ListView, then...
  30. Replies
    4
    Views
    5,019

    Re: Boyer-Moore byte array search

    Thank you very much.
  31. Replies
    4
    Views
    5,019

    [RESOLVED] Boyer-Moore byte array search

    Hi, I found the Boyer-Moore search algorithm below to search for a byte pattern in byte arrays. The byte arrays are between 10MB and 50MB. The code works fine, but now I need to search for a byte...
  32. Replies
    4
    Views
    2,443

    Re: [RESOLVED] Console write to StdOut

    I simply added a new parameter that people must use when they want to send the stream to StdOut instead of saving it to disk. Not the solution I was initially looking for, but it works fine.
  33. Replies
    4
    Views
    2,443

    Re: Console write to StdOut

    Thank you.


    ::Edit::

    Resolved.
  34. Replies
    5
    Views
    1,366

    Re: Goto Line In TextBox

    Your declaration of SendMessage is wrong.

    http://www.pinvoke.net/default.aspx/user32.sendmessage
  35. Replies
    4
    Views
    2,443

    [RESOLVED] Console write to StdOut

    Hi, I have a console application that modifies MP3's. Currently I'm writing the modified MP3 to a file using a filestream.

    Some users have requested to be able to pipe the MP3 directly to their...
  36. Replies
    4
    Views
    3,878

    VS 2010 Re: Can’t set WebClient Accept header

    If you're already using HttpWebRequest and your code works fine, then you might as well keep using that. The WebClient class simply makes the most common tasks with HttpWebRequest easier. It also...
  37. Replies
    4
    Views
    3,878

    VS 2010 Re: Can’t set WebClient Accept header

    WebClient uses HttpWebRequest in the background. You can inherit the WebClient and override GetWebRequest in order to change everything you want.

    Here's a small example.

    Imports System.Net
    ...
  38. Replies
    3
    Views
    962

    Re: Listview item removal

    When you really want to remove items with "RemoveAt", then you should always loop backwards, because the index gets updated when items are removed.

    The Listview is 0-based (first index is 0 and...
  39. Re: CheckBoxRenderer and ownerdrawn ListView

    Perfect!

    Thank you very much for your help.
  40. Re: CheckBoxRenderer and ownerdrawn ListView

    I've made some progress.

    The code below seems to work, but I have two problems.

    1) If I move the mouse cursor from outside the ListView into the ListView, from the right side, I get an "Object...
Results 1 to 40 of 500
Page 1 of 13 1 2 3 4



Click Here to Expand Forum to Full Width