You are here: PSPad forum > English discussion forum > Write a custom Code Explorer parser?

Write a custom Code Explorer parser?

Goto Page: Previous1 2 3 Next

#11 Re: Write a custom Code Explorer parser?

Posted by: pspad | Date: 2018-12-11 09:09 | IP: IP Logged

SAS has code parser for code explorer included in PSPad.
If you have use highlighter, change file type for code explorer to ftSAS

Options: Reply | Quote | Up ^


#12 Re: Write a custom Code Explorer parser?

Posted by: bomans007 | Date: 2018-12-11 18:13 | IP: IP Logged

Hi

Thanks for the swift reply!
pspad indeed includes a sas highligher(looked over it), I changed also the 'CodeExplorer file typ' to ftSas (as you recommend).
And now the code explorer loads indeed 3 types: libraries, Data and procedures which is really great.
But I still miss the Macro overview, would it be possible to extend this ftSas code explorer file with this?
The reason is that we include a lot of these macro's in our code(they have a meaningful name) so we can work with it as a 'function' -> This way we are able to structure our code much better.
I believe strongly this would be very convenient for other sas developers as well.

Just a question, no obligation off course.

Frank

Options: Reply | Quote | Up ^


#13 Re: Write a custom Code Explorer parser?

Posted by: pspad | Date: 2018-12-11 19:15 | IP: IP Logged

Hello

I can extend SAS code explore, but I need some source sample and description what you want to see in code explorer window

Options: Reply | Quote | Up ^


#14 Re: Write a custom Code Explorer parser?

Posted by: bomans007 | Date: 2018-12-12 11:00 | IP: IP Logged

Hi
The syntax to define a macro looks as follows:
%macro MacroFunctionName;
...
Code
...
%mend MacroFunctionName;

where MacroFunctionName is the name of the macro definition(which is probably pretty obvious but just to be clear smiling smiley )

below a (more or less)full sas code snippet of a macro function.

/*-----------------------------------*/
/* Check if there was data found */
/*-----------------------------------*/
%macro check_if_edc_found;
%let timenow=%sysfunc(time(), time.);
%put ----- [&timenow] MACRO: check_if_edc_found -----;
%global nr;
data _null_;
set SAVE.EDCdata_all end=end;
if end then call symputx('nr',_N_);
run;
%put SAVE.EDCdata_all: nr of observations=&nr;
%if "&nr"="" %then %do;
data _null_;
file _webout;
/* Set title of webpage */
put "<title>No data found</title>";
[...]
put "</body></html>";
run;
%let abort=1;
%abort;
%end;
%mend;
smiling smileysmiling smileysmiling smileysmiling smiley

Options: Reply | Quote | Up ^


#15 Re: Write a custom Code Explorer parser?

Posted by: pspad | Date: 2018-12-12 11:50 | IP: IP Logged

Will be available in the next build for ftSAS code parser type

Options: Reply | Quote | Up ^


#16 Re: Write a custom Code Explorer parser?

Posted by: bomans007 | Date: 2018-12-12 13:20 | IP: IP Logged

Hey

╱╱┏╮
╱╱┃┃
▉━╯┗━╮
▉┈┈┈┈┃
▉╮┈┈┈┃
╱╰━━━╯
Thanks!!!

Any outlook on when this will be(roughly estimated)?
This way I can temper my colleagues their enthousiasme for a while smiling smiley

Options: Reply | Quote | Up ^


#17 Re: Write a custom Code Explorer parser?

Posted by: pspad | Date: 2018-12-12 13:35 | IP: IP Logged

I will release it this weekend I hope

Options: Reply | Quote | Up ^


#18 Re: Write a custom Code Explorer parser?

Posted by: bomans007 | Date: 2018-12-12 15:29 | IP: IP Logged

wow, I've to say much faster than expected!
Thanks again for the GREAT support!

Options: Reply | Quote | Up ^


#19 Re: Write a custom Code Explorer parser?

Posted by: bomans007 | Date: 2018-12-19 15:22 | IP: IP Logged

not to be willing impatient, just to know the outlook, any idea when you would find time(supposing somewhere next year?) smiling smiley

Options: Reply | Quote | Up ^


#20 Re: Write a custom Code Explorer parser?

Posted by: pspad | Date: 2018-12-19 16:15 | IP: IP Logged

Build with your highlighter was released last weekend. Look at developer forum

Options: Reply | Quote | Up ^


Goto Page: Previous1 2 3 Next





Editor PSPad - freeware editor, © 2001 - 2019 Jan Fiala, Hosted by Webhosting TOJEONO.CZ, design by WebDesign PAY & SOFT, code Petr Dvořák, Privacy policy and GDPR