how to change output mode to input mode (fields)in updating the database file using rpgle as400 - function-pointers

I've written a program in #rpgle along with the 2 records work screen in display file.
First record will display the main-screen-of-company, which takes input as:
emp id indicators= f3: exit f6: accept.
After pressing the f6, it goes to the second record
indicators= f3: exit f12: cancel f7: modify f8: delete f6: accept
& fields are in output mode.
When I press f7 to update the fields, which are in o/p non editable mode should get change into editable mode.
How to do that?

Try protecting the field with the same indicator associated to the function key.
A R REC001 TEXT('Record')
A CF07(07)
A FIELD R B 10 3
A N07 DSPATR(PR)

Related

VSCode select next occurrence of variable

In VSCode on Mac, I can use the keyboard shortcut Cmd + D to select the next occurrence of my currently highlighted text.
For example, if I highlight the variable order on line 1 in the below code, hitting Cmd + D causes order_form on line 2 to be partially highlighted, and hitting Cmd + D again causes order to be highlighted on line 3.
1. order = "Some string"
2. order_form = create_form()
3. return "Here is your order: " + order
However, I just want to select the actual variable order on lines 1 and 3 (i.e. excluding the text that is part of the variable order_form)
What keyboard shortcut can I use to just highlight the actual variables named order on lines 1 and 3?
The Ctrl+D functionality uses the current Find widget settings "behind the scenes" - whether that Find widget is visible or not.
So you would get the behaviour you want if the Whole Word option was enabled in that Find widget first before you began Ctrl+D'ing.
Alternatively, as the demo below shows when you place your cursor on the word you want order you can then hit Alt+W which will toggle the Whole Word option on and off. Note the little box that opens in the top right of the editor that shows only the Find options.
Then all your find next occurrences with Ctrl+D will find only what you want with that Whole Word option still enabled.
If you want to skip any of those occurrences, you can use the command
Add Selection To Previous Find Match
editor.action.addSelectionToPreviousFindMatch
(which you would have to make your own keybinding for). Just trigger that command to skip the next possible match - so follow this order:
Ctrl+D on the first order
Alt+W to enable whole word matching
trigger the command Add Selection To Previous Find Match
Ctrl+D to select the next order
It sounds like a bit of a hassle but they are common commands to know - to skip the next match and to toggle Whole Word matching.
[That little box that opens with the Find options is a little glitchey in that it seems to sometimes also enable the case sensitivity option as well - which isn't a problem in your example.]

VsCode Vim Extension command to enter insert mode

I am wondering what is the vim command that one can use to enter the insert mode? In other words, what command is executed when you press "i" from normal mode. I want to use this command to construct custom actions using "extension.multiCommand.execute". In particular, I want to bind cmd+D in visual mode such that after selecting a text, pressing cmd+D will first put me in the insert mode without changing the selection and then will add another cursor each time I press cmd+D to the next found instance of the selected text.
Thanks

Notepad++: Record macro will not remember steps taken within Column Editor

I'm trying to remove duplicates in an document. This includes both of entries it finds without moving the order of the entries.
Example
A
B
C
Random info
B
C
Results
A
Random info
I found how to do that via this link and following Method 2. Problem is when recording the macro it doesn't record steps I take when using Column editor. Does anyone know how to fix this or a different method? Thank you
Unfortunatelly, column editor and other plugin actions cannot be recorded because of a bug in notepad++.
However, you can still achieve what you want without using column editor.
Use this macro:
Start macro recording
Control + H to launch "search & replace":
Find what: ^([^\n]*)$\R([\s\S]*?)\R?+^\1$
Replace by: \2
Replace All
Place the cursor at the first position of the file (line 0, character 0) Use the mouse or use Control + G, then 0
Stop macro recording
Now, run your macro with run a macro multiple times and select run until the end of file.
Here is a demo of the process:

How to list out previous command arguments input to minibuffer in Emacs?

Often I need to do replacement with text. I am looking for a way to avoid repeatedly input replacement text.
For example, firstly, I replaced a with b in text;
Secondly, I replaced c with d.
Thirdly, I need to replace a with b again. However, Emacs only store last replacement as default argument.
What is the way to list previous replacement argument, i.e. a to b?
The responses you give to M-% (and other commands that get input from the minibuffer) are kept in the history. Hit the "Up" key to see them.
As the search texts and the replacement texts are kept in the same history, in your case above the history would be a, b, c, d. So, when prompted for the search text, you'd need to hit "Up" four times to come back to a. The history would then change to a, b, c, d, a, so to get back to b as replacement text you'd again need to hit "Up" four times.
You can use M-p instead of "Up" if you prefer.
If you want to see what the previous minibuffer values were without invoking another command you can directly inspect the minibuffer-history variable: C-h v minibuffer-history. This will list all of the values together with the description of this variable.

AutoHotKey script activates only on numpad enter

My script is only activating when I press the numpad enter, is it possible for it to work if I press the big enter?
Here is what I have, when I type test + numpad enter then it invokes ctr+shift+u
:*:test`n::test^+u
I need the other enter to work or both if possible.
Thanks
I tried this:
:*:test`n::bob
And it types bob no matter which enter key I push. If you use n, that doesn't necessarily indicate that you are pushing anyenterkey - it just means you are inserting a carriage return - so eitherenter` key will do that. But your text area must be able to receive and insert a carriage return.
That means, that if you are working in a single-line text box, it can't receive a carriage return, in which case, using `n won't work for you.
You might also assure that the active window is able to receive ^!u and do something with that.