Hello -
I have a GUI that uses a RichTextBox to output text. The problem is
that if this box ouput text while hidden behind another window, it is
blank when I bring it to the foreground. The text is there when I
click on the scroll button on the scrollbar but it seems to be scrolled
"up" all the way.
The following code is used to add new text to that box with a certain
color:
Dim lTextLength As Integer = aRichTextBox.Te xtLength()
' The following will append aString in aColor to the Text of the
' aRichTextBox.
aRichTextBox.Se lect(lTextLengt h, 0)
aRichTextBox.Se lectionColor = aColor
aRichTextBox.Se lectedText = aString
' This will set the cursor to the end of the text so that it
' scrolls and becomes visible.
aRichTextBox.Se lect(aRichTextB ox.TextLength() , 0)
The last line of code is something I added hoping it would show the
text.
Is this a problem with the RichTextBox or am I doing something wrong
when I add text to the box?
Thanks!
Joe 1 1453
Hello -
Great ... I'll give that a try.
Thanks,
Joe
On Jan 18, 10:01 am, Michel Posseth [MCP]
<MichelPosseth. ..@discussions. microsoft.comwr ote:
I use the rich textbox control mostly for programs that have a status log
function
in these programs i use this method
Private Sub writeText(ByVal text As String, ByVal Kleur As
System.Drawing. Color)
Me.RtbxRapp.Sel ectionColor = Kleur
Me.RtbxRapp.App endText(text)
Me.RtbxRapp.Scr ollToCaret()
end sub
"Joe HM" wrote:
Hello -
I have a GUI that uses a RichTextBox to output text. The problem is
that if this box ouput text while hidden behind another window, it is
blank when I bring it to the foreground. The text is there when I
click on the scroll button on the scrollbar but it seems to be scrolled
"up" all the way.
The following code is used to add new text to that box with a certain
color:
Dim lTextLength As Integer = aRichTextBox.Te xtLength()
' The following will append aString in aColor to the Text of the
' aRichTextBox.
aRichTextBox.Se lect(lTextLengt h, 0)
aRichTextBox.Se lectionColor = aColor
aRichTextBox.Se lectedText = aString
' This will set the cursor to the end of the text so that it
' scrolls and becomes visible.
aRichTextBox.Se lect(aRichTextB ox.TextLength() , 0)
The last line of code is something I added hoping it would show the
text.
Is this a problem with the RichTextBox or am I doing something wrong
when I add text to the box?
Thanks!
Joe- Hide quoted text -- Show quoted text -
This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics |
by: Henrik S. Hansen |
last post by:
I'm new to C++, and cannot figure out why this won't compile:
std::map<std::string, int> tst;
tst = 1;
int main() { /*...*/ }
It gives me:
error: ISO C++ forbids declaration of `tst' with no type
|
by: Squid Seven |
last post by:
This is just bizarre. for the following snippet of code:
#include <string>
using std::string;
I get the error message:
|
by: Apotheosis |
last post by:
The problem professor gave us is:
Write a program which reads two integer values. If the first is less
than the second, print the message "up". If the second is less than
the first, print the message "down" If the numbers are equal, print
the message "equal" If there is an error reading the data, print a
message containing the word "Error" and perform exit( 0 );
And this is what I wrote:
|
by: baumann.Pan |
last post by:
when define
char *p = " can not modify";
p ='b' ;is not allowed,
but if you declare p as
char p = "can modify";
p = 'b'; is ok?
why?
|
by: Martin Jørgensen |
last post by:
Hi,
Today I got a really strange problem... I've made myself a data-file and
I read in data from that file....
When I read something like this line:
03 04 05, 00 04 01, 05 03 07, 08 03 00, 09 06 03 ... etc.
with something like scanf("%i %i %i, ", &var1, &var2, &var3);
| |
by: Chicagoboy27 |
last post by:
All I am trying to find a solution for removing the ?returnUrl if a
user is not authenticated. I want to be redirect an unauthenticated
user to the login.aspx less the returnUrl.
Once they log in I specifically want them to go to the default.aspx
page and not the "ReturnUrl=" page. currently my sight is set up to
redirect to the log in but I am looking to remove the ?returnurl so
that it goes to the normal defualt.aspx
Currently I am...
|
by: U S Contractors Offering Service A Non-profit |
last post by:
" Hind sight is that of 20/20 they say ? "
Craig Somerford
to New
More options 3:49 pm (0 minutes ago)
" The calm before the STORM... SNOW STORM that is "
Craig Somerford
|
by: U S Contractors Offering Service A Non-profit |
last post by:
ALOT of them to pick from... Inbox
Reply
Craig Somerford
to uscosoct24, Matthew, B-eing-I-nstru., Ed, me, New, mw, Natural,
(bcc:USA), (bcc:Letters), (bcc:lvargas), (bcc:Le), (bcc:staff),
(bcc:Local)
show details
2:57 am (0 minutes ago)
" A match made in Heaven "
|
by: service0059 |
last post by:
This category is designed to enable you to have all the important
information right at your fingertips and create better "sight value".
You will learn how karat gold affects appeal and value and understand
various cuts and stone settings. You get to discover for yourself the
sales process and learn how to relate quality, rarity, and color to
the gem values.http://www.dojewelry.net
These are the latest items we have brought back from the...
|
by: marktang |
last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look !
Part I. Meaning of...
|
by: Hystou |
last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it.
First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
| |
by: Oralloy |
last post by:
Hello folks,
I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>".
The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed.
This is as boiled down as I can make it.
Here is my compilation command:
g++-12 -std=c++20 -Wnarrowing bit_field.cpp
Here is the code in...
|
by: jinu1996 |
last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth.
The Art of Business Website Design
Your website is...
|
by: agi2029 |
last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own....
Now, this would greatly impact the work of software developers. The idea...
|
by: isladogs |
last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM).
In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules.
He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms.
Adolph will...
|
by: TSSRALBI |
last post by:
Hello
I'm a network technician in training and I need your help.
I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs.
The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols.
I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
|
by: adsilva |
last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
| |
by: 6302768590 |
last post by:
Hai team
i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
| |