Não entendio muito bem, mas vou te mandar um editor que fiz em no curso de vb que nam lembro quando foi que fiz, mas ele utiliza um richtextbox para haver a quebra de linha.
No seu caso é só vc anexar ele no seu projeto !!
Ps.: como vc não deixou e-mail para resposata vou postar aqui mesmo e vc tera que adivinhar os objetos!!!
Option Explicit
Private Sub abrir_Click()
On Error GoTo deu_erro
cdl_caixas.ShowOpen
If cdl_caixas.FileName <> "" Then
' abre o arquivo p/ leitura
Open cdl_caixas.FileName For Input As #1
' variaveis auxiliares
Dim linha, todotexto
Do While Not EOF(1)
' le uma linha do arquivo
Line Input #1, linha
todotexto = todotexto & linha & Chr(13) & Chr(10) ' ou vbcrlf
Loop
Close #1 ' fecha o arquivo
novo_Click
mdi_editor.ActiveForm.txt_texto.TextRTF = todotexto
End If
Exit Sub
deu_erro:
MsgBox Err.Description
End Sub
Private Sub cascata_Click()
mdi_editor.Arrange (vbCascade)
End Sub
Private Sub colar_Click()
' testar o que tem na área de transferencia
If Clipboard.GetFormat(vbCFRTF) Then
txt_texto.SelRTF = Clipboard.GetData(vbCFRTF)
ElseIf Clipboard.GetFormat(vbCFText) Then
txt_texto.SelRTF = Clipboard.GetData(vbCFText)
End If
End Sub
Private Sub copiar_Click()
' envia o texto selecionado para a área de tranferencia
Clipboard.SetText txt_texto.SelRTF
End Sub
Private Sub cores_Click()
cdl_caixas.ShowColor
txt_texto.SelColor = cdl_caixas.Color
End Sub
Private Sub fontes_Click()
cdl_caixas.Flags = &H3 Or &H100
cdl_caixas.ShowFont
With txt_texto
.SelFontName = cdl_caixas.FontName
.SelFontSize = cdl_caixas.FontSize
.SelBold = cdl_caixas.FontBold
.SelItalic = cdl_caixas.FontItalic
.SelUnderline = cdl_caixas.FontUnderline
End With
End Sub
Private Sub Form_Resize()
With txt_texto
.Top = 0
.Left = 0
.Height = ScaleHeight
.Width = ScaleWidth
End With
End Sub
Private Sub lado_Click()
mdi_editor.Arrange (vbTileVertical)
End Sub
Private Sub localizar_Click()
Dim trecho As String
Dim posicao As Long
trecho = InputBox("Qual texto a procurar", "Pesquisa")
If Trim(trecho) <> "" Then
' pesquisa o trecho no texto
posicao = InStr(UCase(txt_texto.Text), UCase(trecho))
If posicao > 0 Then ' encontrou
'seleciona o texto
txt_texto.SelStart = posicao - 1
txt_texto.SelLength = Len(trecho)
txt_texto.SetFocus
Else
MsgBox "trecho não encontrado", vbInformation, "Resultado!"
End If
End If
End Sub
Private Sub novo_Click()
' variavel que cria uma instânci (clone)
' do form de texto
Dim novodoc As New frm_texto
' exibe o novo documento
novodoc.Show
End Sub
Private Sub organizar_Click()
mdi_editor.Arrange (vbArrangeIcons)
End Sub
Private Sub recortar_Click()
Clipboard.SetText txt_texto.SelRTF
txt_texto.SelRTF = ""
End Sub
Private Sub salvar_Click()
On Error GoTo deu_erro
cdl_caixas.ShowSave
If cdl_caixas.FileName <> "" Then
' abre o arquivo p/ leitura
Open cdl_caixas.FileName For Output As #1
' grava o texto no arquivo
Print #1, txt_texto.TextRTF
' fecha o arquivo
Close #1
End If
Exit Sub
deu_erro:
MsgBox Err.Description
End Sub
Private Sub sobre_Click()
frmAbout.Show 1
End Sub