Click here to Skip to main content
15,895,084 members
Home / Discussions / Managed C++/CLI
   

Managed C++/CLI

 
GeneralRe: Named Pipes Pin
Christian Graus14-Apr-08 13:35
protectorChristian Graus14-Apr-08 13:35 
GeneralRe: Named Pipes Pin
Mark Salsbery21-Apr-08 21:19
Mark Salsbery21-Apr-08 21:19 
GeneralauxWireCylinder in VC9.0 Pin
hain14-Apr-08 3:41
hain14-Apr-08 3:41 
GeneralDataGridViewPrinter Class Pin
mikobi14-Apr-08 3:40
mikobi14-Apr-08 3:40 
QuestionProblem of using form component Pin
Member 454227211-Apr-08 18:45
Member 454227211-Apr-08 18:45 
GeneralRe: Problem of using form component Pin
Giorgi Dalakishvili12-Apr-08 8:10
mentorGiorgi Dalakishvili12-Apr-08 8:10 
QuestionRe: Problem of using form component Pin
Member 454227213-Apr-08 18:47
Member 454227213-Apr-08 18:47 
Generalcolor changing Pin
rose19610-Apr-08 2:52
rose19610-Apr-08 2:52 
Hi
I want to change the color of the keyword. for that i read the file and store it as a string. From that i will read the word by word file content and i will check the keyword is matched with the file content or not if it is present it change the color.


for that i wrote the code as follows

array<string^>^ dataTypesTable = gcnew array<string^>{"int","void","float","double","long"};
String^ filecontentpath = this->m_pFileOpenDialog->FileName;
String^ content = File::ReadAllText(filecontentpath);
MessageBox::Show(content);
int length = content->Length;
cli::array<string ^=""> ^str = content->Split(nullptr);
if(str->Length>0)
{
for(int j=0;j<str->Length;j++)
{
for(int i=0;i<datatypestable->Length;i++)
{
if(String::Compare(dataTypesTable[i],str[j])==0)
{
this->srcTextBox->SelectionColor = Color::Blue;
}
}
this->srcTextBox->AppendText(str[j]);
this->srcTextBox->SelectionColor = Color::Black;
}
}


now my problem is it disply the file in a single line .
can you tell me how to read the content of a file in word by word

Thanks
GeneralRe: color changing Pin
Mark Salsbery10-Apr-08 6:28
Mark Salsbery10-Apr-08 6:28 
GeneralRe: color changing Pin
rose19610-Apr-08 16:16
rose19610-Apr-08 16:16 
GeneralRe: color changing Pin
Mark Salsbery10-Apr-08 19:42
Mark Salsbery10-Apr-08 19:42 
GeneralMixed Mode Assemblies Pin
Richard Andrew x649-Apr-08 16:02
professionalRichard Andrew x649-Apr-08 16:02 
GeneralRe: Mixed Mode Assemblies Pin
led mike10-Apr-08 5:00
led mike10-Apr-08 5:00 
GeneralRe: Mixed Mode Assemblies Pin
Mark Salsbery10-Apr-08 6:32
Mark Salsbery10-Apr-08 6:32 
GeneralProblem with Dialogs.... Pin
dSolariuM9-Apr-08 5:28
dSolariuM9-Apr-08 5:28 
GeneralRe: Problem with Dialogs.... Pin
Mark Salsbery9-Apr-08 5:33
Mark Salsbery9-Apr-08 5:33 
GeneralPriceless Pin
led mike10-Apr-08 5:03
led mike10-Apr-08 5:03 
Generalclass libraries Pin
hansipet8-Apr-08 20:19
hansipet8-Apr-08 20:19 
Generalcheck file Pin
rose1968-Apr-08 18:10
rose1968-Apr-08 18:10 
GeneralRe: check file Pin
Mark Salsbery8-Apr-08 18:25
Mark Salsbery8-Apr-08 18:25 
GeneralRe: check file Pin
rose1968-Apr-08 19:20
rose1968-Apr-08 19:20 
GeneralRe: check file Pin
Mark Salsbery9-Apr-08 5:31
Mark Salsbery9-Apr-08 5:31 
QuestionPPP protocol in C? Pin
Benny_Lava7-Apr-08 1:02
Benny_Lava7-Apr-08 1:02 
AnswerRe: PPP protocol in C? Pin
led mike7-Apr-08 4:34
led mike7-Apr-08 4:34 
GeneralRe: PPP protocol in C? Pin
Christian Graus8-Apr-08 1:19
protectorChristian Graus8-Apr-08 1:19 

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.