Deactivate Event Handlers within an EH Set
We're using EH Sets consisting of shipment and delivery Event Handlers. We deactivate them by configuring an Expected Event that, when overdue, calls the "EHSET_SET_INACTIVE" activity. Unfortunately this process is not working correctly so we now have tens of thousands of active Event Handlers that need to be deactivated. We tried running the "/SAPTRX/ARCHIVE_EH_DEACTIVATE" program but the message "No archiving-relevant data found for selection criteria; check criteria" is returned as the program checks to see if the EH is part of an EH Set.
Does anyone know of a way to deactivate these EHs?
Hi Steven,
This is what I can see "You archive an event handler that belongs to one or more event handler sets by deactivating and archiving the entire event handler set" and check in this link Archiving Event Handlers (SCM-EM) - Archiving in SAP Event Management - SAP Library.
It will have some implications, if we deactivate particular event handler in event handler set then subsequent event message may fail for other event handler in EH set, SAP EM Web UI doesn't retrieve event handler data as other event handler deactivated in EH set etc. You can raise SAP OSS message to SAP to get the list of causes deactivating event handlers in EH set.
Regards
GGOPII
Similar Messages
-
Event Handlers and Callbacks: Best way to handle?
I'm writing an actionscript class. I'm wondering how to deal
with call backs and event handlers within my class. In particular,
I'm wondering how I might structure my class so that developers
using it can choose which arguments get passed to the callback
function as they code. I've been googling and haven't found any
particularly useful information on this.
As far as I can tell, it would appear that the parameters
passed to any callback function are determined at the time I write
my class as this anonymous function example illustrates.
var myObj:Object = new MyClass('foo', 'bar');
myObj.onLoad = function(arg) {
// the args passed to this anonymous function are dictated
by the actionscript defnining MyClass
I have also seen an approach using named functions and a
class method for setting the event handler which allows a developer
to pass some object to be used for scoping the named function but
this also results in the parameters for the callback being
predetermined by the actionscript that defines the class
function myLoad(arg) {
// the args passed to this function are also dictated by the
actionscript defining MyClass
var myObj:Object = new MyClass('foo', 'bar');
myObj.setOnLoadHandler(this, 'myLoad');
As far as I can tell, neither approach would let a developer
specify any parameters for the callback functions (onLoad() in the
first example, myLoad() in the second example). Which of these
approaches is considered 'best practice'? Also, what would I do if
I wanted to specify that the callback should operate on a
particular movieclip on my timeline? How can I pass that
movieclip's parameter to the callback function?You can download the Library from this link. Inside is an example that shows how to handle windows messages/events.
http://zone.ni.com/devzone/cda/epd/p/id/4394 -
Tracking ID for different event handlers set
In the following link i send the file with the image purpose:
http://www.sendspace.com/file/cxbd8l
Dear experts,
We need to give Visibility for the next process, conformed by three visibility process, show more detailed in the following explanation:
1. First Visibility process -> purchasing scenario
Purchase Order -> Confirmation -> Goods Receipt -> Invoice Verification
Note: In this scenario we need to modify the rule set (don´t include inbound delivery) and modify the standard functions (Create Z), of expected events and Goods receipt.
2. Second Visibility process -> Stock transport order Scenario
Stock transport order (PO) -> Outbound Delivery -> Shipment -> Goods receipt -> Invoice Verification (Planned delivery costs).
Note: In this scenario we need to create a Z function to planned delivery costs and create the Z events according to the Planned delivery costs we want to control.
3. Third Visibility process -> Second Stock transport order scenario
Stock transport order (PO) -> Outbound Delivery -> Goods receipt -> Invoice Verification (Planned delivery costs).
Note: In this scenario we need to create a Z function to planned delivery costs and create the Z events according to the Planned delivery costs we want to control.
After this introduction, the question is how we can see an entire operation (the combination of the three scenarios), I mean, when we ingress to /SAPTRX/EH_LIST transaction, and execute this, the transaction show an event handler level (Same way /SAPTRX/EH_SET, event handler set level), but my grouping fields are according to Event handler (example: Bussines process type), but we don´t have a u201CProcess Unique IDu201D, that combine the different Application Object Types involved (In this process, PCM10_ITEM, TRA10_DELIV, TRA10_ROAD).
In the following image I show an example of the point exposed (think in /SAPTRX/EH_LIST transaction):
Appl.Obj.type PROCESS UNIQUE ID
PCM10_ITEM 123456
TRA10_DELIV 123456
TRA10_ROAD 123456
Ok for do this; we expect to follow the next steps:
1. Define a field in the Tracking documents (Purchase order, Stock transport order, shipment and outbound delivery), where we ingress the same value (Process value ID) at the moment of execute the indicated transaction:
a. ME21N -> PO and stock transport order.
b. VT01N -> Shipment.
c. VL01N -> Outbound delivery.
2. Define a new Info Parameter both in the application system and in event management system.
3. Create Z function for expected event extractors and Info parameter Extractors (These functions have to look and save the info parameter defined previously).
4. Because this field doesn´t exist in any report, we think to create an enhancement in the /SAPTRX/EH_LIST transaction with the objective of don´t create a new report for only one new field (It require an ABAP program).
According with this explanation, it´s correct our analysis? We forget any step to get our purpose?
We appreciate a lot your help in this issue.Hello,
Kevin thanks a lot by your answer, the question is how to associate three event handlers, but i don´t know about the number range, i appreciate a lot if you can explain to me more detailed, how i can define this number range and what tables has associated in order to define de Function module for "Control parameter extractor". I appreciate too if you can explain me how the system assign the same number in the three event handlers.
According to this, I appreciate a lot if you confirm to me, the followings steps that cover this requirement (I propose two different scenarios, the second scenario was adjusted after your explanation):
SCENARIO 1 -> Using a custom number range.
1. Define a custom number range.
2. Define a new Control Parameter both in the application system and in event management system. Assign the control parameter to the list and create the event handler set.
3. Create Z function for "expected event extractors" and "Control parameter Extractors" (These functions have to look and save the control parameter defined previously).
4. In this case, cause its defined a common event handler set, we can execute the /SAPTRX/EH_SET transaction and look the operation consolidated.
SCENARIO 2 -> Including information in one additional field in the ECC transactional documents
1. Define a field in the Tracking documents (Purchase order, Stock transport order, shipment and outbound delivery), where we ingress the same value (Control parameter) at the moment of execute the indicated transaction:
a. ME21N -> PO and stock transport order.
b. VT01N -> Shipment.
c. VL01N -> Outbound delivery.
2. Define a new Control Parameter both in the application system and in event management system. Assign the control parameter to the list and create the event handler set (with relation type -> 2 control parameter).
3. Create Z function for "expected event extractors" and "Control parameter Extractors" (These functions have to look and save the control parameter defined previously, in this case according with the extractor (PCM10_ITEM or TRA10_ROAD), the function has to find in the respective field in any case (it means in the PO its the field XXX in the shipment its the field YYY, but in event management the "control parameter" its the same).
4. In this case, cause its defined a common event handler set, we can execute the /SAPTRX/EH_SET transaction and look the operation consolidated.
According with this explanation, it´s correct my analysis? I forget any step to get our purpose?
I appreciate a lot again your help in this issue. -
OIM 11g: Event Handlers/Plugins Classpath
We have a number of custom utility libraries that we use for OIM development which are currently uploaded to the OIM database OIMHOME_JARS table.
Ideally, we'd like to reference classes from these JARs in our plugins/event handlers. During initial testing, it looks like the plugin code doesn't consider the uploaded JARs and we get a bunch of NoClassDefFoundError errors.
Is there no way to get the plugin code to be able to use the uploaded utilities? or is the solution to also deploy the utility JARs within the plugin zip file itself (not ideal).
Thanks.Not always true. In most of the cases you would find that it reads the helper jars from within the lib directory inside the plugin but in some special cases it does't behave that simple.
UploadJars definitely doesn't work. I had to put the jar in the weblogic startup script to set classpath for this to work. This script is *<domain_home\bin\setDomainEnv.cmd\>*
So its a bit dubious. -
Do I need to worry about these event handlers in a grid from a memory leak perspective?
I'm pretty new to Flex and coudn't figure out how to add event handlers to inline item renderer components from the containing file script so I attached the listnerers simply as part of the components themselves (eg <mx:Checkbox ... chnage="outerDocument.doSomething(event)"../>):
<mx:DataGrid id="targetsGrid" width="100%" height="100%" doubleClickEnabled="true" styleName="itemCell"
headerStyleName="headerRow" dataProvider="{targets}"
rowHeight="19" fontSize="11" paddingBottom="0" paddingTop="1">
<mx:columns>
<mx:DataGridColumn width="78" dataField="@isSelected" headerText="">
<mx:itemRenderer>
<mx:Component>
<mx:HBox width="100%" height="100%" horizontalAlign="center">
<mx:CheckBox id="targetCheckBox" selected="{data.@isSelected == 'true'}"
change="outerDocument.checkChangeHandler(event);"/>
<mx:Image horizontalAlign="center" toolTip="Delete" source="@Embed('/assets/icons/delete.png')" useHandCursor="true" buttonMode="true"
click="outerDocument.deleteHandler(event);"/>
<mx:Image id="editButton" horizontalAlign="center" toolTip="Edit" source="@Embed('/assets/icons/edit-icon.png')" useHandCursor="true" buttonMode="true"
click="outerDocument.editHandler(event);"/>
</mx:HBox>
</mx:Component>
</mx:itemRenderer>
</mx:DataGridColumn>
<mx:DataGridColumn id="Name" dataField="@collectionDesc" headerText="Name" itemRenderer="com.foobar.integrated.media.ui.component.CellStyleForTargetName"/>
<mx:DataGridColumn id="Created" width="140" dataField="@createDateTime" headerText="Created" labelFunction="UiHelper.gridDateFormat" />
</mx:columns>
</mx:DataGrid>
This grid is part of a view that will get destroyed and recreated potentially many times during a user's session within the application (there's a large dynamic nature to the app and views are created at run-time.) By destroyed I mean that the view that holds the above datagrid will no longer be referenced under certain circumstances and an entire new view object is created (meaning the old datagrid is no longer refernced and a new one is created.)
I heard you should clean up event handlers when they are no longer used, and I know at what point the view is destroyed, but I don't know how to clean up the event handlers added to the item renderer components? Is it something that the Flex garbage collector will handle efficiently?
Also, on a somewhat related note, how could I push the item renderer to an external component since in my event handlers for the item renderer buttons I need a reference to the datagrid.selectedIndex which, as an external item renderer I wouldn't have access to this containing grid?No. You don't need explicit cleanup in this case: if your outerDocument is going away, you have nothing to worry about. The event handler leak can happen in sort of the reverse situation: suppose you have a long-lived MyView that contains a custom DataGrid like the one below. Now suppose that MyView frequently destroys and re-creates the grid. And suppose that on its creationComplete event, the grid registers a listener for outerDocument's (MyView's) enterFrame Event. Unless you explicitly remove this listener, MyView will still have a reference to it even after the grid that registered the listener is destroyed (and garbage collected).
This is a pretty contrived example, but it sort of illustrates the potential for leaks: a certain component is elligible for garbage collection, but some longer-lived component holds a reference to it (or part of it, such as a listener function). If the longer-lived component is elligible for GC as well, you don't really need to worry about proper cleanup. That's what you're paying the GC processor cycles for. -
Problems with .chart-plot-background and event handlers
Hello. I'm trying to add event handlers to my chart so that the user can be allowed click within the chart itself to perform certain actions like dragging, zooming, etc. To avoid having to deal with handling mouse clicks that lie outside the chart itself (for example on the axes), I've found that:
.chart-plot-background
is the Region that gives me the entire chart and nothing else. However, when I attach mouse listeners to this Region, the event is only registered on half of the cells in the chart. If you've seen the default JavaFX Chart background layout, you know that it contains alternating rows of cells with slightly different coloring. I've found that only the rows with the lightest gray coloring actually register a mouse click on them, which makes me believe the dark grey cells are not part of the .chart-plot-background, but something else on top.
To me, this feels like an oversight in how the regions of the chart are defined. Why can I not get a listener to work on the whole chart and nothing else? Currently the only workaround seems to be to take the Region:
.chart-content
instead, and compute the difference between this region and the .chart-plot-background in order to manually suppress mouse clicks that lie outside .chart-plot-background.
Anyone have suggestions? Is this worth issuing on the JavaFX Jira?Hello,
I'm not an expert on controls, but here is my guess based on your description: when you register an event handler on a "background" node, it is called only when the mouse hovers over the background node - I suppose the light gray is the background with the light gray cells being transparent and dark grey cells being filled. So the behavior seems correct - you can't expect the events to be delivered to background when it is covered by other nodes. I think you really should register the handler on the entire chart and filter out the events you don't want to handle. This however should not require much of computing the difference between the regions, it should be possible to do just something like
if (!background.contains(event.getX(), event.getY())) {
return;
Provided that the background doesn't reach under the axes as well. Note that if there are any different transforms between the background and the node with the handler registered on it, you may need to recompute the coordinates by
background.sceneToLocal(event.getSceneX(), event.getSceneY());
And use the contains method on that. -
Multiple event handlers registered for the same event and error when adding users to sec groups
Project Server 2013 CU April (May) 2014
I've created and installed two event handlers (separate dll:s) and both are triggering on Project Published - initially, both are working fine.
After an IISReset, trying to create a new security group (or add a user to an existing group) will result in an error on the page and a corresponding error in the ULS log - the latter indicating an error in the method security.creategroups, and specifically
a problem 'An item with the same key has already been added.'
An SQL trace reveals a break in execution after executing the proc 'pub.MSP_ADMIN_ReadEventReceivers' which returns all registered event handlers.
In my case, the result of that proc execution shows that there are two event handlers registered with an EVENT_ID of 53 (Project Published) and with ORDER_FIRED set to 1 and 2 respectively.
I tried removing one of the event receivers using the Central Admin PWA interface and then everything worked just fine - I added the event receiver back again, and everything STILL worked! IISReset and I got the error back again. :-(
Since there's obviously some problem with reading multiple entries from that table regardless of the ORDER_FIRED differentiation, I tried temporarily modifying one of the '53' entries in the table directly and then the sec group was created just fine!
I would like to know if anyone else has seen this? I've seen this on three separate installations now after deploying a second event listener onto those systems.
/Lars Hammarberg
//Lars Hammarberg www.connecta.seHi Lars,
yes I have seen the same issue. It is not related to April CU. I had the error before with SP1.
It is not only an issue with the security groups. At least in our case nothing worked at all. No custom field editing, all Queue Jobs failing.
For your case I suggest you consolidate your code in one eventhandler.
Theory says that you can have more than 1 (up to 999) eventhandlers for one Event (http://msdn.microsoft.com/en-us/library/ms481079(v=office.12).aspx) but that seems not to
work. Not sure, if it worked in earlier versions.
Kind regards
Christoph
Christoph Muelder | Senior Consultant, MCTS, MCSE, MCT | SOLVIN information management GmbH, Germany -
Parallel event handlers disabling events while handling
Hi, I have an application where there are multiple event handlers in multiple while loops that are driven from the same front panel. The front panel controls are designed to provide diferent motion control moves for different axes under control. All events that trigger these moves are fired by the same event handler for the same axes of motion. Hence, for safety reasons, I do not want some of these controls to be executable while certain other move profiles are executing. Sounds simple to implement right?
When I use traditional prop nodes like disable to disable the front panel controls, the event queue still acquires the event and then subsequently executes it. I want to be able to clear this event queue so that no other events from a certain group of my front panel controls can be executed simultaneousy. However, I do not want to disable all front panel controls since I have other buttons that are capable of controlling other indepenedent things and safety functions like stopping.
It is like I need a disable events property or soemthing that can be done programmatically. Can someone please advise me on what makes sense to do here?
Attachments:
evntdisable.vi 119 KBThere is no way to interact directly with the event queue that LV maintains. If you need to do that you need to utilize the queue functions that LV provides and create your own event queue. However, if all you need is prevent interactions while an event in being processed, value change events have a setting that is (set by default) called: Lock Panel Until Handler Completes. And for other kinds of events, there's an option in the event structure's event-definition dialog box that perhorms the same action.
Mike...
Certified Professional Instructor
Certified LabVIEW Architect
LabVIEW Champion
"... after all, He's not a tame lion..."
Be thinking ahead and mark your dance card for NI Week 2015 now: TS 6139 - Object Oriented First Steps -
OIM11g - Event handlers - picking up external libraries
Hi all,
I seem to be running into an issue with event handlers. I have to refer to some other custom libraries within them and they don't seem to be accessible by the event handlers.
I've put the libraries in JavaTasks and ThirdParty but I'm still getting NoClassDef found and in the worst case the Orcherstration engine seems to break preventing me from even logging into OIM and meaning I have to remove the event handler metadata manually.
Does anyone know how the event handler classpath works and where I can put libs such that event handlers can use them?
Thanks.
Wayne.From the WebLogic Administrator screen, you can go to the servers for your OIM Server, or SOA Server, whichever will be accessing the jar. Under the server start tab, add in the path in the classpath section for your jar file. User forward slashes. Now when your server starts, it will load those jar files and they should be accessible.
-Kevin -
Hi
I have a requirement of creating a user identity in OIM 11gR2 only when few set of attributes say FirstName, MiddleName and Lastname. If this set of attributes are not exist in OIM then only we have to create the user otherwise not.
So for this purpose we are using Validation Event Handlers, So whenever i am creating a user from OIM console the validation is working but with GTC reconciliation its not working.
I have implemented both the validate(long eventID, long processID, BulkOrchestration orchestration) and validate(long eventID, long processID, Orchestration orchestration) methods under that event handler.
So is it a expected behaviour that validation event handler will not work with Recon?
Can somebody also suggest, what else we can use to satisy this requirement.
Thanks in AdvanceIn this case the values can be null also..So i dont think we can use Required attribute option.
Let me know if you have some diffrent thought on this? -
OIM11 event handlers: How to avoid firing the same code in both pre+post
Hi everyone,
I have a question around event handlers. My experiments so far have gleaned the following:
Manual updates of user form in admin interface -> Fires: pre-insert + Post-insert
Reconciliation trusted creates -> Fires: Post-insert
Reconciliation trusted updates -> Fires: pre-insert + Post-insert
Now I have various handlers that trigger to update fields coming in from trusted recon. Formatting telephone numbers, setting custom user attributes.. etc. I am using the same code in both the post and pre handlers as wherever the update comes from it needs to be processed in the same way. Problem is if a handler fires twice I can't be sure exactly how the system is going to behave (updating the same field again etc), never mind it is unneeded processing.
We have to keep the pre handlers because otherwise changes completed via the admin interface won't be seen until you refresh.
Can anyone please advice how to go about ensuring a handler is only fired once? i.e. if pre fires don't fire post. Have I missed something key here?
Edit: I know I've worded this badly. They will always fire as that's how OIM behaves, what I want is some way to work out in the underlying code if a field has already been modified in pre process... or something like it.
Thanks,
Wayne.
Edited by: wblacklock on 27-Feb-2012 05:38I am sorry but I am not agree with your design.
However there is no chance to avoid this according to my knowledge. As both class has separate thread under different process, so there is no way to implement thread lock on entity operation.
Alternate way to acheive your requirement:
You can have hidden UDFs. Update hidden UDFs in prepost handler with some data (hardcoded).
"You can have the value this hidden filed like :- "NAME_UPDATE|EMAIL_UPDATED|MANGER_UPDATE"
Now in Post - Process handler check the value of hidden UDF.
Get the value of hidden UDF, tokenize with String Tokenizer. Check which filed is not updated in Pre handler.
*If it is already updated - do not update.* else Update.
Thanks,
Kuldeep -
Hi
I am new to web dynpro java . I want to know what are various situations in which Event handlers and Methods are introduced into component controller of a web dynpro component and situations in which individual component subscribe to event in component controller..
Thanks
prasadHi Prasad,
When we write Events and methods inside the component controller those becomes visible throughout the components. So, for example, any action of a view of the component can call such a method of the component controller.
And when we write an Event or Method inside an individual component, it's life cycle remains inside the component only.
This is the basic difference.
Moreover, If you create attributes insdie component controller those becomes known to all methods that are called within a component and can be used by them, provided they have the Public property.
Hope it helps...
Regards,
Sen -
Multiple menu items != multiple event handlers?
I'm developing a program whereby a user can rate how much they like certain images when displayed on screen. The bulk of the work is done, but my rating mechanism (first attempt at one) is currently a right-click pop-up menu with the values 1-10 in ten menu items - naff I know, but its early design stages ;)
This brings obvious problems, and I don't want to have to code event handlers for each and every Menu item just to set the same parameter to a different value depending on which menu item the user clicked (i.e. I don't want to have to create an event for the first menu item that simply sets and int variable to 1, and do the same for #2 through 10). What I was wondering was, is there any simpler way of implementing this? I.e. can I use the same event for the whole popup menu and detect the value of the option clicked and set the value accordingly? This would also mean, should I need to extend the rating scale above ten, say perhaps to twenty, then there would be no further coding necessary (which is nice! Lol!).
Can anyone offer any suggestions? I did search, but tbh didn't have a clue what to search for. Your advice is appreciated.Implement the ActionListner that allows the constructor to take an argument as to the rating of the menu item, and then set the required rating variable to this when called. For example
class MyRatingSystem
int rating = 0;
public void createMenus()
JMenu ratings = new JMenu("Ratings");
for(int i = 0; i < 10; i++)
JMenuItem rating = new JMenuItem("Vote: " + i);
rating.addActionListener(new RatingListener(i));
ratings.add(rating);
class RatingListener imlpements ActionListener{
final int rate;
public RatingListener(int rate)
this.rate = rate;
public void actionPerformed(ActionEvent ae)
rating = this.rate;
}The above code is inefficient and is only there to serve the purpose of an example(look at the loop, although I would think the compiler could do some loop unrolling?)
HTH -
Portal Forms (9ias) JavaScript Event Handlers
For each form field it is possible to write event handlers in Javascript e.g OnFocus
//On BLUR effectively prevents the field from ever gaining
//focus.
this.blur();
There are no PL/SQL event handlers at field level. Is there any way that we can call PL/SQL code from the Javascript event?
Thanks in Advance.In case of do_event(), you can do a view source of the form's runtime page and lookup the code. It's a simple javascript that set values to some hidden variables.
When you do a view source , you will find some javascripts like :-
<SCRIPT TYPE="text/javascript" SRC="<some-url>">
Copy the url and paste it on a new browser window and try to access it. In case of IE, it will prompt you for a file download. Download the file as a text file and you will get to see the code. -
Hello Friends;
I have a problem with event handlers. I have defined events for double_click, data_change and hotspot_click. At first run of the program everything runs fine but when I make a change at the screen (like pressing Enter or entering a value at a screen field) the handlers seem to be called a couple of times. For example at a hotspot click I call an accounting document display and when I want to return with back button the program seems to be stuck at document display. Actually it calls event handler over and over again. How can I solve this problem? Can refreshing grid be a solution?
Thx in advance
AliHello Ali
The problem is that after handling the hotspot event the current cell is still on the field with the hotspot. Thus, when you push ENTER the ALV grid checks the current cell which has a hotspot defined which, in turn, raises event HOTSPOT_CLICK.
Therefore, you have to move the current cell to another cell that has no hotspot defined. Have a look at the implementation of the event handler method. The hotspot is on field KUNNR. After calling transaction XD03 I shift the current cell to field BUKRS.
If you comment these lines you will see the same behaviour of the report as you described.
*& Report ZUS_SDN_TWO_ALV_GRIDS
REPORT ZUS_SDN_ALVGRID_EVENTS.
DATA:
gd_okcode TYPE ui_func,
gt_fcat TYPE lvc_t_fcat,
go_docking TYPE REF TO cl_gui_docking_container,
go_grid1 TYPE REF TO cl_gui_alv_grid.
DATA:
gt_knb1 TYPE STANDARD TABLE OF knb1.
PARAMETERS:
p_bukrs TYPE bukrs DEFAULT '1000' OBLIGATORY.
* CLASS lcl_eventhandler DEFINITION
CLASS lcl_eventhandler DEFINITION.
PUBLIC SECTION.
CLASS-METHODS:
handle_hotspot_click FOR EVENT hotspot_click OF cl_gui_alv_grid
IMPORTING
e_row_id
e_column_id
es_row_no
sender.
ENDCLASS. "lcl_eventhandler DEFINITION
* CLASS lcl_eventhandler IMPLEMENTATION
CLASS lcl_eventhandler IMPLEMENTATION.
METHOD handle_hotspot_click.
* define local data
DATA:
ls_knb1 TYPE knb1,
ls_col_id type lvc_s_col.
READ TABLE gt_knb1 INTO ls_knb1 INDEX e_row_id-index.
CHECK ( ls_knb1-kunnr IS NOT INITIAL ).
SET PARAMETER ID 'KUN' FIELD ls_knb1-kunnr.
SET PARAMETER ID 'BUK' FIELD ls_knb1-bukrs.
CALL TRANSACTION 'XD03' AND SKIP FIRST SCREEN.
* Set active cell to field BUKRS otherwise the focus is still on
* field KUNNR which will always raise event HOTSPOT_CLICK
ls_col_id-fieldname = 'BUKRS'.
CALL METHOD go_grid1->set_current_cell_via_id
EXPORTING
IS_ROW_ID = e_row_id
IS_COLUMN_ID = ls_col_id.
ENDMETHOD. "handle_hotspot_click
ENDCLASS. "lcl_eventhandler IMPLEMENTATION
START-OF-SELECTION.
SELECT * FROM knb1 INTO TABLE gt_knb1
WHERE bukrs = p_bukrs.
* Create docking container
CREATE OBJECT go_docking
EXPORTING
parent = cl_gui_container=>screen0
ratio = 90
EXCEPTIONS
OTHERS = 6.
IF sy-subrc <> 0.
* MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
* WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
* Create ALV grid
CREATE OBJECT go_grid1
EXPORTING
i_parent = go_docking
EXCEPTIONS
OTHERS = 5.
IF sy-subrc <> 0.
* MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
* WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
* Set event handler
SET HANDLER:
lcl_eventhandler=>handle_hotspot_click FOR go_grid1.
* Build fieldcatalog and set hotspot for field KUNNR
PERFORM build_fieldcatalog_knb1.
* Display data
CALL METHOD go_grid1->set_table_for_first_display
CHANGING
it_outtab = gt_knb1
it_fieldcatalog = gt_fcat
EXCEPTIONS
OTHERS = 4.
IF sy-subrc <> 0.
* MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
* WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
* Link the docking container to the target dynpro
CALL METHOD go_docking->link
EXPORTING
repid = syst-repid
dynnr = '0100'
* CONTAINER =
EXCEPTIONS
OTHERS = 4.
IF sy-subrc <> 0.
* MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
* WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
* ok-code field = GD_OKCODE
CALL SCREEN '0100'.
END-OF-SELECTION.
*& Module STATUS_0100 OUTPUT
* text
MODULE status_0100 OUTPUT.
SET PF-STATUS 'STATUS_0100'.
* SET TITLEBAR 'xxx'.
ENDMODULE. " STATUS_0100 OUTPUT
*& Module USER_COMMAND_0100 INPUT
* text
MODULE user_command_0100 INPUT.
CASE gd_okcode.
WHEN 'BACK' OR
'END' OR
'CANC'.
SET SCREEN 0. LEAVE SCREEN.
WHEN OTHERS.
ENDCASE.
CLEAR: gd_okcode.
ENDMODULE. " USER_COMMAND_0100 INPUT
*& Form BUILD_FIELDCATALOG_KNB1
* text
* --> p1 text
* <-- p2 text
FORM build_fieldcatalog_knb1 .
* define local data
DATA:
ls_fcat TYPE lvc_s_fcat.
CALL FUNCTION 'LVC_FIELDCATALOG_MERGE'
EXPORTING
* I_BUFFER_ACTIVE =
i_structure_name = 'KNB1'
* I_CLIENT_NEVER_DISPLAY = 'X'
* I_BYPASSING_BUFFER =
* I_INTERNAL_TABNAME =
CHANGING
ct_fieldcat = gt_fcat
EXCEPTIONS
inconsistent_interface = 1
program_error = 2
OTHERS = 3.
IF sy-subrc <> 0.
* MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
* WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
READ TABLE gt_fcat INTO ls_fcat
WITH KEY fieldname = 'KUNNR'.
IF ( syst-subrc = 0 ).
ls_fcat-hotspot = abap_true.
MODIFY gt_fcat FROM ls_fcat INDEX syst-tabix.
ENDIF.
ENDFORM. " BUILD_FIELDCATALOG_KNB1
Regards
Uwe
Maybe you are looking for
-
Can Burn Ripped Music, Can't Burn Purchased Music
Help!! Ever since installing 7.0.2 I can no longer burn purchased music to CD. Music I ripped from my own CDs burns just fine. Data from desktop burns fine as well as music from other programs such as sonic and Windows Media Player. Actually iTunes w
-
When watching on Apple TV, iTunes is playing another move.
Whenever I watch or browse my playlists on Apple TV, iTunes react as well in making clicking noises, playing songs or playing movies. Why is this?
-
Visual studio performance problem.
Asalam o alekom : i use visual studio when i save changes in my asp.net project it need to click CTRL+S three times to be saved and every time it take a little more time.
-
Error 3253 when updating Apps in iTunes
For a few weeks now, I can't update apps in iTunes on my iMac without having an Error 3253 : reinitializing of the connexion. The configuration of my Mac has not changed and I don't have this problem when I connect from my iPad or when I download on
-
hi all, i have using struts. i have written struts-config file which is giving some error while start the tomcat 5.xxx struts-config shown below <?xml version="1.0" encoding="ISO-8859-1" ?> <!DOCTYPE struts-config PUBLIC "-//Apache