i just want to write a string to a text file with part of this one in bold.
Is there any way to do it?
An example of what i am asking for:
2021/02/19: this is an example
i just want to write a string to a text file with part of this one in bold.
Is there any way to do it?
An example of what i am asking for:
2021/02/19: this is an example
You cannot use any type of markdown in a .txt
file, using python or not.
You might want to check other files extensions such as .md
files.
test = 'teste.rtf'
out_file = open(test,'w')
out_file.write("""{\\rtf1
This is \\b Bold \\b0\line\
}""")
out_file.close()