| View previous topic :: View next topic |
| Author |
Message |
icarng Power User


Joined: 05 Jan 2004 Posts: 73
|
Posted: Sun Feb 22, 2004 8:16 pm Post subject: how to change the color of a selected character? |
|
|
hi all,
i would like to know how can i change the color of a character which the character is supposed to be returned from a separated method.
i have been working on this for long, can anyone help? |
|
| Back to top |
|
 |
DannyB Moderator


Joined: 02 Apr 2003 Posts: 3991 Location: Lawrence, Kansas, USA
|
|
| Back to top |
|
 |
icarng Power User


Joined: 05 Jan 2004 Posts: 73
|
Posted: Tue Feb 24, 2004 6:27 pm Post subject: |
|
|
since i have used oText and oCursor for highlighting a string from a document, i think i may not be able to use the same method to achieve the task.
i wonder if there's any method that can help in changing the color without using oCursor and oText
or is there any method that i can use another oText and oCursor apart from the previous? |
|
| Back to top |
|
 |
dfrench Moderator

Joined: 03 Mar 2003 Posts: 1605 Location: Wellington, New Zealand
|
Posted: Tue Feb 24, 2004 9:00 pm Post subject: |
|
|
| You may have any number of text cursors and text objects (only one viewcursor) |
|
| Back to top |
|
 |
icarng Power User


Joined: 05 Jan 2004 Posts: 73
|
Posted: Tue Feb 24, 2004 10:04 pm Post subject: |
|
|
can you show me a sample?
just like declaring a new variable?
oText1 oText2? |
|
| Back to top |
|
 |
icarng Power User


Joined: 05 Jan 2004 Posts: 73
|
Posted: Tue Feb 24, 2004 10:08 pm Post subject: |
|
|
or let me put in this way
is it possible for me to change the character properties of a character that is supposed to be shown on dialog box? |
|
| Back to top |
|
 |
dfrench Moderator

Joined: 03 Mar 2003 Posts: 1605 Location: Wellington, New Zealand
|
Posted: Tue Feb 24, 2004 11:08 pm Post subject: |
|
|
| Quote: | | is it possible for me to change the character properties of a character that is supposed to be shown on dialog box? |
I do not think so . I assume that you would be putting the character in a TEXTFIELD control in the dialog ... this only allows a string and not a text object which is what you need to have character formatting.
You may have better luck with a FORM where the textbox control does allow for a text object. |
|
| Back to top |
|
 |
icarng Power User


Joined: 05 Jan 2004 Posts: 73
|
Posted: Wed Feb 25, 2004 1:33 am Post subject: |
|
|
i just lookfor some articles,
and i discover that VB would have the following codes for changing the color of text
| Code: | | Text1.ForeColor = vbRed |
i m looking for something similar in starbasic, not possible, right? |
|
| Back to top |
|
 |
|