1. [Win32Lib] weird RichEdit problem

I'm trying to develop an application alternately on a laptop & a desk pc,
but a part of the app doesn't run correctly on the desktop, though it runs
just fine on the laptop.

The two systems are both running Eu 2.3 & Win32Lib 59.01 for the app, and
the only difference I can see between them is that the desk pc has Windows
98 1st ed, & the laptop has Windows 98 2nd ed.

The relevant parts of the program are these:
1.  a listbox & a richedit;
2.  clicking on an item in the list causes "stuff" to be loaded into the
richedit; some
items cause a lot of stuff to be loaded, others just load a little;  in all
cases the stuff loaded contains at least the item from the list, with some
elaboration;
3.  after the stuff is loaded into the richedit, it is searched for the item
that was clicked on from the list, & when found it is "selected" (hilighted)
in the richedit, & if the stuff in the richedit was really big, the richedit
automagically pages down to the "selected" item.

The problem is this:
All of the above *happens* on the laptop; but on the desk pc, for one large
"page" of stuff in the richedit, the *selection* & page movement only
happens down to some particular item.
The item which is the start of the problem is at character #32787 in the
richedit.
All items at & after that one do NOT select (hilite) anything, & moves down
to show the end of the "page" of text. (And if I look back up to where that
item would be in the richedit, it is not selected.)

Since that character count number, 32787, looks suspiciously like a boundary
limit in the richedit, I'm wondering if that is somehow the culprit, & if
so, what I can do to fix it?  All the text SHOWS in the richedit, it's just
that some found "lines" don't get selected as they should.

TIA,
Dan Moyer

new topic     » topic index » view message » categorize

2. Re: [Win32Lib] weird RichEdit problem

danielmoyer wrote:
> 
> I'm trying to develop an application alternately on a laptop & a desk pc,
> but a part of the app doesn't run correctly on the desktop, though it runs
> just fine on the laptop.
> 
> The two systems are both running Eu 2.3 & Win32Lib 59.01 for the app, and
> the only difference I can see between them is that the desk pc has Windows
> 98 1st ed, & the laptop has Windows 98 2nd ed.

Richedit 2.0 was released with Win98 1st Ed.

Richedit 3.0 was unofficially released with 2nd Ed. It officially
came with Windows ME.

All you need to do is copy the riched20.dll from the laptop to
the desktop machine. This will "install" RichEdit 3.0 on both
machines. It is this version that supports more than 32K chars
by default.

-- 
Derek Parnell
Melbourne, Australia

new topic     » goto parent     » topic index » view message » categorize

3. Re: [Win32Lib] weird RichEdit problem

----- Original Message ----- 
From: "Derek Parnell" <guest at RapidEuphoria.com>
To: <EUforum at topica.com>
Sent: Sunday, September 05, 2004 9:05 PM
Subject: Re: [Win32Lib] weird RichEdit problem


>
>
> posted by: Derek Parnell <ddparnell at bigpond.com>
>
> danielmoyer wrote:
> >
> > I'm trying to develop an application alternately on a laptop & a desk
pc,
> > but a part of the app doesn't run correctly on the desktop, though it
runs
> > just fine on the laptop.
> >
> > The two systems are both running Eu 2.3 & Win32Lib 59.01 for the app,
and
> > the only difference I can see between them is that the desk pc has
Windows
> > 98 1st ed, & the laptop has Windows 98 2nd ed.
>
> Richedit 2.0 was released with Win98 1st Ed.
>
> Richedit 3.0 was unofficially released with 2nd Ed. It officially
> came with Windows ME.
>
> All you need to do is copy the riched20.dll from the laptop to
> the desktop machine. This will "install" RichEdit 3.0 on both
> machines. It is this version that supports more than 32K chars
> by default.

Aha!  thanks Derek!  I'll give it a try.
But just in case any user of the app also doesn't have Richedit 3.0 on their
system, is there some way to programmatically change the default?
(And the richedit on the desk pc doesn't neglect to *hold* or display the
longer text, just neglects to allow programmatic selection of text displayed
past the 32K char.)

Dan



>
> -- 
> Derek Parnell
> Melbourne, Australia
>

new topic     » goto parent     » topic index » view message » categorize

4. Re: [Win32Lib] weird RichEdit problem

danielmoyer wrote:

[snip]
> But just in case any user of the app also doesn't have Richedit 3.0 on their
> system, is there some way to programmatically change the default?
> (And the richedit on the desk pc doesn't neglect to *hold* or display the
> longer text, just neglects to allow programmatic selection of text displayed
> past the 32K char.)

I don't think so. You could try the limitText() routine but
that can only set a maximum of 64,000 characters (I think). The
API documentation is ambiguous.

-- 
Derek Parnell
Melbourne, Australia

new topic     » goto parent     » topic index » view message » categorize

5. Re: [Win32Lib] weird RichEdit problem

----- Original Message ----- 
From: "Derek Parnell" <guest at RapidEuphoria.com>
To: <EUforum at topica.com>
Sent: Monday, September 06, 2004 12:03 AM
Subject: Re: [Win32Lib] weird RichEdit problem


>
>
> posted by: Derek Parnell <ddparnell at bigpond.com>
>
> danielmoyer wrote:
>
> [snip]
> > But just in case any user of the app also doesn't have Richedit 3.0 on
their
> > system, is there some way to programmatically change the default?
> > (And the richedit on the desk pc doesn't neglect to *hold* or display
the
> > longer text, just neglects to allow programmatic selection of text
displayed
> > past the 32K char.)
>
> I don't think so. You could try the limitText() routine but
> that can only set a maximum of 64,000 characters (I think). The
> API documentation is ambiguous.

LimitText didn't help; first I tried 128K, didn't either fail, nor help;
then I tried 64K, ditto; then I tried 32K, just to see if it would actually
limit the text (last element in largest text was 50K +), & the *full text*
was displayed in richedit, still no selection past 32K.  So it would appear
that at least in the not-most-recent Win32Lib, LimitText may not be working
in its intended fashion for RichEdit?  Maybe it's working in newest.

Any other thoughts for allowing programmatic selection in richedit past 32K
in Win98 1st ed without having to have user import the dll?

Dan





>
> -- 
> Derek Parnell
> Melbourne, Australia
>
>
>
>

new topic     » goto parent     » topic index » view message » categorize

6. Re: [Win32Lib] weird RichEdit problem

On Mon, 6 Sep 2004 00:40:38 -0700, Dan Moyer <DANIELMOYER at prodigy.net>
wrote:

>Any other thoughts for allowing programmatic selection in richedit past 32K
>in Win98 1st ed without having to have user import the dll?

What happens if you place a copy of the dll in the application
directory?

Pete

new topic     » goto parent     » topic index » view message » categorize

7. Re: [Win32Lib] weird RichEdit problem

----- Original Message ----- 
From: "Derek Parnell" <guest at RapidEuphoria.com>
To: <EUforum at topica.com>
Sent: Sunday, September 05, 2004 9:05 PM
Subject: Re: [Win32Lib] weird RichEdit problem


>
>
> posted by: Derek Parnell <ddparnell at bigpond.com>
>
> danielmoyer wrote:
> >
> > I'm trying to develop an application alternately on a laptop & a desk
pc,
> > but a part of the app doesn't run correctly on the desktop, though it
runs
> > just fine on the laptop.
> >
> > The two systems are both running Eu 2.3 & Win32Lib 59.01 for the app,
and
> > the only difference I can see between them is that the desk pc has
Windows
> > 98 1st ed, & the laptop has Windows 98 2nd ed.
>
> Richedit 2.0 was released with Win98 1st Ed.
>
> Richedit 3.0 was unofficially released with 2nd Ed. It officially
> came with Windows ME.
>
> All you need to do is copy the riched20.dll from the laptop to
> the desktop machine. This will "install" RichEdit 3.0 on both
> machines. It is this version that supports more than 32K chars
> by default.

Derek,  I checked my desk pc & it already has:  riched20.dll, Riched32.dll,
& riched.dll (for 16 bit).

When I look at riched20.dll on both desk & laptop, they look identical & do
both have the same checksum, signature, & time/date stamp.

However, for Riched32.dll, while the signature is the same for both, the
time/date stamp is different, as is the checksum.  (timedate for
Riched32.dll on laptop is 3720a1d1, timedate on desk pc is 38555167).

Does this make it seem that if it's the .dll that's the problem, I would
need to copy Riched32.dll from laptop to desk pc, rather than riched32.dll?

Dan


>
> -- 
> Derek Parnell
> Melbourne, Australia
>

new topic     » goto parent     » topic index » view message » categorize

8. Re: [Win32Lib] weird RichEdit problem

----- Original Message ----- 
From: "Pete Lomax" <petelomax at blueyonder.co.uk>
To: <EUforum at topica.com>
Sent: Monday, September 06, 2004 2:43 AM
Subject: Re: [Win32Lib] weird RichEdit problem


>
>
> On Mon, 6 Sep 2004 00:40:38 -0700, Dan Moyer <DANIELMOYER at prodigy.net>
> wrote:
>
> >Any other thoughts for allowing programmatic selection in richedit past
32K
> >in Win98 1st ed without having to have user import the dll?
>
> What happens if you place a copy of the dll in the application
> directory?
>
> Pete
>

Thanks Pete, that's an interesting thought & I'll try it, though I'm not too
comfortable with the implied (?) suggestion to "bundle" a .dll with the app
for users (here), as that isn't code that can be examined easily & verified
to be non-malicious.

Dan

new topic     » goto parent     » topic index » view message » categorize

9. Re: [Win32Lib] weird RichEdit problem

danielmoyer wrote:
[snip]
> 
> Does this make it seem that if it's the .dll that's the problem, I would
> need to copy Riched32.dll from laptop to desk pc, rather than riched32.dll?

The way win32lib works is that if first looks for riched20.dll. If found
it uses that, otherwise it tries to use riched32.dll

You can changes behaviour to look for 32.dll before 20.dll by
editing w32dll.ew. Change ...

riched32 = registerw32Library({"riched20.dll","riched32.dll"}),   -- Rich Edit
 control

to 

riched32 = registerw32Library({"riched32.dll","riched20.dll"}),   -- Rich Edit
 control


Then have 32.dll inside your application directory. I think that'll work.

BTW, I think I should change win32lib to look for 32.dll before 20.dll.

-- 
Derek Parnell
Melbourne, Australia

new topic     » goto parent     » topic index » view message » categorize

10. Re: [Win32Lib] weird RichEdit problem

----- Original Message ----- 
From: "Derek Parnell" <guest at RapidEuphoria.com>
To: <EUforum at topica.com>
Sent: Monday, September 06, 2004 4:09 PM
Subject: Re: [Win32Lib] weird RichEdit problem


>
>
> posted by: Derek Parnell <ddparnell at bigpond.com>
>
> danielmoyer wrote:
> [snip]
> >
> > Does this make it seem that if it's the .dll that's the problem, I would
> > need to copy Riched32.dll from laptop to desk pc, rather than
riched32.dll?
>
> The way win32lib works is that if first looks for riched20.dll. If found
> it uses that, otherwise it tries to use riched32.dll

Interesting, but confusing, since I have riched20.dll on both systems, &
they appear to be exactly the same on both, yet I have different behavior on
each.  If Win32Lib is looking for 20dll first, & it's on both machines &
it's the same, then shouldn't the richedit behavior be the same?


>
> You can changes behaviour to look for 32.dll before 20.dll by
> editing w32dll.ew. Change ...
>
>  riched32 = registerw32Library({"riched20.dll","riched32.dll"}),   -- Rich
Edit control
>
> to
>
>  riched32 = registerw32Library({"riched32.dll","riched20.dll"}),   -- Rich
Edit control
>
>
> Then have 32.dll inside your application directory. I think that'll work.

I think for the moment I'll rename 20dll in win/system on desk pc, & copy
32dll from laptop to 20dll into win/system on desc pc, & see what that does;
make sense?

Dan


>
> BTW, I think I should change win32lib to look for 32.dll before 20.dll.
>
> -- 
> Derek Parnell
> Melbourne, Australia
>

new topic     » goto parent     » topic index » view message » categorize

11. Re: [Win32Lib] weird RichEdit problem

----- Original Message ----- 
From: "Derek Parnell" <guest at RapidEuphoria.com>
To: <EUforum at topica.com>
Sent: Monday, September 06, 2004 4:09 PM
Subject: Re: [Win32Lib] weird RichEdit problem


>
>
> posted by: Derek Parnell <ddparnell at bigpond.com>
>
> danielmoyer wrote:
> [snip]
> >
> > Does this make it seem that if it's the .dll that's the problem, I would
> > need to copy Riched32.dll from laptop to desk pc, rather than
riched32.dll?
>
> The way win32lib works is that if first looks for riched20.dll. If found
> it uses that, otherwise it tries to use riched32.dll

Derek,

More confusion:  when I look at properties of riched20.dll on both machines,
they BOTH say that it's version *3.0* .  Even has the same "file version"
number (5.30.23.1200)

Dan

>
> You can changes behaviour to look for 32.dll before 20.dll by
> editing w32dll.ew. Change ...
>
>  riched32 = registerw32Library({"riched20.dll","riched32.dll"}),   -- Rich
Edit control
>
> to
>
>  riched32 = registerw32Library({"riched32.dll","riched20.dll"}),   -- Rich
Edit control
>
>
> Then have 32.dll inside your application directory. I think that'll work.
>
> BTW, I think I should change win32lib to look for 32.dll before 20.dll.
>
> -- 
> Derek Parnell
> Melbourne, Australia
>

new topic     » goto parent     » topic index » view message » categorize

12. Re: [Win32Lib] weird RichEdit problem

danielmoyer wrote:
> 
> 
> ----- Original Message ----- 
> From: "Derek Parnell" <guest at RapidEuphoria.com>
> To: <EUforum at topica.com>
> Sent: Monday, September 06, 2004 4:09 PM
> Subject: Re: [Win32Lib] weird RichEdit problem
> 
> 
> > posted by: Derek Parnell <ddparnell at bigpond.com>
> >
> > danielmoyer wrote:
> > [snip]
> > >
> > > Does this make it seem that if it's the .dll that's the problem, I would
> > > need to copy Riched32.dll from laptop to desk pc, rather than
> riched32.dll?
> >
> > The way win32lib works is that if first looks for riched20.dll. If found
> > it uses that, otherwise it tries to use riched32.dll
> 
> Derek,
> 
> More confusion:  when I look at properties of riched20.dll on both machines,
> they BOTH say that it's version *3.0* .  Even has the same "file version"
> number (5.30.23.1200)

So sue Microsoft. They caused this confusion.

You need to do tests to determine which dll is doing what. For example
try swapping them between machines. Try hiding any riched32.dll. Try
hiding any riched20.dll. Use exactly the same copy of 20.dll on both
machines. Use exactly the same 32.dll on both machines... etc...


-- 
Derek Parnell
Melbourne, Australia

new topic     » goto parent     » topic index » view message » categorize

Search



Quick Links

User menu

Not signed in.

Misc Menu