NetTalk Central

NetTalk Web Server => Web Server - Ask For Help => Topic started by: GordonF on November 18, 2021, 04:59:09 AM

Title: Goto First Page in NetWebBrowse
Post by: GordonF on November 18, 2021, 04:59:09 AM
I'm probably missing something obvious but can anyone tell me how to force a browse list to goto the first page. Basically I have a popup update form on a browse and after an insert I want to go to the first page of the calling browse not the last, any ideas?

Gordon


Title: Re: Goto First Page in NetWebBrowse
Post by: Alberto on November 18, 2021, 07:17:46 AM
Did you try this?
Title: Re: Goto First Page in NetWebBrowse
Post by: GordonF on November 19, 2021, 01:14:59 AM
Thank you very much for your suggestion, unfortunately it doesn't do what I'm wanting to do.

All I really want to do is go to to the first page of a browse list after a completed insert (only insert), regardless of the actual position of the inserted record.
Title: Re: Goto First Page in NetWebBrowse
Post by: Alberto on November 19, 2021, 05:34:46 AM
In TakeEvent After gainfocus add:

if p_web.gsv('MyRecordInsertedOk')=1
     p_web.script('$("[name=''first_btn'']").click()')
     p_web.ssv('MyRecordInsertedOk',0)
end

Set the session value in the form, in the postinsert routine.

Hope this helps.
Title: Re: Goto First Page in NetWebBrowse
Post by: GordonF on November 19, 2021, 08:07:53 AM
Fantastic that worked perfectly I really appreciate your help, fortunately I already had the equivalent of the insert ok ssv so it was only a moments work.

Gordon