Re: Opening Large Files
- From: Joseph M. Newcomer <newcomer@xxxxxxxxxxxx>
- Date: Tue, 25 Jul 2006 23:29:26 -0400
Hmm. It used to be that NotePad would complain and ask me if I wanted to switch to
WordPad. Obviously they've fixed that problem, and I hadn't noticed.
I'd seen references to the 1MB, which is why I qualified it with "I believe", but I don't
have any large files to test it with.
I knew of a couple fancy edit controls from years ago, which is why I suggested a
third-party control. Your pointer looks like a good one.
joe
On Tue, 25 Jul 2006 21:39:05 -0500, "Doug Harrison [MVP]" <dsh@xxxxxxxx> wrote:
On Tue, 25 Jul 2006 19:22:47 -0400, Joseph M. NewcomerJoseph M. Newcomer [MVP]
<newcomer@xxxxxxxxxxxx> wrote:
Depends on what you mean by "large" file. 30MB is sort-of-small as files go. You don't
start applying the term "large" until you get to gigabytes
As far as showing it in an edit box, however, an edit box is restricted to 64K
Notepad can open files a lot bigger than that.
and a rich edit control I believe has a limit of 1MB.
That was never the case. However, there is a problem in that its
implementation (in Win2K, at least) of WM_GETTEXTLENGTH is O(n), and
programs like WordPad use that message in UPDATE_UI handlers. So even
moving the cursor around can be really slow in large files, at least back
in the day of P200MMX machines.
So by that definition, your filel is "large".
Unfortunately, I am not aware of any solutions other than buying third-party controls. If
you don't need the ability to select at other than the line level, the virtual listbox
will handle your needs; if you need a real text control, you probably had to investigate
what is out there. I just searched codeproject and didn't find anything that suggested
any extension to rich edit that might handle this.
Scintilla is written from scratch and looks pretty good:
http://www.scintilla.org/
email: newcomer@xxxxxxxxxxxx
Web: http://www.flounder.com
MVP Tips: http://www.flounder.com/mvp_tips.htm
.
- Follow-Ups:
- Re: Opening Large Files
- From: Doug Harrison [MVP]
- Re: Opening Large Files
- From: Alexander Grigoriev
- Re: Opening Large Files
- References:
- Opening Large Files
- From: kefkastudio
- Re: Opening Large Files
- From: Joseph M . Newcomer
- Re: Opening Large Files
- From: Doug Harrison [MVP]
- Opening Large Files
- Prev by Date: Re: Updating Status Bar,
- Next by Date: Re: editing resource.h,
- Previous by thread: Re: Opening Large Files
- Next by thread: Re: Opening Large Files
- Index(es):
Relevant Pages
|