Listener Removal Strategy

May be dumb - but I create a lot of objects in an application
written in 3.0. When they are done doing what they do, I would love
to be able to call a utility routine that shimply looped through
the listeners that are registered for all objects and remove them
where is .target is the object I am done with. I don't know if this
is possible but it would significantly simplify my code and I
suspect the internals of listener registration, removal and cycling
does the .target check anyways......
Am I barking up the wrong tree, is this something someone had
done or is the mere thought of it stupid from the start......
bob

Kglad - no, just the listeners. I would like something like
for each(listener in the listener stack) {
if listener.subscribed_to_target = mytarget
remove listener
In my coding - any listeners set up in an object are dealt
with by that object when done - typical remove_listeners funtion
removing listeners set-up, typically on instantiation of the
object. Listners that subscribe to the object events from other
objects deal with removal separately.
It would clean things up tremendously to simply walk the
listener stack and where the target is the object that is no longer
needed, I could have some iteration to remove all listeners that
have that object as a target.....
Hope this makes sense....
ccoonen - I fear the use of "weak reference" but do so as is
suggested in some texts. If I could confirm that the listener was
removed and collected as of a certain point I would follow your
strategy, but I always hesitate to rely on something I can not
test.

Similar Messages

  • User Defined Stock Removal Strategy

    Hi,
    We want to define a user defined stock removal strategy while creating TO for delivery using transaction LT03. This can be done in user exit MWMTO004. Although we modify the output table T_QMAT in this exit as per requirement , the TO is not split as per the table.
    SAP proposes all the batch bins in table T_QMAT , but if all the delivery quantity is found in first bin itself , the TO is created with that bin only , no Split. We wish to split the TO as per table T_QMAT.
    How to split the TO as per proposal from the exit ?
    Please provide some ideas.
    Regards,
    Tushar

    Hello,
    You can change the Storage unit type in this exit EXIT_SAPLL03A_005 of TO creation transaction.
    I am not sure, If this helps you.
    Thanks and Regards
    Reddy

  • WM - Stock Placement and Stock Removal Strategy

    Hi Gurus
    Need yr expertise..
    What would be the ideal stock placement strategy if need to store standard pack in one location and partial quantity in another location?
    example:
    standard pack for material A is 100pcs
    if GR 250 pcs, TO need to be created for 200pcs at location A (since it is standard pack) and
    50pcs at location B (sicne it is partial)
    The same logic aplly for stock removal strategy. If customer order of 200pcs, system need to pick
    from location A (since it is standard pack). If customer order 50pcs, system need to pick from
    location B. What will be the ideal stock removal strategy?
    Please advise
    Rgds..Sanjay

    yu can make use of the small/large stock removal strategy and for the concerned material in WM 2 view you can give the control quantity like if the requirment is of >200 pc then storage type 0002 should be used to pick the goods otherwise if required quantity is less then system should search for storage type 0001
    this is a standard strategy

  • New stock removal strategy

    Folks,
    This is the scenario, We have 2-3 pallets in a single storage bin.The bin is like a deep rack in the warehouse.
    So the logic would be to use the Last in first out strategy to pull out the pallet which is outside/first one reachable to the user.
    So LIFO basically works on the actual TO creation time so in case a TO for P1 is created on 01/01/01 at 12:00 PM and another TO for P2 on 01/01/01 at 12:01.The proposes the pallet created at 12:01 to be picked when there is stock removal.
    But the scenario is like though the TO for P2 is created first at 12:01 and it is confirmed at 12:15 and the next one  P1 at 12:16 so the pallet P2 will be placed inside the bin and P1 will be placed outside/reachable to the user.
    But when LIFO kicks in for automatic TO creation it will propose p2 as the To was created at a later time but the user will pick P1 as it is the nearest reachable to him so when he tries to confirm the pallet at production the system says that the wrong pallet from what was proposed was picked.
    Is there any enhancement we can use to build this custom stock removal strategy.

    Hi,
    Just querious on TO confirmation time...why it is confirmed differently? Will immediate TO confirmation (after TO creation) creates any issue to putaway process into Rack?
    If don't want immediate TO confirmation...you can manipulate the picking of pallet through user exit MWMTO004 Own stock removal strategy (EXIT_SAPLL03A_005) to change the sorting of records on TO confirmation date and time instead of TO creation date and time.
    Hope this will help.
    Reg,
    Sudhir

  • Stock Removal Strategy

    Hi,
       We have requirement for removal Strategy
        Example:
       Stock Bin1: 300
                 Bin2: 500
       Requirement Qty: 500
        System is picking 300 from Bin1 and 200 from Bin2. We don’t want to break the pallet. Is it possible to Pick the full quantity of 500 from Bin2?
    Thank You

    Please use a user exit for picking:
    1) Activate the user exit for picking on storage type level settings
    2) Write code that first searches for candidate bins that have at least the quantity required on TO
    You can achieve this easily, not too much coding is needed here. Just looping through candidate bins and selecting the first one with the qty >= of the requested qty.
    As for standard, I have tried to achieve this for a client in customizing only, but never actually go it to work.
    You can do something with M strategy - Large / Small quantities, but this is more influencing the search between storage types, not storage bins in the same storage type.
    So, to cut the story short, go with the user-exit for picking.

  • Stock Removal Strategy - Enhancement MWMTO004

    All;
    I am making changes in the exit EXIT_SAPLL03A_005 (Enhancement MWMTO004 ) for our own stock removal strategy. When i populate the internal table T_QMAT with the stock and bin details, there is a problem.
    I have the following sequence in T_QMAT.
    Bin(LGPLA) Total Stock(VERME) Stock to be Removed (AUSME)
    A 100 50
    B 34 34
    When the TO is created, it is taking all 84 from Bin A and Bin B is not all consumed. My Removal Strategy at config is "F".
    Any light shown on this discrepancy is greatly appreciated.
    Thanks!!!!

    I think that you will need to accomplish this by using user exit EXIT_SAPLL03A_005 for picking  - it's this include: ZXLTOU07. This should be fairly easy considering your requirement.
    You will sort your bin candidates by available qty (field verme) in them (ascending), and then pick from the first bin. The system will loop through this user exit until entire quantity is picked.
    The table you need to influence in this exit is t_qmat.
    But.. I don't think your requirement will be the best solution (except if you pick less than full pallet in 99% of the time). This is because you will never get to pick full pallet quantity from full pallets.
    E.g. You always want to pick from partial pallets => You will pick until you pick all the partial qty in warehouse for the material. But, it is sure that you will not have the exact qty in partial pallets, so most probably and I'd say most certainly you will have to pick the rest of the qty from full pallet.
    It practically means that you will always have partial pallets, and if not you will create them by your picking strategy.
    But if this is what you want it can be easily accomplished by user exit mentioned above...

  • Stock Removal Strategy-A

    Hi,
    I am using Stock removal strategy as A-Partial Quantities for one of the S.Types. I have the stocks like this.
    Bin A- 10
    Bin B- 20
    Bin C- 30
    When picking for a TO of 100, it is picking from Bin B and Bin C. My question is according to Stock Removal Strategy A, I thought it is supposed to pick 10 from Bin A, 20 from Bin B and 70 from Bin C. Isn't it?
    Are there any other settings that I need to maintain in order to make sure it picks the partial quantities to make sure we are freeing up the bins with less quantities?
    Thanks for all the replies...
    Venkat

    I think that you will need to accomplish this by using user exit EXIT_SAPLL03A_005 for picking  - it's this include: ZXLTOU07. This should be fairly easy considering your requirement.
    You will sort your bin candidates by available qty (field verme) in them (ascending), and then pick from the first bin. The system will loop through this user exit until entire quantity is picked.
    The table you need to influence in this exit is t_qmat.
    But.. I don't think your requirement will be the best solution (except if you pick less than full pallet in 99% of the time). This is because you will never get to pick full pallet quantity from full pallets.
    E.g. You always want to pick from partial pallets => You will pick until you pick all the partial qty in warehouse for the material. But, it is sure that you will not have the exact qty in partial pallets, so most probably and I'd say most certainly you will have to pick the rest of the qty from full pallet.
    It practically means that you will always have partial pallets, and if not you will create them by your picking strategy.
    But if this is what you want it can be easily accomplished by user exit mentioned above...

  • User exit for stock removal strategy.

    Hi Experts,
    I have a scenario that I want to use FIFO stock removal strategy which is based on the old MRP price in the storage type. How
    Can I impliment his User exist or any predefined user exit are there for this scenario.
    Thanks
    Raghu.

    Please use enhancement MWMT0004 and MWMt0013

  • Can SLED removal strategy automatic choose not expired bin for delivery?

    Dear experts,
    Any help is very appreciated.  I've been investigated on this for quite a while and still not able to find a workaround. 
    We want some materials using the SLED removal strategy when creating transfer order.  as per my setting, when confirm TO, the system will check the expiration date giving a warning msg if expire. the bin has already been determined during TO creation.  is there any configuration or exit function that i should look into so that when creating TO, the system can realize the bin determined is expired and will automatically look for a valid bin?  does it have to be done by exit function?  i also try to set some breakpoint in the exit function EXIT_SAPLL03A_005 and EXIT_SAPLL03A_006 in MWMTO004 , but i don't see any sign of stopping on the breakpoint.  please advise... am i using the wrong exit functions?  all i want is when creating TO, the un-expired bin being picked. 
    Elaine

    Dear Jürgen,
    you are right, only the stock is expired.  We didn't do batch management nor quality management, that's why i 'm considering not to choose the expired stock when creating the TO.  I need to find out the right exit function to do the bin determination.  or block from being confirmed the TO, then use a program to manually do the stock transfer from unrestricted to block stokc.. 
    Elaine

  • WM removal strategy picking random quants

    Hi Guys,
    I have the following problem in our WM-system:
    When a batch has been chosen, the system will use the partial picking strategy to remove quants from the system.
    Example:
    I have 4 quants in bin 1
    i have 4 quants in bin 2
    i have 4 quants in bin 3
    All quants have exactly the same kilograms of material.
    When the total requested quantity is, let's say, covered by 5 quants, the system will choose the bins randomly.
    In this case, i have 2 quants from bin 1, 2 quants from bin 3 and 1 quant from bin 2. This makes no sense to me.
    I would expect the system to get all the quants from bin 1 and 1 quant from bin 2.
    Any ideas?
    The bins are in the same storage type and storage section...
    Thanks in advance,
    Paul

    Hi!
    The total quantity for the TR = 1500 KG.
    There are multiple storage units of 250 KG in the bins (material/quantity/batch/gr-date all equal, but different storage unit numbers).
    The results:
    250     VAT     OND     01C01
    250     VAT     OND     01C01
    250     VAT     OND     01C01
    250     VAT     OND     01C01
    250     VAT     OND     03F01
    250     VAT     OND     03F01
    1: so if there are more quants in 01C01...why skip them?
    2: there are also more of those quants in 01D01, which is closer than 03F1.
    Bin deterimation data:
    Material data                                              28.01.2011   12:48:30 
    Material....... 29999999995        RAL 9002 BEY                                  
    Plant.......... 4301                                                             
    Storage locat.. VMAG                                                             
    Batch..........                           Pick.type.indic. VAC                   
    Stock category.                           Putaway type ind VAC                   
    Special stock..                           Stor.sect.ind... OMB                   
    Storage class..                           Add.exist.stock.                       
    Water pol.class 0                         Block stor.ind..                                                                               
    Storage bin search attempt  1                                                    
    Required qty... 250,000 KG                                                       
    Batch.......... 3432423                                                                               
    Determ.of source data                                                            
      Storage type search sequence copied from preparation screen                    
      Stk rmvl storg. type VAT Stk rmvl strategy A Management of partial quantities  
          ->  Storage bin 03F01      Quantity 250,000 KG                                                                               
    Determ.destination data    Known:                                                
                               Storage type... 923                                   
                               Storage bin.... UITGEVEN                                                                               
    We are planning to build our own removal strategy, so we could probably fix it there, but i would still like to know why standard doesn't work properly.     
    Thanks in advance!

  • Add listener / remove listener

    hi,
    when I add a listener on a clip or button (like the CLICK Event) that exists in the timeline do I allways have to remove the listener if the Clip is removed from stage? Or will it be removed automaticly by the garbage collection?
    TIA

    It will only be removed automatically if you use a weak reference:
    clip.addEventListener(MouseEvent.CLICK, clickHandler, false, 0, true); //weak ref
    vs:
    clip.addEventListener(MouseEvent.CLICK, clickHandler); //strong ref
    the second version is only removed if you removeEventListener on it.

  • Changing stock removal strategy

    Hi All,
    I need to modify the source storage bin during stock removal such that the TO is created from fixed bin even when its stock is zero.I was using exit EXIT_SAPLL03A_009 for the same.But it gave me 'Quant overflow' or 'Storage unit error'.
    I also tried EXIT_SAPLL03A_005 but even this doesn't seem to work as I cant find data to append in t_qmat table.
    Can anyone help? its urgent.
    Edited by: Jaya Singh on Mar 24, 2008 5:31 PM

    I think that you will need to accomplish this by using user exit EXIT_SAPLL03A_005 for picking  - it's this include: ZXLTOU07. This should be fairly easy considering your requirement.
    You will sort your bin candidates by available qty (field verme) in them (ascending), and then pick from the first bin. The system will loop through this user exit until entire quantity is picked.
    The table you need to influence in this exit is t_qmat.
    But.. I don't think your requirement will be the best solution (except if you pick less than full pallet in 99% of the time). This is because you will never get to pick full pallet quantity from full pallets.
    E.g. You always want to pick from partial pallets => You will pick until you pick all the partial qty in warehouse for the material. But, it is sure that you will not have the exact qty in partial pallets, so most probably and I'd say most certainly you will have to pick the rest of the qty from full pallet.
    It practically means that you will always have partial pallets, and if not you will create them by your picking strategy.
    But if this is what you want it can be easily accomplished by user exit mentioned above...

  • Disabling Listener/Removing edit From UndoManager

    Problem I was wondering if someone could assist me with.
    Currently im using a standard UndoManager and i need someway of removing an edit from the manager.
    A function in the application loads clears and adds new text to a textArea, i need someway of not listening to these events or (or removing them from the edit after they happen) I cannot just add the listener after they occur as I need to listen to all Undoableedit events before and after the function runs.
    Any help would be very much appreciated.
    Tim

    My suggestion is to create your own MyUndoManager which extends UndoManger. You can override adddUndo() method where you can check whether current undo is acceptable if not just skip it in other cases call super.addUndo();
    regards
    Stas

  • Regarding Stock Removal strategy M

    Hi friends -
    We have a requirement here for the system to propose different storage types based on quantity on the transfer order.
    I have recommended strategy M which allows for this.
    But there is a problem, there is not 1 fixed bin to pick from in the case of small qties.
    In other words, the client wants a group of bins to belong to a material, if the qty on the TO is less than Control quantity then the system should propose any of those bins. Plus replenishment for that material should always point to that group of bins.
    Now I suggested using section indicators and maintaining a section search strategy to correctly identify those bins, but they dont want to maintain so much material master data either.
    What they want to do is this, identify bins as and allocate them for a material, all picks and all replenishment henceforth should point to those bins until changed. In addition they want minimal master data maintenance.
    Any ideas?
    Thanks for your recommendations.

    There doesn't need to be 'one fixed Bin', you just want the system to go to a given Storage Type dependent on the control quantity (WM2).  It'll find the material in whichever Bin(s) it's in.

  • WM - Stock removal strategy: small/large quantities

    I have two different storage types: one to remove small quantities of a
    product (with negative stocks available) and one for the large ones. In
    the material master record I have established for a product that
    quantities lower than 50 units are removed from the first storage type.
    I also have defined for the product one stock removal rule (to search
    for material in the two storage types)
    When I don't have enough available stock in my small quantities storage
    type, the system always search for stock in the other storage type
    (although I asked for 10 units), but what I need really is to have a
    negative available stock in this storage, and I will do a reposition.
    It's not correct that for small quantities it searchs in the large
    quantities storage type.
    If in the stock removal rule I'd only put the small quantities storage
    type, then I get negative available stock in the storage type, but,
    logically, the system then doesn't find from where to remove large
    quantities.
    Thank you

    Hi Paloma,
    I hope defined the strategies for both the storage types (for large and small qty.) what about the the negative stocks, how are you going to do the configuration. Mostly what you can do is, you can allow the negative stocks for that particular storage type, but you can't guide the system to create negative quants if the quantity is small.
    Hope it is helpful
    Aktar

Maybe you are looking for

  • Is there a way to hide the reading pane in iPad mail after a message is read?

    Is there a way to hide the reading pane in iPad mail after a message is read?

  • How to paste a link on logon page

    Dear gurus, I want a Http link on my portal logon page ,plz help me Thanks and Regards, santhosh.

  • Current Date in query

    Hi guys, I would that at the opening of a query in BEx, my characteristic "ZDAY" will be allways equal to todays'date. I'm working on Infoset and so I can't use virtual characteristic... Do you know how to do that in BW or in BEx ? For sure, points w

  • Hardware test and disk repair

    Hi: I'm relatively new to the mac world and I have a Mini, core solo, intel. I have two questions that I hope you can answer: 1. How do I do a hardware test? 2. How do I repair the disk via the CD that came with the Mini? When I install the disk, it

  • JBoss connection pools

    hi. i just upgraded from jboss 2.2.2 to jboss 2.4.1 and now all of my connection pools are shot. here's my jboss.jcml: <mbean code="org.jboss.jdbc.JdbcProvider" name="DefaultDomain:service=JdbcProvider"> <attribute name="Drivers">org.hsql.jdbcDriver,