Add note

Add note

Giuseppe_Origine9S5JK
Explorer Explorer
625 Views
5 Replies
Message 1 of 6

Add note

Giuseppe_Origine9S5JK
Explorer
Explorer

Hi.

I need to add a simple text note on my drawings using iLogic. For example "Paint" (with the possibility to box it).

I have no experience with iLogic, so If anyone can post a rule I can modify it would be great!

0 Likes
Accepted solutions (1)
626 Views
5 Replies
Replies (5)
Message 2 of 6

JelteDeJong
Mentor
Mentor
Accepted solution

Is this what you are looking for?

Dim doc As DrawingDocument = ThisDoc.Document
Dim sheet As Sheet = doc.ActiveSheet

Dim insertPoint = ThisApplication.TransientGeometry.CreatePoint2d(1, 1)
Dim note = sheet.DrawingNotes.GeneralNotes.AddFitted(insertPoint, "Painted")

note.ShowTextBorder = True

Jelte de Jong
Did you find this post helpful? Feel free to Like this post.
Did your question get successfully answered? Then click on the ACCEPT SOLUTION button.

EESignature


Blog: hjalte.nl - github.com

0 Likes
Message 3 of 6

Giuseppe_Origine9S5JK
Explorer
Explorer

That is brilliant!

How do I choose text size and font?

0 Likes
Message 4 of 6

JelteDeJong
Mentor
Mentor

That is a bit more difficult. The easiest way is to create a note and run the following rule.

Dim note As GeneralNote = ThisApplication.CommandManager.Pick(SelectionFilterEnum.kDrawingNoteFilter, "Select note")
logger.Info(note.FormattedText)

It writes the formatted text to the iLogic log. Then you can use that in the first rule as the text.

Jelte de Jong
Did you find this post helpful? Feel free to Like this post.
Did your question get successfully answered? Then click on the ACCEPT SOLUTION button.

EESignature


Blog: hjalte.nl - github.com

0 Likes
Message 5 of 6

Giuseppe_Origine9S5JK
Explorer
Explorer

I thought it was easier, hence why I said I just need "painted". I acually need longer rentences to appear in a certain way, for example:


FABRICATION NOTES
FABRICATION WORKMANSHIP SHALL BE TO AS/NZS 1554.6 OR GREATER.
SHARP EDGES AND BURRS TO BE REMOVED.
DXF PROVIDED FOR PROFILE CUTTING. DRAWING SHALL BE USED FOR CRITICAL MEASUREMENTS.
MACHINING OPERATIONS TO BE COMPLETED AFTER FABRICATION AND WELD EXAMINATION.

Is there a guide I can consult with all the programming language options?

0 Likes
Message 6 of 6

A.Acheson
Mentor
Mentor

Hi @Giuseppe_Origine9S5JK 

I would suggested to use formatted text sparingly unless you need to weave in parameter texts through the paragraphs. It is much easier to set a style in the style library and just call up the use of the style by code. 

This way you can adjust this globally if needed. Of course this mighten work for custo.ixation such as bold etc bit at least it gets you partially there. 

If this solved a problem, please click (accept) as solution.‌‌‌‌
Or if this helped you, please, click (like)‌‌
Regards
Alan
0 Likes