Message 1 of 6
VBA string replace mtext
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
Hi,
So I have a autocad 2d drawing with a lot of mtext. I have to change all instances of ":" to "-". Doing this manually would take a long time, so I thought of doing it with VBA.
I'm not asking for a full code, but some input on wether this is possible or not? All I have found about this on the internet is about making a new mtext, not editing existing mtexts.
So, my pseudo-code I imagine is something like this
Loop all objects
if(type=mtext)
mtext.text = str_replace(":","-",mtext.text)
end if
This is first time vba in acad. Have done some before in excel and access..
Thanks in advance