Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
How to get a list of all AutoText files in the left pane
#83
I finally got it.  Smile

My programming level is limited and I can only use the most clumsy method.

I hope someone can provide a better way 
Heart

Thank you very much for the help of kevin. Without your help, this Function is impossible.  Heart Heart

 
Code:
Copy      Help
case 14 ;;Edit
_s.getwintext(id(5 hDlg))
str items=sub.gotoitemedit(_s)
items.findreplace(":sub." "     ")
items.findreplace(";;" "     ")
_i=ListDialog(items "Which item to Edit" "Select item")
if(_i=0) ret
mac+ _s
int c=GetQmCodeEditor
out _i

SendMessage(c SCI.SCI_GOTOLINE _i 0)
int cp=SendMessage(c SCI.SCI_GETCURRENTPOS 0 0)
cp+12
SendMessage(c SCI.SCI_GOTOPOS cp 0)


 
Code:
Copy      Help
#sub gotoitemedit
function~ ~name

str pattern="(?:.*\:sub.Sub\d.*)"

_s.getmacro(name 0)
str ss d
int i
ARRAY(str)+ aid_S
foreach ss _s
    findrx(ss pattern 0 4 aid_S)
    for i 0 aid_S.len
        d.formata("%s[]" aid_S[0 i])
ret d.trim


Messages In This Thread
RE: How to get a list of all AutoText files in the left pane - by win - 04-18-2019, 07:07 AM

Forum Jump:


Users browsing this thread: 1 Guest(s)