Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Problem when creating a new line #155

Open
TirOFlanc opened this issue Jan 8, 2021 · 4 comments
Open

Problem when creating a new line #155

TirOFlanc opened this issue Jan 8, 2021 · 4 comments

Comments

@TirOFlanc
Copy link

TirOFlanc commented Jan 8, 2021

Hi,

I have encountered several problems that I think are related.

When I create a new line, for example MsgBox or AssignVariable, when I validate by clicking on the OK button, this new line doesn't appear, as if I had cancelled, so I have to repeat it until it works (sometimes it does it several times in a row) [now I spam the 'Apply' button].

When there is a function, the new line created in the main macro may end up at the end of the function, so I cut and paste it into the main macro, but it's strange. (see screen)

image
image

Here, my selection was on 'EndIf' of the 'Main' macro to add a line just above it.

I clicked on the 'Variables / Arrays' button, entered 'ORDER' in the 'Output Variable' field, then '%A_LoopField%' in the 'Value' field and finally, I clicked on the 'Ok' button (I had unchecked the 'Expression / Array' box).

As this new line didn't appear, I went to the 'CloseBoards()' function tab and found it there.

Well, I don't know what to add to make it easier for you.

If you have any questions, don't hesitate.

Have a nice day !

@Pulover
Copy link
Owner

Pulover commented Mar 16, 2021

I could not reproduce this problem. If you can give me a step-by-step of how to reproduce it can take a look.

@higrm
Copy link

higrm commented Jun 15, 2022

I have experienced the same issue myself. It has usually happened when I tried to insert a new command into existing code, such as a new If statement or simply a new MSG. After I click OK, the line doesn't appear, but when I happened to look at my last tab of code, the added IF statement or the MSG was tagged onto the end of this other code. After the return. I cannot reproduce it on a regular basis, but whenever I notice my new line doesn't show up, the first thing I do is click through my other tabs and make sure it didn't get added to the bottom of another one. Using Apply does seem to be safer than clicking OK after creating a new line.

@TirOFlanc
Copy link
Author

Ok, that's good to know.
I will use this method, thanks.

@higrm
Copy link

higrm commented Aug 27, 2022

What I will try the next time I need to make an edit to any of my existing macros is create a new right-most tab that just contains a single line of code, perhaps just a pause. Then when I make my edit, even if the code mysteriously shows up on the right-most tab, it won't effect a needed part of my macro and will be easier to find. Originally, I said the newly added code would be at the end of the right-most macro. In fact, the code tries to show up on the matching line number where it should have been added on the desired tab. E.g. if I want to add a msg on line 14 and it doesn't appear, looking at the right-most tab would have the new msg instruction on line 14. But again, this isn't easy to reproduce, but does happen 20% of the time, maybe a bit less, but I think more than 10% of the time. I'll do some testing to get better frequency data.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants