473,670 Members | 2,397 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Chat Window Challenges

Greetings, All... I'm writing an internet enabled game and I'm working on
the chat engine. I'm using a RichTextBox as the chat message display window
so I can easily display text in several colors. One of the problems is: in
order to scroll the text box to ensure that the most recently posted message
is visible, I have to give the RichTextBox focus. Even though I can switch
focus back to whatever control had it before the update, it is really
annoying to anyone using the other parts of the game interface.

Can anyone give me some advice as to the best way to handle continuous chat
in an environment like this? Is there a better way than the RichTextBox?
Any thoughts are greatly appreciated. Thanks.

Jerry
Nov 20 '05 #1
3 1200
How are you setting the text?

"Rlrcstr" <rl*****@msn.co m> wrote in message
news:ex******** ******@TK2MSFTN GP10.phx.gbl...
Greetings, All... I'm writing an internet enabled game and I'm working on
the chat engine. I'm using a RichTextBox as the chat message display window so I can easily display text in several colors. One of the problems is: in order to scroll the text box to ensure that the most recently posted message is visible, I have to give the RichTextBox focus. Even though I can switch focus back to whatever control had it before the update, it is really
annoying to anyone using the other parts of the game interface.

Can anyone give me some advice as to the best way to handle continuous chat in an environment like this? Is there a better way than the RichTextBox?
Any thoughts are greatly appreciated. Thanks.

Jerry

Nov 20 '05 #2
I'm setting the insertion point and color and using the AppenText method.
Then I'm calling the ScrollToCaret method, but that only works if the
control has the focus.

I know there's got to be a way to do this, I see it all the time, but for
some reason I just can't figure it out...

Jerry

"CJ Taylor" <no****@blowgoa ts.com> wrote in message
news:vs******** ***@corp.supern ews.com...
How are you setting the text?

"Rlrcstr" <rl*****@msn.co m> wrote in message
news:ex******** ******@TK2MSFTN GP10.phx.gbl...
Greetings, All... I'm writing an internet enabled game and I'm working on the chat engine. I'm using a RichTextBox as the chat message display

window
so I can easily display text in several colors. One of the problems is:

in
order to scroll the text box to ensure that the most recently posted

message
is visible, I have to give the RichTextBox focus. Even though I can

switch
focus back to whatever control had it before the update, it is really
annoying to anyone using the other parts of the game interface.

Can anyone give me some advice as to the best way to handle continuous

chat
in an environment like this? Is there a better way than the RichTextBox? Any thoughts are greatly appreciated. Thanks.

Jerry


Nov 20 '05 #3
Wish I could say I had experience with it. I would say that maybe you could
raise an event after its been updated to set the focus back to another
control. Or find another method besides scrolltocaret, I wish I could give
better advice than that..

"Jerry Camel" <rl*****@msn.co m> wrote in message
news:uz******** ******@TK2MSFTN GP09.phx.gbl...
I'm setting the insertion point and color and using the AppenText method.
Then I'm calling the ScrollToCaret method, but that only works if the
control has the focus.

I know there's got to be a way to do this, I see it all the time, but for
some reason I just can't figure it out...

Jerry

"CJ Taylor" <no****@blowgoa ts.com> wrote in message
news:vs******** ***@corp.supern ews.com...
How are you setting the text?

"Rlrcstr" <rl*****@msn.co m> wrote in message
news:ex******** ******@TK2MSFTN GP10.phx.gbl...
Greetings, All... I'm writing an internet enabled game and I'm
working
on the chat engine. I'm using a RichTextBox as the chat message display

window
so I can easily display text in several colors. One of the problems
is:
in
order to scroll the text box to ensure that the most recently posted

message
is visible, I have to give the RichTextBox focus. Even though I can

switch
focus back to whatever control had it before the update, it is really
annoying to anyone using the other parts of the game interface.

Can anyone give me some advice as to the best way to handle continuous

chat
in an environment like this? Is there a better way than the

RichTextBox? Any thoughts are greatly appreciated. Thanks.

Jerry



Nov 20 '05 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
2450
by: |-|erc | last post by:
<?php // Get the names and values for vars sent by index.lib.php3 if (isset($HTTP_GET_VARS)) { while(list($name,$value) = each($HTTP_GET_VARS)) { $$name = $value; }; };
2
1662
by: oracle3001 | last post by:
Hi All, I want to capture / read the text flowing through a chat window that is part of an external application. I should note that I don't just want to capture the text in the chat window once, I want to get the new text as and when it is posted into the chat window
2
2792
by: John Dalberg | last post by:
I am looking for a software package hopefully open source for a live chat system in C#.. one that's similar to phplivesupport. I have contacted the vendors I found in the component gallery at asp.net but none have responded!! That's poor customer service for me. I will probably use an open source one and extend it myself. Any suggestions? It needs to satisfy these:
1
1050
by: Terry Olsen | last post by:
I have a chat client working, using a standard textbox for the chat window. Is there another control and/or code I could use that could recognize a hyperlink in the chat and allow me to click on it?
1
1379
by: ranabhavin2 | last post by:
Hi, I have made database chat application in asp.net. now suppose I have two chat window at different computer. If user1 writing something to user2 then at the bottom there shuold be message into user2 chat window as "User1 is typing." Samething we can see into yahoo chat. Is it possible without using Remoting or Socket ????
5
3955
by: Bhaiyyah | last post by:
I am repetitively failing to login with any user name for XHTML Chat. Here is some info I copied from view source: Link: http://www.shiachat.com/forum/chat.html javascript:Chat=void(window.open('http://www.shiachat.com/forum/chat.html','Chat','resizable=1,status=1,width=800,height=620,top=0,left=0')) <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html...
1
1847
oll3i
by: oll3i | last post by:
when i run it from bat (@start "CHAT to topic" run Chat)without durable subscriber the window for chat opens but when i added the durable subscriber to the code it stopped opening? import java.awt.event.ActionEvent; import java.awt.event.ActionListener; import javax.naming.*; import javax.swing.BorderFactory; import javax.swing.BoxLayout; import javax.swing.JButton; import javax.swing.JFrame;
4
3200
by: hussainiyad | last post by:
Hi experts ,i,m doing a chat room project in it i wanna to create a iframe (e.g in gmail when we want to chat then a window will come )i wanna the same type of window in my chat project, can anyone help me the above this dellemo with regards hussain
4
2474
by: nbt725 | last post by:
Dear Sir, Hello ! I want 1 to 1 chat script in php between client coming to site to chat with admin. And admin can chat with multiple client.There can be multiple admin. I want to disable login window also would supply login details if required thro' script/existing database. I saw many free php chat scripts but they are many to many like messenger where as in this sort of requirement when customer comes and wants to chat with service...
0
8469
marktang
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...
0
8903
Oralloy
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...
0
8814
jinu1996
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...
0
8661
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
7419
agi2029
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...
1
6213
isladogs
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...
0
5684
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
1
2800
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
2
1794
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.