Alaska Software Inc. - PostAppEvent xbeBRW_ItemMarked not working - Test31.zip (0/1)
Username: Password:
AuthorTopic: PostAppEvent xbeBRW_ItemMarked not working - Test31.zip (0/1)
Itai Ben-ArtziPostAppEvent xbeBRW_ItemMarked not working - Test31.zip (0/1)
on Tue, 21 Dec 2021 12:30:06 -0800
Why posting ItemMarked does not work?
Attached is a snippet project illustrating the problem.
Andreas Gehrs-Pahl
Re: PostAppEvent xbeBRW_ItemMarked not working - Test31.zip (0/1)
on Fri, 24 Dec 2021 02:19:28 -0500
Itai,

>Why posting ItemMarked does not work?
>Attached is a snippet project illustrating the problem.

Posting xbeBRW_ItemMarked is working just fine. But it isn't used to move 
the cursor to a particular cell, but to react to the left mouse button 
having been pressed in a particular cell. Your example code doesn't use the 
:itemMarked callback slot, so this event has no visible effect.

Besides, "PostAppEvent( xbeBRW_ItemMarked, { aRowCol[1] }, nil, @oBrw )" has 
a couple of issues, like "{ aRowCol[1] }" needs to be a two-element array, 
"{nRowPos, nColPos}" and there is no point in having an "@" in front of the 
"@oBrw".

Just add the following line before your push button, to see that the posted 
event can indeed have an effect:

oBrw:ItemMarked := {| mp1, mp2, obj | MsgBox(Var2Char(mp1))}

BTW, the same is true for xbeBRW_ItemSelected.

Hope that helps,

Andreas

Andreas Gehrs-Pahl
Absolute Software, LLC

phone: (989) 723-9927
email: Andreas@AbsoluteSoftwareLLC.com
web:   http://www.AbsoluteSoftwareLLC.com
[L]:   https://www.LinkedIn.com/in/AndreasGehrsPahl
[F]:   https://www.FaceBook.com/AbsoluteSoftwareLLC
Itai Ben-ArtziRe: PostAppEvent xbeBRW_ItemMarked not working - Test31.zip (0/1)
on Sat, 25 Dec 2021 12:59:25 -0800
Thank you, Andreas.
The underline issue remains unsolved:
Is there a way to navigate the cursor to a specific cell (even when
the current cursor is not in the visible area of the browse)?  In
other word, is it possible to programmatically click a cell?  How?

-Itai
Jim LeeRe: PostAppEvent xbeBRW_ItemMarked not working - Test31.zip (0/1)
on Sun, 26 Dec 2021 06:01:15 +0100
hi,

you need to "navigate" to CELL before

   PostAppEvent ( xbeBRW_ItemSelected,,, oBrowse )

so try this Demo
have a nice Xmas




---
Diese E-Mail wurde von AVG auf Viren gepruft.
http://www.avg.com


BroNavi.zip
Itai Ben-ArtziRe: PostAppEvent xbeBRW_ItemMarked not working - Test31.zip (0/1)
on Sun, 26 Dec 2021 22:23:24 -0800
Jim,
Your code is working only if the browser cursor is in the visible
area.  If the browser cursor is not visible, oBrowse:rowPos is zero,
and Select_BrowseLine() fails.

(Try it on a browser withe a vertical bar where the cursor (marked
line) is not visible; either above or below the displayed lines).

-Itai
Jim LeeRe: PostAppEvent xbeBRW_ItemMarked not working - Test31.zip (0/1)
on Mon, 27 Dec 2021 09:33:53 +0100
hi,

include oBrowse:PanRight() / oBrowse:PanLeft() BEFORE xbeBRW_Navigate,
XBPBRW_Navigate_*

         IF oBrowse:CursorMode == XBPBRW_CURSOR_CELL
            oBrowse:PanRight()
            PostAppEvent ( xbeBRW_Navigate, XBPBRW_Navigate_NextCol,,
oBrowse )

         IF oBrowse:CursorMode == XBPBRW_CURSOR_CELL
            oBrowse:PanLeft()
            PostAppEvent ( xbeBRW_Navigate, XBPBRW_Navigate_PrevCol,,
oBrowse )



---
Diese E-Mail wurde von AVG auf Viren geprüft.
http://www.avg.com