CGDevTools Forum

Welcome to the Official CGDevTools Support Community Forums.

How to capture the cursor location within a TIWCGJQMemoEx

by MCarver » 17 May 2016 21:01

CG Gurus,

I have a need to insert text into a TIWCGJQMemoEx at a particular location. How would I accomplish this task?

I am confident that
memoPlainText.Lines.Insert(AIndex, '{%TAG_NAME%}' );
will insert the text into the proper location.

The question is how do I capture the cursor location within the MemoEx when an Async event inserts the subject text? I was thinking of using the OnAsyncExit event, but what MemoEx property captures where the cursor is currently located?

Regards,
Monte Carver
MCarver
 
Posts: 48
Joined: 27 Sep 2013 19:15

by Alexander Bulei » 18 May 2016 17:35

Hi MCarver,

For what you need it?

You can change the text in server side and then call AjaxReRender, or in client side, but it require the javascript knowledge.

Best Regards.
Group: Developers | Support Team

  • info [at] cgdevtools.com - General information
  • sales [at] cgdevtools.com - Sales department
  • support [at] cgdevtools.com - Product and Technical Support
User avatar
Alexander Bulei
Site Admin
 
Posts: 3635
Joined: 15 May 2012 08:52
Location: Mealhada, Portugal

by MCarver » 18 May 2016 18:39

Alexander,

From your response, it sound like you don't understand my question. So I will rephrase.

What properties in the CGMemoEx can I capture, that determines where the cursor is located within the CGMemoEx when a given Async event occurs? I am looking for something like Line.Offset, or Line.ItemIndex which allows me to determine where to insert a given tag.

Thank you for your support.

Regards,
Monte
MCarver
 
Posts: 48
Joined: 27 Sep 2013 19:15

by Alexander Bulei » 19 May 2016 09:11

Hi MCarver,

From your response, it sound like you don't understand my question. So I will rephrase.


I understand your question, just dont understand the reason...

Anyway, it can be done with javascript code, there is no properties for this purpose.

Best Regards.
Group: Developers | Support Team

  • info [at] cgdevtools.com - General information
  • sales [at] cgdevtools.com - Sales department
  • support [at] cgdevtools.com - Product and Technical Support
User avatar
Alexander Bulei
Site Admin
 
Posts: 3635
Joined: 15 May 2012 08:52
Location: Mealhada, Portugal

by MCarver » 19 May 2016 16:15

Alex.

Thanks for your response.

The reason is to allow the user to insert tags having the form "{%TAG_NAME%}" into the given MemoEx, where the tag is inserted where the cursor was last placed. This behavior would mirror very much like the CGHtmlEditor. When one inserts a given property within the editor, it drops the property where the cursor is located. I am looking to mirror that ability somewhat by simply dropping a preformed tag into a MemoEx.

I was simply looking for an easy and painless solution to this task.

Regards,
Monte Carver
MCarver
 
Posts: 48
Joined: 27 Sep 2013 19:15

by Alexander Bulei » 19 May 2016 16:32

Hi MCarver,

As I said before:

it can be done with javascript code, there is no properties for this purpose.


This request is out of our standard support (special functionality), so you need the premium support ticket.
Send us your email (order) to check your the available tickets.

Best Regards.
Group: Developers | Support Team

  • info [at] cgdevtools.com - General information
  • sales [at] cgdevtools.com - Sales department
  • support [at] cgdevtools.com - Product and Technical Support
User avatar
Alexander Bulei
Site Admin
 
Posts: 3635
Joined: 15 May 2012 08:52
Location: Mealhada, Portugal


Return to JQMemoEx

cron

Who is online

Users browsing this forum: No registered users and 3 guests

Contact Us.