Click here to Skip to main content
15,914,221 members
Home / Discussions / C#
   

C#

 
AnswerRe: Populate dataset [modified] Pin
NasimKaziS3-Aug-06 1:38
NasimKaziS3-Aug-06 1:38 
QuestionC# books online Pin
vikas amin3-Aug-06 0:49
vikas amin3-Aug-06 0:49 
AnswerRe: C# books online Pin
yueue3-Aug-06 3:16
yueue3-Aug-06 3:16 
GeneralRe: C# books online [modified] Pin
vikas amin3-Aug-06 3:40
vikas amin3-Aug-06 3:40 
Questionrtb formatting problems Pin
SoftcodeSoftware3-Aug-06 0:07
SoftcodeSoftware3-Aug-06 0:07 
AnswerRe: rtb formatting problems Pin
Ingo3-Aug-06 0:16
Ingo3-Aug-06 0:16 
QuestionRe: rtb formatting problems [modified] Pin
SoftcodeSoftware3-Aug-06 0:24
SoftcodeSoftware3-Aug-06 0:24 
AnswerRe: rtb formatting problems [modified] Pin
Ingo3-Aug-06 0:57
Ingo3-Aug-06 0:57 
SoftcodeSoftware wrote:
Thanks, but that still only does one instance of the term - I think it's finding the first instance and applying it to that over and over again - is there a way to find a string's position searching from the end instead of the beginning at all?


You can search the position of a string:

str.IndexOf("username:");
or
str.LastIndexOf("username:");

So you can search every part of the string you want bold and then select it and set it bold like in the first answer I gave.

example:
string searchstr[] = new string[<nr>];
searchstr[0] = "username:";

for (int i = 0; i < searchstr.Length; i++) {
rtfbox.Select(rtfbox.Text.IndexOf(searchstr[i]), searchstr[i].Length);
...
}

Regards,
Ingo



-- modified at 6:57 Thursday 3rd August, 2006

------------------------------
PROST Roleplaying Game

War doesn't determine who's right. War determines who's left.

GeneralRe: rtb formatting problems Pin
SoftcodeSoftware3-Aug-06 5:04
SoftcodeSoftware3-Aug-06 5:04 
AnswerRe: rtb formatting problems Pin
yueue3-Aug-06 0:22
yueue3-Aug-06 0:22 
Questionloading a bitmap file Pin
diddy343-Aug-06 0:05
diddy343-Aug-06 0:05 
AnswerRe: loading a bitmap file Pin
Robert Rohde3-Aug-06 0:11
Robert Rohde3-Aug-06 0:11 
GeneralRe: loading a bitmap file Pin
yueue3-Aug-06 0:24
yueue3-Aug-06 0:24 
JokeRe: loading a bitmap file Pin
mav.northwind3-Aug-06 1:04
mav.northwind3-Aug-06 1:04 
GeneralRe: loading a bitmap file Pin
yueue3-Aug-06 2:57
yueue3-Aug-06 2:57 
GeneralRobert I need some help Pin
diddy343-Aug-06 1:18
diddy343-Aug-06 1:18 
GeneralRe: Robert I need some help Pin
Christian Graus3-Aug-06 1:32
protectorChristian Graus3-Aug-06 1:32 
GeneralRe: Robert I need some help [modified] Pin
Dave Kreskowiak3-Aug-06 1:48
mveDave Kreskowiak3-Aug-06 1:48 
GeneralRe: Robert I need some help Pin
stancrm3-Aug-06 19:57
stancrm3-Aug-06 19:57 
Questionservice controller/impersonate error [modified] Pin
JakeFront3-Aug-06 0:03
professionalJakeFront3-Aug-06 0:03 
QuestionDelegates Pin
fmardani2-Aug-06 23:48
fmardani2-Aug-06 23:48 
AnswerRe: Delegates Pin
Christian Graus3-Aug-06 0:01
protectorChristian Graus3-Aug-06 0:01 
GeneralRe: Delegates Pin
yueue3-Aug-06 0:32
yueue3-Aug-06 0:32 
AnswerRe: Delegates Pin
NasimKaziS3-Aug-06 1:51
NasimKaziS3-Aug-06 1:51 
QuestionExposing classes' methods/properties in Web Service [modified] Pin
impeham2-Aug-06 23:29
impeham2-Aug-06 23:29 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.