Hi
At 2018-09-26 21:46:57 GMT+2, we have updated V 2.28.0-beta.7
installation on our site with improved focus
on form's lowest tabindex control in Bootstrap mode.
Please download it again if you want to test this latest version.
Hi Thierry
With beta 7, in handling the LostFocus () of a TextBox object I get the following error message when the VALID () method of the TextBox object contains code that calls an THISFORM.wForm () 09/27/18 02:26:39 PM awajax.lSuccess(.f.): Erreur détectée à la ligne n° 14,125 de la méthode 'awajax.useraction' "FoxInCloud n'a pas pu traiter cette requête : Awajax.useraction() - Erreur dans l'exécution de la méthode 'prescripteur_scx.prescrip.Lostfocusinet(m.this.uValue)' : Méthode ou procédure osiblingtabindex() : erreur n° 107 ("Opérateur et opérande incompatibles") à la ligne n° 652 Paramètres reçus :
- Valeur : "rigal"
- Objet : prescrip
Événement : blur Méthode : aucun Propriété : aucun" Call stack: 1 .processhit (561) > 2 .process (903) > 3 .routerequest (922) > 4 bvwprocess.process (2715) > 5 wwprocess.process (272) > 6 bvwprocess.domevent (4615) > 7 bvwprocess.ajaxformrequest (4631) > 8 awajax.formrequest (9258) > 9 awajax.useraction (14126)
Exe: "C:\CAL\CAL.exe", version 2.0.0 of 2018-09-27 02:20:48 PM (il y a 6 minutes) Process ID: 1948
* ========================================
function oSiblingTabIndex && {fr} Frère d'un object dans un conteneur selon un différentiel de tabindex
lparameters ;
toObject; && {fr} Objet
, tnTabIndex; && {fr} Différentiel de TabIndex
, tlControl; && [.F.] {fr} tabuler seulement les contrôles
&& 2018-09-11 thn -- {FiC V 2.28.0-beta.2} {en} improved; tlControl added
&& 2018-09-18 thn -- {FiC V 2.28.0-beta.4} {en} works for controls in the same container
local loResult;
, laSibling[1], lnSibling, liSibling, loSibling, llUp
do case
case empty(m.tnTabIndex) or !lProperty(m.toObject, 'tabIndex')
return m.toObject
case varSet(@m.lnSibling, aoSiblings(@m.laSibling, m.toObject,, .t., @m.tlControl)) and Empty(m.lnSibling)
return .null.
*!* CASE VARTYPE(m.tnTabIndex) == 'C' && code qui évite l'erreur
*!* RETURN m.toObject
otherwise
* setStepOn(Lower(m.toObject.Name) == Lower('txtnom35'))
llUp = m.tnTabIndex > 0
tnTabIndex = m.toObject.tabIndex + m.tnTabIndex
loResult = m.laSibling[1]
for liSibling = 1 to m.lnSibling
if .T.;
and Iif(m.llUp, laSibling[m.liSibling, 2] >= m.tnTabIndex, laSibling[m.liSibling, 2] <= m.tnTabIndex);
and varSet(@m.loSibling, m.laSibling[m.liSibling, 1]);
and m.loSibling.tabStop;
and m.loSibling.enabled;
and (!m.tlControl or m.loSibling.visible);
and .T.
loResult = m.loSibling
EXIT
endif
endfor
return m.loResult
endcase
endfunc
in this case in the above function aoboop.oSiblingTabIndex() the tnTabIndex parameter contains the TextBox.VALUE instead of TextBox.tabindex Amicalement Gilles
Thanks for the feedback and for posting a debugger screenshot.
However I need all the debugger windows visible, including the call stack (especially here as the error is due to the tnTabIndex
parameter) and the locals
Thanks in advance
this fix should work:
modify class awfrm of aw method lostFocusInet
replace
loResult = ICase(;
m.lcVarType == 'O',;
m.luResult,; && You can direct where focus is assigned using the optional oObjectName parameter in the RETURN command of the Valid Event. The object specified must be a valid Visual FoxPro object. If the specified object is disabled or cannot receive focus, then focus is assigned to the next object in the tab order. If an invalid object is specified, Visual FoxPro keeps the focus at the current object. You can now set focus to objects on another visible form or on a non-visible Page or Pageframe control.
Empty(m.luResult),;
m.toMember,;
oSiblingTabIndex(; && modify command abOOP.prg
m.toMember;
, m.luResult;
, .T.; && m.tlControl
);
)
by
loResult = ICase(;
m.lcVarType == 'O',;
m.luResult,; && You can direct where focus is assigned using the optional oObjectName parameter in the RETURN command of the Valid Event. The object specified must be a valid Visual FoxPro object. If the specified object is disabled or cannot receive focus, then focus is assigned to the next object in the tab order. If an invalid object is specified, Visual FoxPro keeps the focus at the current object. You can now set focus to objects on another visible form or on a non-visible Page or Pageframe control.
Empty(m.luResult),;
m.toMember,;
m.lcVarType == 'N',;
oSiblingTabIndex(; && modify command abOOP.prg
m.toMember;
, m.luResult;
, .T.; && m.tlControl
),;
.null.;
)