trichview.com

trichview.support




Re: GetItemAtEx


Return to index


Author

Message

Christian Kirchhoff

Posted: 10/02/2002 14:36:18


Hallo,


thanks for the reply. I weren't able to solve that problem, yet.


First: as you can see in my exemplary code, I called this procedure as a

procedure of rv.RVData. The appropriate line of code is:

MyRichViewEdit.RVData.GetItemAtEx(X,Y,RVData,ItemNo,Offs);

Delphi's compiler says that this procedure is not defined.


If I was just missing an additional parameter, Delphi's compiler would have

told me that. Therefore I presume that this procedure does not exist in version

1.5.4.


I searched the whole source code of the TRichView components for the procedure

GetItemAtEx and it couldn't be found. Therefore I kindly ask you to think

about this problem again and tell me what I could have done wrong.


Thanks in advance,


Christian Kirchhoff


"Sergey Tkachenko" <svt@trichview.com> wrote:

>This procedure is still there.

>But this procedure is rv.RVData, not of rv. It has additional parameter,

>which should be False in this case.

>

>

>> Hello,

>>

>> some days ago I found some code that allows to move the caret pos while

an

>> object ios dragged onto a TRichViewEdit component. Basically in the

>> OnDragOver event handler a WM_SETCARETPOS is triggered which eventually

>> calls a procedure similar to this:

>>

>> procedure MoveCaretTo(X, Y: Integer);

>> var

>>   RVData: TCustomRVFormattedData;

>>   ItemNo, Offs: Integer;

>> begin

>>   inc(X, MyRichViewEdit.HScrollPos);

>>   inc(Y, MyRichViewEdit.VScrollPos*MyRichViewEdit.VSmallStep);

>>   MyRichViewEdit.RVData.GetItemAtEx(X,Y,RVData,ItemNo,Offs);

>>   if ItemNo<0 then

>>     exit;

>>   if RVData is TRVTableCellData then begin

>>     TRVTableCellData(RVData).Edit;

>>     RVData := TCustomRVFormattedData(RVData.GetRVData);

>>   end;

>>   RVData.SetSelectionBounds(ItemNo, Offs, ItemNo, Offs);

>>   RVData.Invalidate;

>> end;

>>

>> When I was testing this, I used an unregistered version of TRichView.

>After

>> installing the registered version (1.5.4), the procedure "GetItemAtEx"

>> cannot be found any more. Is there a workaround?

>>

>> Regards,

>>

>> Christian Kirchhoff

>>

>>

>

>





Powered by ABC Amber Outlook Express Converter