NetTalk Central

Author Topic: Locate Field Not Working In Mobile Mode  (Read 3512 times)

AZIS350

  • Jr. Member
  • **
  • Posts: 62
    • View Profile
    • Email
Locate Field Not Working In Mobile Mode
« on: February 06, 2012, 10:10:23 PM »
Sorry to start a new thread on this, but the old thread is no longer being displayed for some reason.

Clarion 8, NT 6.18.

With Example 49 (Locator), I am able to replicate the same problem I have in my app regarding not being able to use the Locate field to search for a record in Mobile Mode (i.e. iPhone testing in my case) the first time the browse is displayed. These are the steps I followed - Bruce can you try this with Example 49 on your end and see if you get the same results please.

1) Embed Locator Position values in Example 49 (LocatorOptions Form) so that you do not have to press any checkboxes on the form during runtime (set values to 1)
2) Run Example, select 'Runtime Locator Example' and immediately enter a value in the Locate field (i.e. Cheryl) and tap on the DONE button on the iPhone (do not tap on any checkbox on the form before doing this - go straight to the locate field and enter the value then tap DONE). Nothing happens. Tap on the SEARCH button - still nothing happens.
3) Now tap on either one of the checkboxes on this form, or just tap on a the Name column heading to sort the column, then enter the Locate value again (i.e. Cheryl) and tap on DONE. This time it now does the search and finds the appropriate record.

This is the same problem I am having with my app. If you bring up a browse and enter a Locate value in mobile mode and then tap DONE on the phone and even press SEARCH right afterwards, nothing happens. Only when you tap on a button (reset values?) on a form where a browse is embedded will it work the first time you enter a value on the browse.

Anyone else able to replicate this problem in mobile mode? It appears for whatever reason that when a browse with a Locate field is displayed initially and you enter a value and tap DONE on the phone, nothing is being sent back to the server (no activity is occurring). But if you tap on a column heading, etc, - there is a SEND going back to the server and from that point any locate you do on that browse during that session (before going to another procedure) will continue to work correctly.

Bruce

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 11250
    • View Profile
Re: Locate Field Not Working In Mobile Mode
« Reply #1 on: February 06, 2012, 11:09:27 PM »
hi Bob,

>> Sorry to start a new thread on this, but the old thread is no longer being displayed for some reason.

This forum software has some sort of "flame limit" type feature, which blocks you from a thread after you post n times in the thread. I don't know where the setting is, so I can't turn it off. But it's a pain.

Bruce

Bruce

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 11250
    • View Profile
Re: Locate Field Not Working In Mobile Mode
« Reply #2 on: February 06, 2012, 11:47:19 PM »
>> 1) Embed Locator Position values in Example 49 (LocatorOptions Form) so that you do not have to press any checkboxes on the form during runtime (set values to 1)

loc:type was already set, so I added locator:Position=1 and locator:SearchButton = 1, both turned on "prime for change".

>> 2) Run Example, select 'Runtime Locator Example' and immediately enter a value in the Locate field (i.e. Cheryl) and tap on the DONE button on the iPhone (do not tap on any checkbox on the form before doing this - go straight to the locate field and enter the value then tap DONE). Nothing happens. Tap on the SEARCH button - still nothing happens.

ran exe.
Selected "Runtime Locator Example".
Noted that the "User" column has the sort arrow visible, and the locator prompt says "Locate (Position) User".

Desktop:
clicked on the locate field. Typed in Cheryl.  Clicked on "Search" button
effect: browse jumped to Courtney Ballantyne.

Mobile. (restarted exe) - app looks a bit funny 'cause it's not set up for mobile yet, but I just ignored that.
Went to menu, to Runtime Locator Example.
scrolled down to find the browse, and the locator.
noted that "User" column has the ^ icon showing it's sorted by that column.
selected locator field by tapping on it. Keyboard appears.

Typed Cheryl. Then tapped on "done". The keyboard disappears.
After a rather length delay (5 seconds or so (*)) the browse refreshes.

(*) - For some reason, perhaps related to our wi-fi, my iPod to desktop connection is very flaky. So things happen _very_ slowly. It doesn't seem to be related to the server, but to our infrastructure.

>> 3) Now tap on either one of the checkboxes on this form, or just tap on a the Name column heading to sort the column, then enter the Locate value again (i.e. Cheryl) and tap on DONE. This time it now does the search and finds the appropriate record.

it's working for me in step 2 though - that's the bit I don't get. why are we getting such different experiences there?

cheers
Bruce


AZIS350

  • Jr. Member
  • **
  • Posts: 62
    • View Profile
    • Email
Re: Locate Field Not Working In Mobile Mode
« Reply #3 on: February 07, 2012, 07:23:11 AM »
Thank you Bruce for checking the sequence on your end. It has to be something on my end then. I have the web folders updated (with copyall.bat and gzipall.bat), and even other examples (i.e. #3 Basic with Login) result in the same symptom for me in mobile mode without any changes to the example code. I'll just write a workaround for now until I can figure out what is unique on my end that could be causing this. I haven't tried installing on a different server, using a different connection  - so that's next. If I find anything on my end that is causing this issue I'll post back.

Thanks again.


AZIS350

  • Jr. Member
  • **
  • Posts: 62
    • View Profile
    • Email
Re: Locate Field Not Working In Mobile Mode
« Reply #4 on: February 08, 2012, 01:40:42 PM »
Bruce, here are a few items I"ve discovered while testing on my end. Since you are able to use the Locate in mobile mode without any problem you probably won't be able to test this. But perhaps it may be some clue as to what is happening in my environment. I have updated the web folder to the accessory web folder, use the current copyall.bat and gzipball.bat files as well, in 6.18.

These situations are related only to mobile mode:

1) The Locate search and clear buttons (assuming they are jmobile) do not show up next to the locate field even though I have the checkboxes for them checked in the NT template. However, if I hardcode the Locate:SearchButton and Locate:ClearButton and set to value 1 (like the example 49), then they appear. Either way, doesn't have an effect on not being able to perform a locate though.

2) Oddly, the Locate function DOES work right away if the field is a date field with a date picture token entered in the Picture field. That is the only occasion when the Locate works when the browse is first displayed. I tried most other tokens and they do not work, but the date does. I also noticed the Date token causes the Locate field to omit the search magnifying icon in the left corner of the locate field and replaces it with MM/DD/YY. Makes sense, but not sure if related to my problem that the date field works but all other fields do not.

3) What does work for the Locate is if I create a form and place the browse on it, and create a radio button or checkbox that when clicked performs a refresh on the browse procedure. Once that is done, the Locate field works fine. So somehow, my problem seems to be related to a refresh of the browse the first time the browse is displayed (or rather, the lack of a refresh unless I have a radio button/checkbox on the form). Is there any way therefore I can hardcode to force a refresh of the browse once the browse is first displayed without requiring a form for the browse to be placed on and without requiring a radio button/checkbox to be checked? I'm just trying to find a workaround that will work in my situation. Thanks!


Not sure if this helps - still exploring other possibilities.