How to add event handler for outlook build in control through programmatically
Hi,<o:p></o:p>
There is requirement in my plug in where i need to intercept outlook native attach file method.If user attach more than specified
exchange limit , i need to perform some operatoin. I found that there is way to add "Onaction" method for built in control like this " <command idMso="AttachFile" onAction="CatchExchangeWarning"/> ".
I have to do the same thing via programmatically .I need to attach this event handler through programmatically since my add is not developed by xml file.
<o:p>Thanks</o:p>
Hello,
It looks like you are interested in the
BeforeAttachmentAdd event of Outlook items. It is fired before an attachment is added to an instance of the parent object. So, you can analyze the attachment object passed as a parameter and set then Cancel argument - set
it to true to cancel the operation; otherwise, set to false to allow the Attachment to
be added.
Also the Outlook object model provides the
AttachmentAdd event for Outlook items. It is fired when an attachment has been added to an instance of the parent object. You can also analyze the attachment object passed as a parameter to the event handler. You will not be able to
cancel the action in that case.
Similar Messages
-
How to add event handling for a menu?
hi,
I have created a menu and few mneu items.
for eachmenu itme , i did event handling and it is workign fine.
it was like this
menuItem = new JMenuItem("Exit",KeyEvent.VK_X);
menuItem.setAccelerator(KeyStroke.getKeyStroke(KeyEvent.VK_X, ActionEvent.ALT_MASK));
menuItem.addActionListener(this);
menu.add(menuItem);
public void actionPerformed(ActionEvent e)
JMenuItem source = (JMenuItem)(e.getSource());
String s = "Action event detected. Event source: " + source.getText();
System.out.println(s);
public void itemStateChanged(ItemEvent e)
JMenuItem source = (JMenuItem)(e.getSource());
String s = "Item event detected. Event source: " + source.getText();
System.out.println(s);
now int he second menu i don't have any menu item and i want to do the event handling for the menu itself. any ideas how to do it. following is the code for the menu
//Build the second menu.
menu2 = new JMenu("Options");
menu2.setMnemonic(KeyEvent.VK_O);
menuBar.add(menu2);
menu2.addActionListener(this); //this does nto workYou were on the right track. However, selecting a menu is different from selecting a menu item. MenuItem chucks an ActionEvent and Menu will send an ItemEvent.
If you pile all action output to one actionPerformed method then be careful of your assumptions on what the source type will be. If by any chance the Menu has sent an ActinoEvent then your code will have caused a ClassCastException.
import java.awt.*;
import java.awt.event.*;
import javax.swing.*;
public class MenuTest implements ActionListener, ItemListener {
JMenuItem menuItem;
JMenu menu1, menu2;
JMenuBar menubar;
JFrame frame;
public MenuTest() {
frame = new JFrame("MenuTest");
frame.setDefaultCloseOperation(frame.EXIT_ON_CLOSE);
menubar = new JMenuBar();
frame.setJMenuBar(menubar);
menu1 = new JMenu("File");
menu1.setMnemonic(KeyEvent.VK_F);
menuItem = new JMenuItem("Exit",KeyEvent.VK_X);
menuItem.setAccelerator(KeyStroke.getKeyStroke(KeyEvent.VK_X, ActionEvent.ALT_MASK));
menuItem.addActionListener(this);
menu1.addItemListener(this);
menu1.add(menuItem);
menubar.add(menu1);
//Build the second menu.
menu2 = new JMenu("Options");
menu2.setMnemonic(KeyEvent.VK_O);
menu2.addActionListener(this); //this does not work
menu2.addItemListener(this); // use this instead
menubar.add(menu2);
JPanel panel = new JPanel();
panel.setPreferredSize(new Dimension(100,100));
frame.getContentPane().add(panel);
frame.pack();
frame.show();
public void actionPerformed(ActionEvent e)
String s = "Action event detected. Event source: " + e.getSource();
System.out.println(s);
public void itemStateChanged(ItemEvent e)
String s = "Item event detected. Event source: " + e.getSource();
System.out.println(s);
public static void main(String[] args) {
new MenuTest();
} -
How to find event handler for save button in salesorders
Hi,
I want perform event based on save button in salesorders.Can you tell me how to find the event handler for
save button.
Regards,
BrahmajiBrahma,
you can find the component, view details by doing an F2.
open the component, the view will be mostly an overview page i.e., the name ends OP etc.,
But your method name will be mostly EH_ONSAVE, you need to find exact view.
F2 does not come up properly for overview pages, you have to look into UI config tool preview and make sure sometimes.
Regards,
Masood Imrani S. -
How to add event handler to JTable?
I need an event listener that tells me whenever a cell has been edited. Does anyone have any ideas on how to implement this. There doesn't seem to be much documentation on the subject.
Thanks in advance..
dosteovHello,
It looks like you are interested in the
BeforeAttachmentAdd event of Outlook items. It is fired before an attachment is added to an instance of the parent object. So, you can analyze the attachment object passed as a parameter and set then Cancel argument - set
it to true to cancel the operation; otherwise, set to false to allow the Attachment to
be added.
Also the Outlook object model provides the
AttachmentAdd event for Outlook items. It is fired when an attachment has been added to an instance of the parent object. You can also analyze the attachment object passed as a parameter to the event handler. You will not be able to
cancel the action in that case. -
How to add event handler in maximize window
I need to add code to maximize event... please help
The listener interface you want is WindowStateListener.
This is Implemented in WindowAdapter so is used in the following example.import java.awt.*;
import javax.swing.*;
import java.awt.event.*;
public class WindowStateTest extends JFrame
JLabel label;
public WindowStateTest()
super("WindowStateTest");
setSize(400,400);
setDefaultCloseOperation(WindowConstants.DISPOSE_ON_CLOSE);
addWindowStateListener(new WindowAdapter()
public void windowStateChanged(WindowEvent e)
if(e.getNewState() == Frame.NORMAL)
((WindowStateTest)e.getSource())
.label.setText("Window is Normal");
else if(e.getNewState() == Frame.MAXIMIZED_BOTH)
((WindowStateTest)e.getSource())
.label.setText("Window is Maximized");
public void windowClosing(WindowEvent e)
{System.exit(0);}
label = new JLabel("Window is Normal");
JPanel p = new JPanel(new FlowLayout());
p.add(label);
getContentPane().add(p, BorderLayout.CENTER);
public static void main(String[] args)
new WindowStateTest().setVisible(true);
} -
How to add fault handling for file adapter??
Hi guys I am new to SOA technology ,I have one scenario in file adapter ,when file adapter reads a file from directory .If file is there then read the file data else it can give user defined exception that the file is not there .How can i write user defined exception in SOA?? Give me any ideas please.............
Thanks in advance..So, you want to (1) Fetch the data from these 3 type of files and (2) Also, store the payload data of the file, which is in XML format, into the same database tables ?
If this is the requirement.. then, I would say, you could :
(1) Read files using file adapter, but not as opaque.. Define schemas conforming to the file structures. In that way, you'll always have the file data read in the form of XML.
(2) Fetch relevant data from such XML payloads of files and insert into database tables. Then, insert the XML payload into WHO column. You might have to convert the xml data into blob/clob before inserting.
Job done ! -
How to use common event handler for selected movie clips?
I have a 50-state map in a flash movie. Each state is a movie
clip.
Goal: when mouse moves over a state or is clicked in a state,
the state will be highlighted in a bright color and a small box
will pop up near the state and display some information about the
state.
Question: I know I can add mouse event handler for each state
movie clip. But this is simply not good since this has to be done
50 times and codes thus scattered different places. Ideally, I only
want to have one script that determines where the mouse position is
when events trigged and then do right things (highlight the state
and display info. in a pop-up). How can this be implemented?
Thanks!There are a number of ways. Which way is best depends on how
you have things set up so far.
E.g. If they have an enumerable naming convention:
e.g. each clip is like state_0 , state_1 etc.
Then you can loop through them and assign them all to the
same mouse event handler via the loop. You would need properties
other than the name of the clip to identify the state. E.g. each
clip could contain its own data or the index could be a pointer to
the state data (objects with state name and info properties) in a
separate array.
//state clips named
for (var i=0;i<50;i++) {
this["state_"+i].stateindex=i;
this["state_"+i].onPress= statePressHandler;
var stateData:Array = [{name:"StateName,info:"this state
Info"}, name:"StateName,info:"this state Info"}, etc...]
function statePressHandler() {
trace(this);
trace(stateData[this.stateindex].name+"="+stateData[this.stateindex].info);
Other ways are possible too but the best approach depends on
how you have named the clips and whether you're creating them with
code or whether they're already on stage from authoring (my guess).
If they're already on stage and they're called "Alaska" etc, then I
would be inclined to put them all inside a container clip that
contains nothing else other than states. It would avoid the need
for an array of clip names or for checking some other specific
property of each clip to determine if its a 'state' clip and not
something else in a for..in loop. -
Event handler for STDIN input?
Hi,
This question will probably require a bit of context - I'm attempting to re-implement in java an application that's currently written in perl. The application is a server helper app that rewriters urls; it receives a request ID and a URL on stdin, does the necessary munging (which can require an external SOAP query), then returns the resulting rewritten URL.
Since the results can be asynchronous due to the need for external queries to build the result, this is currently a multithreaded perl app implemented using perl's POE framework to register an event handler for stdin. That handler fires each time a line of input is received, then feeds the query to a thread pool manager (POE::Component::Pool::Thread, which is conceptually similar to the Executor frameworks). The thread returns the result as a callback registered to another function in the main thread, which then populates the query/result to a cache then outputs the result (with the original query ID) on stdout. Since stdin input and the result callbacks are event-driven, there's no while(true) main loop or other blocking mechanism in the main thread. Unfortunately, it's perl-ness is causing problems due to perl's threading implementation (three words: "copy on init"), so we need to reimplement in a language with a more robust threading implementation (preferably one with copy-on-write for shared objects). So, Java it is.
So far everything's been good - Executor, Callables, and Futures work as I hoped they would for proper thread management, and the internal worker thread logic (XML processing, SOAP, regular expressions, etc) is proving rather simple to adapt. However, the main roadblock I'm hitting is that so far, I have not found a way to register any sort of event handler for STDIN input (or more specifically, InputStreamReader/BufferedStreamReader events). This could be due to search engine pollution - everything I see when I search for documentation on event listeners appears to be GUI-specific (buttons, menus, text areas/forms, etc). I'm just looking for a way to handle a line of STDIN, not a text area on a form.
Any pointers in the right direction will be much appreciated!rekoil wrote:
Maybe I need to rethink the design here...
The main reason I used a callback in the original perl is that there's a large cache structure that gets checked before the thread dispatch, and only cache misses get pushed to a thread for processing. Callbacks from the threads will then add its results to the cache. Thanks to perl's thread model, when I attempted to make the cache a shared structure - in perl, you have to explicitly mark as "shared" variables that you want visible to all threads - the structure wound up getting copied to every thread, and this gave the app an unacceptable memory footprint. So the solution was to use a callback in the main thread to update the cache.
I'm now thinking that if Java's thread model is a bit saner (i.e. a shared object doesn't get copied into every thread), then I could just have each thread update the cache, print its output to STDOUT directly, and avoid the need for the callback. I can then make my input loop simply a while() loop, waiting for the next input to dispatch. Sound sane?Yes I think so.
There is some of this I still don't entirely understand. Your loop sounds better now but it sounds to me like the process is this.
1) read from in
2) call some stuff on the basis of what came in
3) do work
4) workers produce things
5) things written back out
6) read back in??
If you're just going in/out then great. If you are going in/out/in then maybe some sort of PipedInput/Output Streams? It may well be that I got lost in your explanation in which case never mind. -
Override event handler for document events in LiveCycle
I would like to have an email notification when a user opens a policy-protected DRM pdf. Is there a way to override the event handler for Document Open events?
Or perhaps there is a way to access the event database- where can I find this information?Thank you so much for your reply. I have created an external authorization and am following the steps outlined here: http://help.adobe.com/en_US/livecycle/9.0/programLC/help/index.htm?content=001479.html
I have deployed my jar and restarted JBoss. However, now when I try to create a new policy using my external authorization, I do not see an option to add it on the create new policy page. I see only sections for Users and Groups, General Settings, Advanced Settings, and Unchangeable Advanced Settings. Could you please tell me how to add the external authorization?
Also, in the component.xml file, I followed the sample and kept this line: <component-id>com.adobe.livecycle.samples.externalauthorization</component-id>
Should that be changed? If so, to what?
Thanks. -
Event Handling for Graphic Shapes
Hi guys,
I have a problem on the implementation of a piece of software that i'm making, to be more specific i implement a GUI. In this GUI i draw rectangles, lines and that kind of things.
The problem is that i want when clicking on a rectangle, an event to take place such as the drawing of something else, or a message, etc.
How am i to achieve that? I've tried many things but didn't succeeded it unfortunately. How am i going to "give" life to my rectangles by adding event handling for them? What code should i write?
Note: My class extends JPanel & i'm using paint(Graphics g) for drawing the shapes
Thanks,
John.Try this:
import java.awt.*;
import javax.swing.*;
import java.awt.event.*;
import java.awt.geom.*;
import java.util.*;
public class Shapes extends JFrame
DPanel pan = new DPanel();
public Shapes()
addWindowListener(new WindowAdapter()
public void windowClosing(WindowEvent ev)
dispose();
System.exit(0);
setBounds(10,10,400,350);
setContentPane(pan);
setVisible(true);
public class DPanel extends JPanel implements MouseListener
Vector shapes = new Vector();
Shape cs;
public DPanel()
addMouseListener(this);
shapes.add(new Rectangle(20,20,100,40));
shapes.add(new Rectangle(40,80,130,60));
shapes.add(new Line2D.Double(20,150,200,180));
public void paintComponent(Graphics g)
super.paintComponent(g);
Graphics2D g2 = (Graphics2D)g;
for (int j=0; j < shapes.size(); j++)
g2.draw((Shape)shapes.get(j));
g.setColor(Color.red);
if (cs != null) g2.draw(cs);
public void mouseClicked(MouseEvent m) {}
public void mouseEntered(MouseEvent m) {}
public void mouseExited(MouseEvent m) {}
public void mouseReleased(MouseEvent m){}
public void mousePressed(MouseEvent m)
for (int j=0; j < shapes.size(); j++)
Shape s = (Shape)shapes.get(j);
Rectangle r = new Rectangle(m.getX()-1,m.getY()-1,2,2);
if (s.intersects(r))
cs = s;
repaint();
public static void main (String[] args)
new Shapes();
}Noah -
I would like to know how to handle events for messages i maintained in zmesg01.
messages are follow: when gv_spfli is initial
"No such flight available.
when gv_scarr is initial.
"Flight name not available with help of raise event ?
pls suggest.
* CLASS lcl_mytestclass DEFINITION
class lcl_mytestclass definition.
public section.
data: gt_spfli type table of spfli initial size 20,
gt_scarr type table of scarr initial size 20.
methods: get_data.
events: data_not_found.
endclass. "lcl_mytestclass DEFINITION
* CLASS lcl_mytestclass IMPLEMENTATION
class lcl_mytestclass implementation.
method: get_data.
select * from spfli into table gt_spfli.
if ( sy-subrc <> 0 ).
raise event data_not_found.
endif.
select * from scarr into gt_scarr
for all entries in gt_flight where carrname = gt_spfli-carrname.
if sy-subrc <> 0.
" How to call event for flight_name_not_found ?"
raise event flight_name_not_found.
endmethod. "get_data
endclass. "lcl_mytestclass IMPLEMENTATION
* CLASS handler DEFINITION
class handler definition.
public section.
methods handle_event
for event data_not_found of lcl_mytestclass.
endclass. "handler DEFINITION
* CLASS handler IMPLEMENTATION
class handler implementation.
method handle_event.
write: / 'Data not found'.
endmethod. "handle_excess
endclass. "handler IMPLEMENTATION
data: oref type ref to lcl_mytestclass,
h1 type ref to handler.
start-of-selection.
create object: oref, h1.
set handler h1->handle_event for all instances.
call method oref->get_data.
Thanks in advance.
Anee.Hello Anee
Events are not used for this kind of message handling.
If you want to collect all messages then use a message handler (see sample report ZUS_SDN_ABAP_OO_MSG_HANDLING ).
Alternatively, you may define an exception class and raise a class-based exception which contains the detailed error message.
The following sample report is based on the more elaborate Wiki posting
[Message Handling - Finding the Needle in the Haystack|https://wiki.sdn.sap.com/wiki/display/profile/2007/07/09/MessageHandling-FindingtheNeedleintheHaystack]
*& Report ZUS_SDN_ABAP_OO_MSG_HANDLING
*& Thread: Event Handling for messages
*& <a class="jive_macro jive_macro_thread" href="" __jive_macro_name="thread" modifiedtitle="true" __default_attr="1052131"></a>
REPORT zus_sdn_abap_oo_msg_handling.
TYPE-POOLS: abap.
* CLASS lcl_mytestclass DEFINITION
CLASS lcl_mytestclass DEFINITION.
PUBLIC SECTION.
DATA: gt_spfli TYPE TABLE OF spfli INITIAL SIZE 20,
gt_scarr TYPE TABLE OF scarr INITIAL SIZE 20.
METHODS: constructor.
METHODS: get_data
IMPORTING
value(id_carrid) TYPE s_carr_id.
METHODS: has_messages
RETURNING value(rd_result) TYPE abap_bool.
METHODS: display_messages.
EVENTS: data_not_found.
PROTECTED SECTION.
DATA: mo_msglist TYPE REF TO if_reca_message_list.
ENDCLASS. "lcl_mytestclass DEFINITION
* CLASS lcl_mytestclass IMPLEMENTATION
CLASS lcl_mytestclass IMPLEMENTATION.
METHOD constructor.
me->mo_msglist = cf_reca_message_list=>create( ).
ENDMETHOD. "constructor
METHOD has_messages.
IF ( me->mo_msglist->is_empty( ) = abap_false ).
rd_result = abap_true.
ENDIF.
ENDMETHOD. "has_messages
METHOD display_messages.
* define local data
DATA:
ld_handle TYPE balloghndl,
lt_log_handles TYPE bal_t_logh,
ls_profile TYPE bal_s_prof.
" Get log handle of collected message list
ld_handle = me->mo_msglist->get_handle( ).
APPEND ld_handle TO lt_log_handles.
* get a display profile which describes how to display messages
CALL FUNCTION 'BAL_DSP_PROFILE_DETLEVEL_GET'
IMPORTING
e_s_display_profile = ls_profile. " tree & ALV List
* set report to allow saving of variants
ls_profile-disvariant-report = sy-repid.
* when you use also other ALV lists in your report,
* please specify a handle to distinguish between the display
* variants of these different lists, e.g:
ls_profile-disvariant-handle = 'LOG'.
CALL FUNCTION 'BAL_DSP_LOG_DISPLAY'
EXPORTING
i_s_display_profile = ls_profile
i_t_log_handle = lt_log_handles
* I_T_MSG_HANDLE =
* I_S_LOG_FILTER =
* I_S_MSG_FILTER =
* I_T_LOG_CONTEXT_FILTER =
* I_T_MSG_CONTEXT_FILTER =
* I_AMODAL = ' '
* IMPORTING
* E_S_EXIT_COMMAND =
EXCEPTIONS
profile_inconsistent = 1
internal_error = 2
no_data_available = 3
no_authority = 4
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.
ENDMETHOD. "display_messages
METHOD: get_data.
SELECT * FROM spfli INTO TABLE gt_spfli
WHERE ( carrid = id_carrid ).
IF ( sy-subrc NE 0 ).
** RAISE EVENT data_not_found.
IF 1 = 2. MESSAGE e154(bc_datamodel_service). ENDIF.
* Flight not found (table SFLIGHT)
CALL METHOD me->mo_msglist->add
EXPORTING
* is_message =
id_msgty = 'E'
id_msgid = 'BC_DATAMODEL_SERVICE'
id_msgno = '154'
* id_msgv1 =
* id_msgv2 =
* id_msgv3 =
* id_msgv4 =
id_detlevel = '1'
* IMPORTING
* es_message =
ENDIF.
IF ( gt_spfli IS INITIAL ).
ELSE.
SELECT * FROM scarr INTO TABLE gt_scarr
FOR ALL ENTRIES IN gt_spfli
WHERE carrid = gt_spfli-carrid.
ENDIF.
IF ( gt_scarr is initial ).
" How to call event for flight_name_not_found ?"
** RAISE EVENT flight_name_not_found.
IF 1 = 2. MESSAGE e159(bc_datamodel_service) WITH '&all'. ENDIF.
* Airline & not found
CALL METHOD me->mo_msglist->add
EXPORTING
* is_message =
id_msgty = 'E'
id_msgid = 'BC_DATAMODEL_SERVICE'
id_msgno = '159'
id_msgv1 = '&all'
* id_msgv2 =
* id_msgv3 =
* id_msgv4 =
id_detlevel = '2'
* IMPORTING
* es_message =
ENDIF.
ENDMETHOD. "get_data
ENDCLASS. "lcl_mytestclass IMPLEMENTATION
* CLASS handler DEFINITION
CLASS handler DEFINITION.
PUBLIC SECTION.
METHODS handle_event
FOR EVENT data_not_found OF lcl_mytestclass.
ENDCLASS. "handler DEFINITION
* CLASS handler IMPLEMENTATION
CLASS handler IMPLEMENTATION.
METHOD handle_event.
WRITE: / 'Data not found'.
ENDMETHOD. "handle_excess
ENDCLASS. "handler IMPLEMENTATION
DATA: oref TYPE REF TO lcl_mytestclass,
h1 TYPE REF TO handler.
PARAMETER:
p_carrid TYPE s_carr_id DEFAULT 'AA'.
START-OF-SELECTION.
START-OF-SELECTION.
CREATE OBJECT: oref, h1.
** SET HANDLER h1->handle_event FOR ALL INSTANCES.
CALL METHOD oref->get_data( p_carrid ).
IF ( oref->has_messages( ) = abap_true ).
oref->display_messages( ).
ENDIF.
END-OF-SELECTION.
Regards
Uwe -
Unable to get automatic event handling for OK button.
Hello,
I have created a form using creatobject. This form contains an edit control and Search, Cancel buttons. I have set the Search buttons UID to "1" so it can handle the Enter key hit event. Instead its caption changes to Update when i start typing in the edit control and it does not respond to the Enter key hit. Cancel happens when Esc is hit.
My code looks like this -
Dim oCreationParams As SAPbouiCOM.FormCreationParams
oCreationParams = SBO_Application.CreateObject(SAPbouiCOM.BoCreatableObjectType.cot_FormCreationParams)
oCreationParams.UniqueID = "MySearchForm"
oCreationParams.BorderStyle = SAPbouiCOM.BoFormBorderStyle.fbs_Sizable
Dim oForm As SAPbouiCOM.Form = SBO_Application.Forms.AddEx(oCreationParams)
oForm.Visible = True
'// set the form properties
oForm.Title = "Search Form"
oForm.Left = 300
oForm.ClientWidth = 500
oForm.Top = 100
oForm.ClientHeight = 240
'// Adding Items to the form
'// and setting their properties
'// Adding an Ok button
'// We get automatic event handling for
'// the Ok and Cancel Buttons by setting
'// their UIDs to 1 and 2 respectively
oItem = oForm.Items.Add("1", SAPbouiCOM.BoFormItemTypes.it_BUTTON)
oItem.Left = 5
oItem.Width = 65
oItem.Top = oForm.ClientHeight - 30
oItem.Height = 19
oButton = oItem.Specific
oButton.Caption = "Search"
'// Adding a Cancel button
oItem = oForm.Items.Add("2", SAPbouiCOM.BoFormItemTypes.it_BUTTON)
oItem.Left = 75
oItem.Width = 65
oItem.Top = oForm.ClientHeight - 30
oItem.Height = 19
oButton = oItem.Specific
oButton.Caption = "Cancel"
oItem = oForm.Items.Add("NUM", SAPbouiCOM.BoFormItemTypes.it_EDIT)
oItem.Left = 105
oItem.Width = 140
oItem.Top = 20
oItem.Height = 16
Dim oEditText As SAPbouiCOM.EditText = oItem.Specific
What changes do i have to make to get the enter key to work?
Thanks for your help.
Regards,
SheetalHello Felipe,
Thanks for pointing me to the correct direction.
So on refering to the documentation i tried out a few things. But I am still missing something here.
I made the following changes to my code -
oForm.AutoManaged = True
oForm.SupportedModes = 1 ' afm_Ok
oItem = oForm.Items.Add("1", SAPbouiCOM.BoFormItemTypes.it_BUTTON)
oItem.Left = 5
oItem.Width = 65
oItem.Top = oForm.ClientHeight - 30
oItem.Height = 19
oItem.SetAutoManagedAttribute(SAPbouiCOM.BoAutoManagedAttr.ama_Visible, 1, SAPbouiCOM.BoModeVisualBehavior.mvb_Default)
oButton = oItem.Specific
oButton.Caption = "OK"
AND
oForm.Mode = SAPbouiCOM.BoFormMode.fm_OK_MODE
oItem = oForm.Items.Add("1", SAPbouiCOM.BoFormItemTypes.it_BUTTON)
oItem.Left = 5
oItem.Width = 65
oItem.Top = oForm.ClientHeight - 30
oItem.Height = 19
oItem.AffectsFormMode = False
I get the same behaviour OK button changes to update and enter key does not work.
Could you please tell me find what is it that i am doing wrong?
Regards,
Sheetal -
HOW TO: Add /manipulate columns for a GridControl
HOW TO: Add /manipulate columns for a GridControl when the columns (attributes) are from different entity objects.
This HOWTO describes the basic steps of using attributes from different entity objects for a GridControl.
One way you can create a GridControl which contain attributes from different entity objects is to create a view object and base it on the entity objects which contain
the desired attributes.
Here are the basic steps:
1.Create a new view object (or use an existing view object) by selecting File>New from the menu, clicking the Business Components tab and double-clicking
on the View Object icon.
2.In the View Object wizard change the name to something meaningful.
3.Select the entity objects you will base your view object on.
4.Nivigate to the attribute screen and select the attributes you would like to include in your view object from each entity object. At this point you can also create
a new attribute by clicking the "New" button. The new attribute can be a concatenation of other attributes, derived from a calculation etc.
5.In the query panel of the View Object wizard, click "Expert mode" and enter a query statement. You write complex queries such as decoding a set of attribute
values.
6.Add your newly to your newly created view object to the application module by double-clicking on the application module in the navigation pane and selecting
your view object from the list.
7.Create a new row set.
8.Bind row set to a query by editing their queryinfo property and selecting your view object and its attributes from the queryInfo pane.
9.Create a GridControl and bind it to the row set by editing the dataItemName property of the GridControl. Since the GridControl is bound at the row set level
all of the related attributes are automatically added.
nullMichael,
Are you intending this as a commercial solution or a work around?
To take an existing equivalent, one would build a view in the database tailored for each grid in an Oracle Forms application. Or a separate query layered over tables for each form/grid in a Delphi or Access application? Even if it is ninety nine percent the same over half a dozen forms/grids?
And now you've added a whole slew of "slightly different" rowSetInfos to maintain.
So if you wanted to add a column that needs to appear everywhere... you've just increased the workload multi-fold?
That would be a management nightmare, wouldn't it? Not to mention yet more performance cost and a slower system?
Hmmmm..... I'm not sure I like where this is headed... someone needs to do some convincing...
null -
How to create event handler in project online
how to create a remote event handler for project online...
i want to create a event handler onprojectcreating using CSOM...need Help..Hi Abidulla,
Here is a good post from UMT for you to start.
http://www.umtsoftware.com/blog/2013/08/01/project-server-2013-remote-event-handlers/
Hope this helps,
Guillaume Rouyre, MBA, MCP, MCTS | -
How to Call Event Handler Method in Another view
Hi Experts,
Can anybody tell me how to call Event handler Method which is declared in View A ,it Should be Called in
view B,Thanks in Advance.
Thanks & Regards
Santhoshhi,
1) You can make the method EH_ONSELECT as public and static and call this method in viewGS_CM/ADDDOC using syntax
impl class name of view GS_CM/DOCTREE=>EH_ONSELECT "method name.
or
2)The view GS_CM/ADDDOC which contains EH_ONSELECT method has been already enhanced, so I can't execute such kind of operation one more time.
or
3)If both views or viewarea containing that view are under same window , then you can get the instance ofGS_CM/DOCTREE from view GS_CM/ADDDOC through the main window controller.
lr_window = me->view_manager->get_window_controller( ).
lv_viewname = 'GS_CM/DOCTREE '.
lr_viewctrl ?= lr_window ->get_subcontroller_by_viewname( lv_viewname ).
Now you can access the method of view GS_CM/DOCTREE .
Let me know in case you face any issues.
Message was edited by: Laure Cetin
Please do not ask for points, this is against the Rules of Engagement: http://scn.sap.com/docs/DOC-18590
Maybe you are looking for
-
What is the data usage for ipad mini on stand by when connected to WIFI?
We connected 34 ipad mini's for yacht WIFI network that has internet access. Now data usage is 1GB/h higher for the all connections than before. None of the ipad's are used for internet. My question is what is the data usage when ipad is is standby u
-
Screen Reader/508 Compliance - Robohelp
Hello Fellow Robohelpers! I wanted to see if any of you great minds could assist me with a pending issue. I need to verify with my client that RH truly is "508" compliant. They would like to know how to: - ensure that the text size changes in RH when
-
Hi All: In procedure create a parameterize cursor to find the records from another databse through db link. this db link can change at run time, its depand on the region. lets exp there is two db link for R1 and R2. how can i create a cursor with dyn
-
Is there My Content or Nokia Search (local) for s4...
Anybody know of a s40 application that can search local content on the phone just like the Nokia Search s60? I have a 6500 classic and it has a pre installed nokia search but it only searches using web Yahoo.. I have seen some screenshots that the s6
-
Poor burned cd quality from itunes
Everytime I burn a CD from a playlist, it sounds fuzzy? Is there some kind of settings I need to change? I am using the most recent version of iTunes