Message 1 of 4
VBA tri le TXT in bloc dans listbox idem bloc écran
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
hello
in autocad block 4 line TXT
TXT1 (handle # 3)
TXT2 (handle # 2)
TXT3 (handle No. 4)
TXT4 (handle # 1)
When I recuper the string in a combobox it puts me in the order of handle
TXT4,2,1,3
I then I want in the order of the line screen TXT1,2,3,4
Thank you for your help
********
Bonjour
Dans le bloc autocad 4 lignes de TXT
TXT1 (handle N°3)
TXT2 (handle N°2)
TXT3 (handle N°4)
TXT4 (handle N°1)
Quand je recupere le string dans une combobox il me le met dans l'ordre du handle =>Ligne 4,2,1,3
alors que je je veux dans l'ordre de l'écran ligne 1,2,3,4
Merci pour votre aide
Public Sub LireTxt() Dim objBloc As AcadBlock Dim objEnt As AcadEntity Dim objEntTxT As as AcadText ThisDrawing.Utility.GetEntity objBlocRef, Pt1, "Sélectionnez le bloc à modifier :" Set objBloc = ThisDrawing.Blocks(objBlocRef.Name) For Each objEnt In objBloc If objEnt.ObjectName = "AcDbText" Then ListBoxTxt.AddItem objEntTxT.textString Endif Next End Sub