Jump to content

Recommended Posts

Posted

Unigui Vdersion: 1.0.0.1412

 

Only 1 step. Put that code in extevents

 

unidbgrid -> clientevents->unievents:

 

function beforeInit(sender, config)
{
    config.viewConfig.enableTextSelection = true;
}

Posted

Hi,

 

how about in browse mode?

 

OK, let's look at this rough approach

 

1. UniMemo2:

Left = -1000

 

2. UniDBGrid -> ClientEvents -> ExtEvents -> function afterrender:

function afterrender(sender, eOpts)
{
    var me = sender,
        tempCopyEl = MainForm.UniMemo2;
    me.el.addKeyMap({
        key: 67,
        ctrl: true,
        fn: function() {
            tempCopyEl.setValue(me.getSelectionModel().getSelection()[0].data[1]); // value of the second cell, the possibility of arbitrary copying can be expanded here!
            tempCopyEl.focus();
            tempCopyEl.selectText();

            document.execCommand('copy');
        }
    })
}

Now try

 

Best regards,

Posted

Sorry. Your code is not clear for me

 

Is not possible select text like in any other web page?

 

I've also tested with:

Clipboard.AsText := SomeStringData_Variable; 

But don't work in isapi dll, only works in standalone.

Posted

Hi,

 

Is not possible select text like in any other web page?

 

Sorry, for example?

 

 

I've also tested with:
Clipboard.AsText := SomeStringData_Variable; 

But don't work in isapi dll, only works in standalone.

 

In web programming, forget about this approach

Posted

For example?.

 

Enter in any page, ant try to select text, left button of mouse and mantain le left button pressed until you ends selection

 

do ctrl-c

 

go to notepad and paste

Posted

Ok.

 

The problem is in my grids:

 

readonly=true

dgediting=false

 

If I put readonly false and dgediting true, works, and the script in your post #12 is not needed.

 

This is not a good solution for me.

 

Any other idea?

 

Thanks.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...