My professor wants the following:

1. Write a program to correct a text including several paragraphs
a. The first line in each paragraph must be indented
b. The first character in every sentence must be capitalized, paragraphs will be indented with "CRLF" code

c. Initial text and output must be displayed in two different textboxes
d. Your program must include "word count" function
e. Your program must be able to correct a variable number of paragraphs

I don't even know where to start with this, I have one multiline textbox with a couple paragraphs in it, and under a button i have to do all of the things he asks to another textbx. Any help at all would be great.

Recommended Answers

All 5 Replies

Please post your code and we'll try to add what we can to it.
For now, i give you what I think would work.

you can parse text using Regular Expression (RegEx).
You are going to have to keep count of all of the words so use that as work count function.
Put everything into an array and move them to the second textbox one at a time and apply a,b.

And you won't indent paragraphs with CRLF. You will indent with vbTab.

>>b. The first character in every sentence must be capitalized,...

With TextBox1
            .Text = StrConv(.Text, VbStrConv.ProperCase)
        End With

>>d. Your program must include "word count" function

With TextBox1
            MsgBox(.Text.Split(" "c).Length.ToString & " totally.noobed words in this WordsCount", MsgBoxStyle.Information)
        End With

>>I don't even know where to start with this...
Hope this helps.:)

I'm in the same class with this guy, thanks so much codeorder, but we need help with the other stuff now!

>>I'm in the same class with this guy, thanks so much codeorder, but we need help with the other stuff now!
.only "we"? hmm., will think about it:D, though in the meantime, start your own dam.n.thread. Return ".thanx":)

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.