NetTalk Central

Author Topic: CASE MESSAGE on NT  (Read 126 times)

osquiabro

  • Sr. Member
  • ****
  • Posts: 372
    • View Profile
    • Email
CASE MESSAGE on NT
« on: October 05, 2019, 06:28:35 AM »
is possible create a case message popup like clarion desktop ?? like this :

CASE MESSAGE('Are you sure you want to Change Zip Code? etc..

thanks

Bruce

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 9848
    • View Profile
Re: CASE MESSAGE on NT
« Reply #1 on: October 09, 2019, 02:28:22 AM »
Hi Osa,

yes, but the context matters. Remember the web page is always moving forward.
So it's probably not going to "work" the way you expect - there's no procedure "waiting" on the server for the user to enter input.

So in order to answer this question better I would need to know a lot more about your context. Where you are, what you are doing, and what you are hoping to do with this message, etc.

cheers
Bruce


osquiabro

  • Sr. Member
  • ****
  • Posts: 372
    • View Profile
    • Email
Re: CASE MESSAGE on NT
« Reply #2 on: October 09, 2019, 08:18:29 AM »
is simple i have a Zip Code field and need a popup message before change the value of the field

Bruce

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 9848
    • View Profile
Re: CASE MESSAGE on NT
« Reply #3 on: October 09, 2019, 10:06:43 PM »
You can have a popup message - alerting the user to some detail, when the field is changed.
But in that context it would be a message, not a decision (ie not a yes/no question).

Tell me more about the message you are intending to display, and what you then expect the user to do, and then what you want to do based on that...

cheers
Bruce

urayoan

  • Full Member
  • ***
  • Posts: 156
    • View Profile
    • AZ Rock Radio
Re: CASE MESSAGE on NT
« Reply #4 on: October 10, 2019, 05:12:46 AM »
Hello Bruce,

I think osquiabro is looking for confirmation message, similar when in a browse the user is gonna delete a record. But in this case, alter or change the record.
« Last Edit: October 10, 2019, 05:16:44 AM by urayoan »

osquiabro

  • Sr. Member
  • ****
  • Posts: 372
    • View Profile
    • Email
Re: CASE MESSAGE on NT
« Reply #5 on: October 10, 2019, 05:43:29 AM »
Exactly urayoan, but for more specific this is a code that run in desktop program and needed a similar code with NT

CASE MESSAGE('Are you sure you want to Change Zip Code?, This Change Delivery Charge.','Alert',ICON:Question,+Button:Yes+Button:No,,1)
            OF Button:Yes
                PUT(BillofLadings)
                History::Bil3:Record  :=: Bil3:RECORD
                SQL{prop:sql} ='select BillofladingId, isnull(ChargeId,0) as ChargeId, PaymentType,0 as ChargeTypeId, ChargeDescription from billofladingcharges where billofladingid= '&Bil3:BillofLadingId & ' AND ChargeDescription = <39>'& 'DELIVERY<39>'
                   
                LOOP
                    NEXT(SQL)
                    IF ERRORCODE() THEN BREAK.
                    CASE Bil3:PaymentZone
                    OF 'C'
                        Shipper{prop:sql} = 'CALL BolChargesByCharge('&Bil3:BillofLadingId &','&chr(39)&CLIP(SQL:C3)&CHR(39)&','&Bil3:CustomerId&','& 0 &','&CLIP(SQL:C2) & ',0)'                               
                        BREAK
                    OF 'P'
                        Shipper{prop:sql} = 'CALL BolChargesByCharge('&Bil3:BillofLadingId &','&chr(39)&CLIP(SQL:C3)&CHR(39)&','&Bil3:ShipperId&','& 0& ','&CLIP(SQL:C2) & ',0)'                                 
                        BREAK
                    OF 'T'
                        Shipper{prop:sql} = 'CALL BolChargesByCharge('&Bil3:BillofLadingId &','&chr(39)&CLIP(SQL:C3)&CHR(39)&','&Bil3:PartyId&','& 0 &','&CLIP(SQL:C2) & ',0)'                                 
                        BREAK
                    END                       
                END
                Charges.Load
                Charges.Reset(1)
            OF Button:No
                Bil3:ShipToZipCode = History::Bil3:Record.Bil3:ShipToZipCode
                Bil3:ShipToCity    = History::Bil3:Record.Bil3:ShipToCity
                Bil3:ShipToState   = History::Bil3:Record.Bil3:ShipToState
                SELECT(?Bil3:ShipToZipCode)
                ThisWindow.Reset(1)
            END
        END