question

Darkblue-9808 avatar image
0 Votes"
Darkblue-9808 asked Viorel-1 answered

How to open and save a rtf file from inkedit ? Need vb code . Thank you very much !

How to open and save a rtf file from inkedit ? Need vb code . Thank you very much !

office-vba-dev
· 3
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

Maybe I didn't make it clear, so I put my question more clearly:

Question 1: How to open a rtf file by inkedit control ? I need vba code .

Question 2: How to save the rich text of inkedit control as a file ? I need vba code .

Question 3: I need a piece of code to change the line spacing of inkedit control directly ,how to do ?

Thanks to all the respondents and followers!

0 Votes 0 ·

How did you create and use the control, and which Office application are you developing?

0 Votes 0 ·

Create: in Additional controls of office2019。

Develop a small excel program, convenient for my children to learn words and articles.

But since this control was added, when debugging the program, the whole office will often crash and have to restart frequently.

Do you know reason ?

0 Votes 0 ·

1 Answer

Viorel-1 avatar image
0 Votes"
Viorel-1 answered

Try using the TextRTF property of InkEdit control to get the content as a special string. Then use any technique, available in VBA, to write this string to a file. You can use the .rtf extension. Such files can be opened in Word or WordPad too.

You can also load the string from file and assign it to TextRTF property.

To deal with simple text ignoring formatting, use the Text property.


5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.