Forums › Forums › SIMPOL Programming › EditSelection
- This topic has 5 replies, 3 voices, and was last updated 11 years, 12 months ago by Michael.
- AuthorPosts
- April 16, 2012 at 6:37 pm #98Reto HuberMember
Is there in SIMPOL a command for Superbase.EditSelection = 0?
May 8, 2012 at 10:02 pm #1599MichaelKeymasterOn 16/04/2012 19:37, Reto Huber wrote:
> Is there in SIMPOL a command for Superbase.EditSelection = 0?
>Off-hand, I can't think of one. This is the default Windows behavior as I recall, and that is how the controls work.
Ciao, Neil
May 9, 2012 at 4:51 pm #1933JD KromkowskiParticipantIn theory, you create a function as part of Ongotfocus.
But, I'm not sure 0, is totally the default.
If you enter a field, EditSelection = 0 is what it looks like.
But if you then tab through fields, EditSelection = -1 is what it looks
like.But that brings up a related question.
Copy, Cut, Paste
Right now even in "Personal" you don't have functions attached to these
menu items. Although, I've been a right-mouse man for the decades of
the windows experience; being able to hook this up I think is kind of
essential to be taken seriously.What exactly are the equivalents of COPY FROM and COPY TO or
EditCopy()
EditCut()
EditPaste()It seems like it should be something like
|wxclipboardputdata| (/|/||/|//|/||/|/Var.control.gettext()) for the
copy functionMaybe for paste?
string clipboard|
wxclipboardgetdata| (clipboard)
Var.control.settext(clipboard)But how do you tell where the focus is from the menu?
||Since it hasn't been implemented in Personal, it obviously more
complicated.
api dll calls?On 5/8/2012 6:02 PM, Neil Robinson wrote:
> On 16/04/2012 19:37, Reto Huber wrote:
>> Is there in SIMPOL a command for Superbase.EditSelection = 0?
>>
> Off-hand, I can't think of one. This is the default Windows behavior as I recall, and that is how the controls work.
>
> Ciao, NeilMay 16, 2012 at 10:20 pm #1934MichaelKeymasterOn 09/05/2012 17:51, John D Kromkowski wrote:
> In theory, you create a function as part of Ongotfocus.
>
> But, I'm not sure 0, is totally the default.
>
> If you enter a field, EditSelection = 0 is what it looks like. But if you then tab through fields, EditSelection = -1 is what
> it looks like.
>
> But that brings up a related question.
>
> Copy, Cut, Paste
>
> Right now even in "Personal" you don't have functions attached to these menu items. Although, I've been a right-mouse man
> for the decades of the windows experience; being able to hook this up I think is kind of essential to be taken seriously.Actually, the standard Windows defaults work in the fields Ctrl+C, Ctrl+X, Ctrl+V; this is built into the Windows controls. The
reason the menu items aren't working is because in Superbase they actually have a different function. They copy an entire record
to the clipboard, and paste an entire record. I simply haven't gotten around to writing this code yet, but probably in the next
release.> What exactly are the equivalents of COPY FROM and COPY TO or
>
> EditCopy() EditCut() EditPaste()
>
>
> It seems like it should be something like
>
> |wxclipboardputdata| (/|/||/|//|/||/|/Var.control.gettext()) for the copy function
>
> Maybe for paste?
>
> string clipboard| wxclipboardgetdata| (clipboard) Var.control.settext(clipboard)
>
> But how do you tell where the focus is from the menu?Exactly right, and in fact that is why I haven't bothered yet. I suspect I would check the form.focuscontrol to see which control
has focus, and if it is an edit control then I would do the action on what is selected in the control using .getselection().> ||Since it hasn't been implemented in Personal, it obviously more complicated. api dll calls?
No more an issue of priority.
Ciao, Neil
May 18, 2012 at 3:21 pm #1938JD KromkowskiParticipantif the standard windows keys work, i.e.
Ctrl+C, Ctrl+X, Ctrl+V
Wouldn't be the simpliest to simple hook up the menus to a function that uses sendkeys() for which there is already a library?
JDK
May 23, 2012 at 11:35 am #1941MichaelKeymasterOn 18/05/2012 16:21, John D Kromkowski wrote:
> if the standard windows keys work, i.e.
>
> Ctrl+C, Ctrl+X, Ctrl+V
>
> Wouldn't be the simpliest to simple hook up the menus to a function that uses sendkeys() for which there is already a library?The problem isn't in trapping the key presses, I just haven't written the code yet that copies records and pastes them.
Also, I avoid using sendkeys for mainstream code where possible, since it is a Windows-only solution.
Ciao, Neil
- AuthorPosts
- You must be logged in to reply to this topic.