|
Post by cyberchipz on Apr 8, 2022 16:53:39 GMT
If one clicks on a line of code and highlights that line; right click brings up a lot of options. Would it be possible to add an option to display the value of any %VARIABLE% in that line? When debugging, since MMM retains the values of the variables; and the display in the variable list is limited; it would be EXTREMELY helpful to be able to see the value of a variable.
I often step through the code one line at a time; this is very useful. However, when it comes to knowing the value of that variable it seems I have to use MESSAGE to display that value. If we could add a simple command just to display any variable that starts and ends with a % in a pop up, or display the value somewhere on the screen. That would really speed up a tough debug on something where it's hard to tell what is going wrong. Yes, there is debug ON and OFF but, often I just need to know one variable's value to do this.
|
|
|
Post by Steve on Apr 8, 2022 23:57:29 GMT
Hi cyberchipzImproving variable use and debugging has been on my todo list for a long time. I’m not sure if an addition to the right click menu for the line is the right way to go here at the risk of making it too cluttered. I’m thinking of a seperate window that can be opened that has all the variable information. This window will be updated in real time as variables are added and changed. Named variables when they are created are added to there respected type array so it would just be simply monitoring these arrays and outputting the values to some sort of list on this window page. Thanks for the idea here. I’ll have a look at the code and might be able to get something simple out to the Patreon page as a pre-release and something nice out for the next update. Cheers, Steve.
|
|
|
Post by cyberchipz on Apr 15, 2022 15:00:34 GMT
I will keep my eye on the Patron page for a pre-release; and eagerly give the Alpha or Beta test it needs! :-) I'm sure whatever you can do will be helpful; I am one of those who troubleshoots by monitoring variable actions and currently this is not... feasible is not the right word... cumbersome is more like it.
I just thought right clicking would give a quick temporary solution to the issue.
I'm intrigued by your use of the word ARRAY if one could easily select which type one wanted to examine. Or perhaps, a little more advanced, a way to select which specific variables one wanted to show in the report; if one did not need to select this every time would be very useful. Similar but perhaps simpler than the type used in VB.
I think right-click on a line would be useful for when one needed only the variables in a particular line for a quick spot examination of those variables. But, having a more robust variable list would also be very helpful. :-)
I would think showing every variable in the report; (cough) I have a 1000+ lines of code in one macro; would actually make the report cumbersome. I would find any type of debug check helpful; one thing I encounter all the time is when the interface to whatever app I'm using modifies the locations of the click zone. Sometimes these move; and I need to redefine the X, Y location of clicks. This is just one need I experience. Often I add a line mousemovement to move the cursor to that location so I can tell if any migration of the location occurs during runtime; and the option to run *that* line of code is the current method I use to determine if I need to change it. Targeting a stop point in the code (or selecting several lines) ; and running those specific lines (multiple) instead of only a single line would also be useful for troubleshooting; but I would most assuredly request the variable display as my first choice. :-) (sigh) Give a mouse a cookie! ;-)
Thanks for your response.
|
|