Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.clipper.visual-objects > #13863

Re: help

From "Wolfgang Riedmann" <wriedmann@gmail.com>
Newsgroups comp.lang.clipper.visual-objects
Subject Re: help
Date 2023-07-11 14:05 +0200
Message-ID <kh4us5Fg3o5U1@mid.individual.net> (permalink)
References <f88f79be-4867-4611-90d6-03fc821ee2e4n@googlegroups.com>

Show all headers | View raw


Buon giorno Aurora,

> i have to create the dispatch method to make the single line edit
> understand that it has to display the value of a calculation,
> basically I have a data windows that contains the list of suppliers
> and a single line edit named supplier balance. I want the calculation
> the supplier balance via notify() but for that I need to broadcast to
> notify the supplier code. 

it may be a bit hard to explain.

The result of your calculation should be put into a variable of your
DBServer class, maybe like this:

class MySupplier
  protect nBalance   as float

access Balance class MySupplier

  return nBalance

method CalcBalance() class MySupplier

  nBalance := 2 * 4
  Super:Notify( NOTIFYFIELDCHANGE, #Balance )  

  return nil

And in your window you have a code like this:

method Notify( kNotifyName, uDescription ) class SupplierWindow
	
  do case	
  case kNotifyName == NOTIFYRECORDCHANGE
    oDCBalance:Value	:= self:Server:Balance
  case kNotifyName == NOTIFYFIELDCHANGE .and. uDescription == #Balance
    oDCBalance:Value	:= self:Server:Balance
  endcase

  return super:Notify( kNotifyName, uDescription )


HTH

Wolfgang

-- 

Back to comp.lang.clipper.visual-objects | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread


Thread

help aurora baccio <aurorabaccio@gmail.com> - 2023-07-03 06:45 -0700
  Re: help dlzc <dlzc1@cox.net> - 2023-07-05 08:27 -0700
  Re: help "Wolfgang Riedmann" <wriedmann@gmail.com> - 2023-07-11 14:05 +0200
    Re: help aurora baccio <aurorabaccio@gmail.com> - 2023-07-19 09:18 -0700
      Re: help dlzc <dlzc1@cox.net> - 2023-07-20 08:52 -0700
        Re: help aurora baccio <aurorabaccio@gmail.com> - 2023-07-20 09:08 -0700
          Re: help dlzc <dlzc1@cox.net> - 2023-07-21 07:50 -0700
      Re: help "Wolfgang Riedmann" <wriedmann@gmail.com> - 2023-07-26 18:06 +0200

csiph-web