Wrox Programmer Forums

Need to download code?

View our list of code downloads.

Go Back   Wrox Programmer Forums > Visual Basic > VB 6 Visual Basic 6 > Beginning VB 6
Password Reminder
Register
| FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read
Beginning VB 6 For coders who are new to Visual Basic, working in VB version 6 (not .NET).
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Beginning VB 6 section of the Wrox Programmer to Programmer discussions. This is a community of tens of thousands of software programmers and website developers including Wrox book authors and readers. As a guest, you can read any forum posting. By joining today you can post your own programming questions, respond to other developers’ questions, and eliminate the ads that are displayed to guests. Registration is fast, simple and absolutely free .
DRM-free e-books 300x50
Reply
 
Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old February 19th, 2004, 04:49 PM
ric ric is offline
Registered User
 
Join Date: Aug 2003
Location: Venice, , Israel.
Posts: 4
Thanks: 0
Thanked 0 Times in 0 Posts
Default Indented paragraph

In my notepad project I inserted the possibility to have an indented paragraph. Unfortunately following code indents all the text:


Private Sub ind_Click()
With ActiveForm.rtfText
.SelStart = 1
.SelLength = Len(.Text) ‘THIS SELECT TO THE END OF TEXT.
.SelIndent = 1440
.SelRightIndent = 1440
End With
End Sub

The wrong line is the one commented (this select ...)I should substitute with a line which apply the modification only at one paragraph end is encountered (I mean, until a "."(dot = end of phrase) is met)
How could I do ?
Thanks in advance.
Reply With Quote
  #2 (permalink)  
Old February 26th, 2004, 06:08 AM
Authorized User
 
Join Date: Aug 2003
Location: , , Belgium.
Posts: 44
Thanks: 0
Thanked 0 Times in 0 Posts
Default

I think you can use the InStr function

Function InStr([Start], [String1], [String2], [Compare As VbCompareMethod = vbBinaryCompare])
    Member of VBA.Strings
    Returns the position of the first occurrence of one string within another

Greetz

Tom
Reply With Quote
Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
paragraph problem dzisaacs XSLT 2 December 31st, 2005 02:49 AM
Table inside paragraph dzisaacs XSLT 3 December 5th, 2005 05:36 AM
get paragraph from database vickyj Classic ASP Databases 2 May 31st, 2005 07:59 AM
Paragraph marks SameerParker Beginning PHP 5 December 14th, 2004 05:25 AM
Help! Empty paragraph tags! abq23 PHP How-To 1 June 15th, 2004 08:57 PM



All times are GMT -4. The time now is 11:33 PM.


Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
© 2013 John Wiley & Sons, Inc.