dervaish Posted June 6, 2008 Posted June 6, 2008 hello i have a layout [in listview] and want to trigger a script whenever user clicks on the layout [outside the fields]. almost all the fields on the layout are locked and cannot be clicked in/on with the exception of one field which is active for some calculations. this field must keep a focus all the time for the calculations to work. this is the only reason why i want a layout level script to prevent the user from losing the focus on that field and when the user clicks on the layout i reset the focus back to that field. so this way field will never lose the focus [hopefully]. so how can i link a script to the layout for this purpose? thanx in advance. PS: it is important to know that records on the layout are in listview so there will be as many active fields [active type = available to attain focus] as records. as long as user clicks on these active fields...its fine but not when he/she tries to click on the layout directly making the then active field to lose focus.
Hare Posted June 7, 2008 Posted June 7, 2008 I'm not sure I fully understand. If there is only one user enterable field for a record on that layout, why not point to that field directly in the calculations? (assuming you are now using get ( activefieldcontents ) in the calcs ) I don't think it makes any difference that you are in list view. If the user clicks outside the field, the field is committed and the calcs trigger. can you tell more about the purpose of this (and the calcs)
dervaish Posted June 7, 2008 Author Posted June 7, 2008 first thanx for your reply. 2nd yes i'm using activefieldname function and that is the reason why i want to use the script to keep the field active even when the user clicks outside the field [on the layout]. i'm using customized navigaion [to highlight the current row] which is linked to status-Area buttons [rolodex] and it works only if it finds that the field [active row] in the current record is active [hence the focus]. as long as focus is there on the field and moves from record to record, the navigation buttons work just fine and they highlight the current row [main purpose of my customized script, i know i can use customized buttons but i want to use rolodex aswell : ]. but as soon as the field loses the focus, thought the rolodex navigation buttons still work but the script does not highlightes the current row as the active row [field missing the focus]. this is the reason why i want to capture the evet of user clicking on the layout and take the cursor back to the record where it should have been. i hope i'm much clear this time. :
comment Posted June 7, 2008 Posted June 7, 2008 This is the third thread you have started to discuss the same problem: http://www.fmforums.com/forum/showtopic.php?tid/195838/ http://www.fmforums.com/forum/showtopic.php?tid/195805/ You have been already asked not to do this: http://www.fmforums.com/forum/showpost.php?post/292626/
dervaish Posted June 7, 2008 Author Posted June 7, 2008 i don't think this thread is related to the other 2 issues i've asked for help. this is totally different and that is why i posted it here to get some help.
Hare Posted June 7, 2008 Posted June 7, 2008 uh well reading the other posts it certainly seems related to me. I think it would be more effective if you kept everything in one thread so people can understand the context of what is asked. At first glance you seem to have two problems: one is you are trying to have your cake and eat it: you want to script control navigation and still allow status area access for users. This is a contradictory strategy. You need to make a choice for either. The second problem, but I admit this is hunch only, is that your current question, keeping focus on a field, is a symptom of bad UI design. But I don't think I have enough info to advise an alternative. So you need to post a stripped down version of what you are trying to achieve.
comment Posted June 7, 2008 Posted June 7, 2008 i don't think this thread is related to the other 2 issues Please do not insult my intelligence. It all started when you posted a follow-up question here: http://www.fmforums.com/forum/showpost.php?post/292838/ any update on this issue of highlighting the row in listview? Then you started this thread: http://www.fmforums.com/forum/showtopic.php?tid/195805/ where you asked: is it possible to capture the staus of rolodex [record navigation through status area] through a script? Then you opened a new thread: http://www.fmforums.com/forum/showtopic.php?tid/195838/ where you asked: how can i link the script to rolodex navigation and when asked about the purpose, you explained: well i'm trying to highlight the current row in listview And now this.
Hare Posted June 7, 2008 Posted June 7, 2008 so.... where to proceed from here? the irritation is reasonable but the problem at hand is not solved and reasonable too. is it possible for a moderator to rake everything with bearing on the matter into one thread and see where it leads us (with the solemn promise by Dervaish to stick to it) (and post a sample)?
mr_vodka Posted June 7, 2008 Posted June 7, 2008 At this point, merging the topics together may cause more confusion than leaving it alone. However, if you guys feel that it should be ulimately merged, then let me know and I will.
Hare Posted June 7, 2008 Posted June 7, 2008 you may be right about the confusion. perhaps it's best to wait and see if dervaish wants to pursue the matter.
comment Posted June 7, 2008 Posted June 7, 2008 I don't really care - I don't find the problem interesting, or even "reasonable". If the automatic highlighting method suggested by Ray is unacceptable, then - if it's important to have highlighting - hide the status area and use scripted navigation/highlighting, or - if it's important to have the status area - compromise on the highlighting. I certainly wouldn't force the cursor into a field just to make sure the record gets highlighted (just think of the record-locking issues that's bound to cause).
Hare Posted June 7, 2008 Posted June 7, 2008 possibly everything has been said about the OPs problem three times over, nevertheless he still hasn't got it solved (or he wouldnot be coming back). whether it's technically interesting or not makes no difference. It's about making clear that the chosen approach is not right and there are better ways available. Ya well maybe had I known about the other threads my view on the matter would be different and I wouldn't even have bothered about posting. As it happens, I dove in fresh and look where I landed. I'm in need of an exit loop if [ ] here :violin:
comment Posted June 7, 2008 Posted June 7, 2008 whether it's technically interesting or not makes no difference I didn't say "technically interesting", I said "interesting". And it makes all the difference to me - I don't work here.
LaRetta Posted June 7, 2008 Posted June 7, 2008 (edited) I have no problem with someone NOT understanding a solution; we all ( well, most all ) of us are a bit dense understanding some suggestions. I take exception that we have made it VERY clear to post back on the same thread and it still isn't happening. We have already wasted our time merging threads; you'all have wasted your time pointing out that we all are wasting our time; you'all have bothered to try to resolve the issue by asking the same questions and re-hashing points which were already made clear ... enough. It's about making clear that the chosen approach is not right and there are better ways available. Nope. We HAVE made it clear. I will not waste my time merging messages or chopping them apart attempting to look for the relevant points, indeed not. It is not our business to hand-hold, nor is it our business to feel responsible when someone ( after many people have attempted to assist them ) still doesn't *get* it. It is THEIR responsibility to try again ( on the same thread ) to phrase things differently if not being understood, to ask questions if things aren't clear and to finally accept what people tell them - or go off on their own and solve it. After having been asked, two additional threads appeared again under the same question. Someone isn't listening here. Simply, when I see duplicate posts like this in future from dervaish, I will simply delete them. Edited June 7, 2008 by Guest Reversed two sentences
Recommended Posts
This topic is 6013 days old. Please don't post here. Open a new topic instead.
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now