NetTalk Central

Author Topic: Best way of show a big note  (Read 2657 times)

Alberto

  • Hero Member
  • *****
  • Posts: 1848
    • MSN Messenger - alberto-michelis@hotmail.com
    • View Profile
    • ARMi software solutions
    • Email
Best way of show a big note
« on: February 27, 2020, 08:49:24 AM »
Hi, I need to show a big note using a button and a popup proc.
How is the best approach?
Because its for only viewing the note, no update, may be theres a more small way that use a form.
see pic
-----------
Regards
Alberto

Matthew51

  • Full Member
  • ***
  • Posts: 151
    • View Profile
    • Email
Re: Best way of show a big note
« Reply #1 on: February 27, 2020, 04:00:33 PM »
Simplest way I guess would be to use a NewWebPage. Include a stringTheory object. In the Processed code embed put
Code: [Select]
st.SetValue(p_web.Translate([noteString]))
st.Replace('<13,10>', '<<br>')
packet.append(st.GetValue())
Contractor with 10+ years of NetTalk experience looking for work.
www.linkedin.com/in/matthew-leavitt
BisWare.ca
Check out my free EasyTime Template

DonRidley

  • Don Ridley
  • Global Moderator
  • Hero Member
  • *****
  • Posts: 729
  • donaldridley2011@gmail.com
    • View Profile
    • Email
Re: Best way of show a big note
« Reply #2 on: February 28, 2020, 02:55:43 AM »
You could use a popup memory form with only one field.

Open the popup NoteMemForm with your button passing the note string as a parameter of the button's OnClick.

That will place the "note" in the NoteMemForm's URL string as a parameter https://wwwwww.xxx?thenote=xxxxxx

Under the NoteMemForm's priming tab, On Change, NoteField primed with p_web.GetValue('thenote')

Display the NoteField with a text control.

Choose a close button instead of save under the NoteMemForm's buttons tab.

Resize the NoteMemForm to taste.

Done.


Don
« Last Edit: February 28, 2020, 02:57:33 AM by DonRidley »
"Eliminate the impossible, whatever remains, however unlikely, must be the truth."

NetTalk 12.55
Clarion 11

Alberto

  • Hero Member
  • *****
  • Posts: 1848
    • MSN Messenger - alberto-michelis@hotmail.com
    • View Profile
    • ARMi software solutions
    • Email
Re: Best way of show a big note
« Reply #3 on: February 28, 2020, 03:49:12 AM »
Thanks Don ... but this does not work in Popup mode, you cant use parameters

« Last Edit: February 29, 2020, 06:56:56 AM by DonRidley »
-----------
Regards
Alberto

DonRidley

  • Don Ridley
  • Global Moderator
  • Hero Member
  • *****
  • Posts: 729
  • donaldridley2011@gmail.com
    • View Profile
    • Email
Re: Best way of show a big note
« Reply #4 on: February 29, 2020, 06:57:12 AM »
Sure you can. 

From the docs for On Click Button:

Quote
Parameters
Parameters to pass to the URL or procedure. This is a & separated list of the form parameter=value&parameter=value and so on.

You're using a button to call your "note" form.  Pass the note form a "NetTalk" parameter.

Don
"Eliminate the impossible, whatever remains, however unlikely, must be the truth."

NetTalk 12.55
Clarion 11

Bruce

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 11191
    • View Profile
Re: Best way of show a big note
« Reply #5 on: March 01, 2020, 09:57:51 PM »
>> Simplest way I guess would be to use a NewWebPage.

No, don't use a NetWebPage - these cannot be popups.

>> You could use a popup memory form with only one field.

yes

>> Open the popup NoteMemForm with your button passing the note string as a parameter of the button's OnClick.

You don't need to pass it. The popup form could just use the session value "as is".
Assuming the notes is a field in the database, then it's just a case of using that field on the form (probably as a "DISPLAY" field.)

Cheers
Bruce