Author Topic: remove Indention tap stop position from mtext  (Read 3217 times)

0 Members and 1 Guest are viewing this topic.

Humbertogo

  • Guest
remove Indention tap stop position from mtext
« on: April 18, 2006, 07:30:38 AM »
Is there a way to remove Indention tap stop position from mtext, the indention position is not always the same.

Using vba

for example:
 \pi-0.875,l0.875;1.HALLO TEST
Need to remove \pi-0.875,l0.875;  from the Mtext the indention position is not always the same.

joseguia

  • Guest
Re: remove Indention tap stop position from mtext
« Reply #1 on: April 18, 2006, 09:14:21 AM »
Is there a way to remove Indention tap stop position from mtext, the indention position is not always the same.

Using vba

for example:
 \pi-0.875,l0.875;1.HALLO TEST
Need to remove \pi-0.875,l0.875;  from the Mtext the indention position is not always the same.


Hmm - not sure but it sounds like you want something like this?

Code: [Select]
Function FndText(strString As String)
  On Error GoTo Err_Control

  Dim Lng As Integer
  ' Searches string for ";" and returns everything to the Right
  ' If no ";" found returns original string
 
  Lng = InStr(strString, ";")
    If Lng > 0 Then
     
      FndText = Right(strString, (Len(strString) - Lng))
    Else
      FndText = strString
    End If

Exit_Here:
  Exit Function
Err_Control:
  Select Case Err.number
  'Add your Case selections here
    Case Else
    MsgBox Err.Description
    Err.Clear
    Resume Exit_Here
  End Select
End Function

sample use:

Code: [Select]
FndText "\pi-0.875,l0.875;1.HALLO TEST"

returns:
1.HALLO TEST

joseguia

  • Guest
Re: remove Indention tap stop position from mtext
« Reply #2 on: April 18, 2006, 09:15:22 AM »
Something tells me you need more than just that .. right?

Humbertogo

  • Guest
Re: remove Indention tap stop position from mtext
« Reply #3 on: April 18, 2006, 09:40:41 AM »
Thanks ,
i will do some more investigation

Bryco

  • Water Moccasin
  • Posts: 1883
Re: remove Indention tap stop position from mtext
« Reply #4 on: April 18, 2006, 10:59:18 AM »
What version Acad Humbertogo?
On acad 2006 I get
\pi-0.75,l0.75,t0.75;1. vhkas\P2.   oiibdf\P3.  qwe
I'm thinking the | and the t do some magic to set the tab spacing.
You don't seem to have that part.
I know on 2000 with a funky text like architxt I could never get it nice
but 2006 is always good.

Humbertogo

  • Guest
Re: remove Indention tap stop position from mtext
« Reply #5 on: April 19, 2006, 01:34:06 AM »
Quote
What version Acad Humbertogo
We use Autocad Mechanical 2006