Push Button Color
Dear Sirs,
How can I change the Push Button Color in Forms 6i?
Thanks
Rehman Ghani
Pakistan
Hi,
try to search in PL/SQL code in your form by the button name... May be it is changed dinamically at execution time?
In what environment are you developing? client/server application? Ebusiness suite?...
Jose L.
Similar Messages
-
Color of the push button in Forms 6i
HI,
I want to change the color of the push button from the default gray color to something else and also the font type. Is it possible? If yes, how to do it ?On Microsoft Windows, the colors of buttons, window title bars, and window borders are controlled by the Windows Control Panel color
settings specified for these elements. You cannot override these colors in Form Builder even by using visual attributes.
The button color attributes are controlled exclusively by the Color facility in the Control Panel.
To define button color attributes do the following :
1. To do this go to 'Settings' + 'control panel'.
2. Double-click on 'display' and select 'appearance' from the menu .
3. Select '3D Objects' from the 'item' list .
4. The background color and the foreground color can be changed to your favourite ones.
But the important thing to note here is that this will affect all the 3D objects in all the applications in your system .
Or you can try this workaround if it is suitable. Use a display item with a "Bevel" property of "Raised" and the "Default Value"
property whatever the label should be. Then attach a WHEN-MOUSE-CLICK trigger to it. You can change the foreground and background colors to whatever you want since it's really just a field.
Abhijith Unnikannan,
Oracle Support Services
null -
Get # from JTextfield, draw that # ovals, push button for color
all
i have an assignment that requires the user to enter a JTextField integer value.
that value is then used to draw an equal # of ovals.
after the ovals are drawn user selects a color button (red/blue) to fill the ovals already drawn based on the button color.
i have everything coded and working except the coloring.
i need help because i can't seem to figure out where or how to fill the ovals with the colors of the button pushed.
OvalDriver7b invokes OvalFrame7B invokes OvalPanel7B.
thanx
75gator
* OvalDriver7B.java
* Created on April 26, 2004, 1:50 PM
* @author dbraxton
// declare OvalDriver7b class
public class OvalDriver7B {
public static void main (String [ ] args) {
OvalFrame7B oframe = new OvalFrame7B();
oframe.setTitle("Request ovals by text ");
oframe.show();
}// terminate main
}// terminate OvalDriver7B
* OvalFrame7B.java
* Created on April 26, 2004, 2:35 PM
// @author dbraxton
// import JAVA API classes
import java.awt.*;
import java.awt.event.*;
import javax.swing.*;
// class declaration
public class OvalFrame7B extends JFrame {
private JTextField numOvals;
private JLabel labelField;
private JButton rButton, bButton;
private JPanel textPanel, buttonPanel;
private OvalPanel7B opanel;
final int WIDTH = 300;
final int HEIGHT = 300;
public OvalFrame7B() {
setSize(800,565);
this.addWindowListener(new WindowCloser());
opanel = new OvalPanel7B();
labelField = new JLabel("Enter integer for # ovals: ");
numOvals = new JTextField(2);
rButton = new JButton("RED");
bButton = new JButton("BLUE");
numOvals.addActionListener(new TextFieldListener());
Color rColor = new Color(255,0,0);
Color bColor = new Color(0,0,255);
buttonPanel = new JPanel();
buttonPanel.setLayout(new GridLayout (1,2));
buttonPanel.add(rButton);
buttonPanel.add(bButton);
//JButton colorButton = new JButton("Change circle color?");
//colorButton.addActionListener(new ColorListener());
rButton.addActionListener(new ActionListener() {
public void actionPerformed(ActionEvent event) {
//color ovals red ????????
opanel.repaint();
bButton.addActionListener(new ActionListener() {
public void actionPerformed(ActionEvent event) {
//color ovals blue ????????
opanel.repaint();
textPanel = new JPanel();
textPanel.setLayout(new GridLayout (1,2));
textPanel.add(labelField);
textPanel.add(numOvals);
Container contentPane = getContentPane();
contentPane.setLayout(new BorderLayout());
contentPane.add(opanel, "Center");
contentPane.add(textPanel, "South");
contentPane.add(buttonPanel, "North");
private class TextFieldListener implements ActionListener {
public void actionPerformed(ActionEvent event) {
String input = numOvals.getText();
opanel.setOvalCount(Integer.parseInt(input));
numOvals.setText("");
private class WindowCloser extends WindowAdapter {
public void WindowClosing (WindowEvent wex) {
System.exit(0);
* OvalPanel7B.java
* Created on April 26, 2004, 2:35 PM
* @author dbraxton
// import JAVA API classes
import javax.swing.*;
import java.awt.*;
import java.awt.geom.*;
import java.util.Random;
// begin class declaration
class OvalPanel7B extends JPanel {
private int ovalcount;
private static final double O_WIDTH = 50;
private static final double O_HEIGHT = 100;
double w1 = 100, h1 = 100;
OvalPanel7B() {
public void paintComponent(Graphics g) {
super.paintComponent(g);
Graphics2D g2 = (Graphics2D) g;
Random rnd = new Random();
g2.setBackground(Color.WHITE);
for ( int i=0; i < ovalcount; i++) {
double x = rnd.nextDouble() + w1;
double y = rnd.nextDouble() + h1;
w1 = w1 + 50;
h1 = h1 + 0;
Ellipse2D.Double oval = new Ellipse2D.Double(x,y,O_WIDTH,O_HEIGHT);
g2.setColor(Color.BLACK);
if ( i % 2 > 0) {
g2.draw(oval);
else
x = rnd.nextDouble() + w1;
y = rnd.nextDouble() + h1;
g2.draw(oval);
}w1 = 100; h1 = 100;
public void setOvalCount (int cntx) {
ovalcount = cntx;
repaint();
}Hi,
This forum is for asking questions about using Sun Java Studio so the kind of people who might know the answer might not be reading these posts.
I am thinking that a better place to get answers for this question is https://java-net.dev.java.net/servlets/ForumMessageList?forumID=95 -
How do I change the color of the small LED inside a Push Button
One of my colleagues managed to accidentally change the color of the LED inside the Push Button. He didn’t know how he did it and we couldn’t figure out how to change it back. It’s easy enough to replace the Push Button with a fresh copy from the Buttons & Switches pallet but I would like to know how to control this parameter. Does anyone know how to do this?
Hi Bob,
Could you help us help you?
Please post a VI with the troubling pushbutton so we can see the issue.
If you are talking about the LED shown in the attached jpg,
that color can NOT be changed at run-time. Use the Paintbrush.
Ben
Message Edited by Ben on 10-14-2005 10:26 AM
Ben Rayner
I am currently active on.. MainStream Preppers
Rayner's Ridge is under construction
Attachments:
Led.JPG 20 KB -
Colored push buttons. It doesn't work on client/server.
I've changed the Background Color property to 'darkyellow' for a push button, but it only shows up colored on the web. Why not in client/server environment ?
BobForms has a separation of UI and the Logic. This is why even in client-server a button will look different on Solaris and Windows. Forms throws the actual drawing of the button(all widgets) off to the underlying operating system. Windows does not allow you to set the background color for a button so the property is ignored.
When Forms runs over the web the UI is rendered as a Java Applet and Windows no longer has control of drawing the widgets.
Hope this helps,
Candace Stover
Forms Product Management -
I was playing a game. Game response was sluggish. I pushed button to exit game and go back to main screen. Took several times to get a response from iPad. The response was a black screen with horizontal colored lines similar to horizontal roll on an old TV. Screen went black and will not come back on. Attempted sync, but iPad no longer shows up in iTunes. Help!
Have you tried a reset ? Press and hold both the sleep and home buttons for about 10 to 15 seconds, after which the Apple logo should appear - you won't lose any content, it's the iPad equivalent of a reboot.
-
Prob with Push Buttons in the selection screen
Hi All,
1) I have 6 push buttons in the selection screen(Normal Report), 3 in a first row(P11, P12, P13) and 3 in the second row(P21, P22, P23). If I press one push button(for ex P11) the other two Push buttons(P12 P13) should grey out(Inactive mode). If I press P22, P21 & P23 shoul grey out.
2) I need color change for the Inactive push buttons.
Thanks
KrisCan you please post your selection screen definition? I don't understand what you want to achieve by greying out the other pushbuttons when one is pressed.
Does that mean pushing one button will do nothing except greying out the buttons?
Typically when you push a button, you want to continue to execute the required processing for that button not just grey out other pushbuttons and stay in the selection screen.
Anyway, you can achieve that using the following logic. I am not sure how and if you can achieve the color change.
TABLES: sscrfields.
DATA: v_button_pushed(5).
SELECTION-SCREEN PUSHBUTTON /1(10) p11 USER-COMMAND push1.
SELECTION-SCREEN PUSHBUTTON 12(10) p12 USER-COMMAND push2.
SELECTION-SCREEN PUSHBUTTON 23(10) p13 USER-COMMAND push3.
SELECTION-SCREEN PUSHBUTTON /1(10) p21 USER-COMMAND push4.
SELECTION-SCREEN PUSHBUTTON 12(10) p22 USER-COMMAND push5.
SELECTION-SCREEN PUSHBUTTON 23(10) p23 USER-COMMAND push6.
INITIALIZATION.
p11 = 'Push11'.
p12 = 'Push12'.
p13 = 'Push13'.
p21 = 'Push21'.
p22 = 'Push22'.
p23 = 'Push23'.
AT SELECTION-SCREEN OUTPUT.
CASE v_button_pushed.
WHEN 'PUSH1'.
LOOP AT SCREEN.
CHECK screen-name <> 'P11'.
screen-input = 0.
MODIFY SCREEN.
ENDLOOP.
WHEN 'PUSH2'.
WHEN 'PUSH3'.
WHEN 'PUSH4'.
WHEN 'PUSH5'.
WHEN 'PUSH6'.
WHEN OTHERS.
ENDCASE.
AT SELECTION-SCREEN.
v_button_pushed = sscrfields-ucomm. -
Push Buttons, Radio Buttons, Folder Tabs
Could someone please let me in on the secret to selecting
background colors for push-buttons, radio-buttons and folder
tabs. I've tried the obvious properties with no luck.
I am developing on a Windows NT 4.0 platform using Developer
6.0. I will be releasing my app to the web soon and could
really use some help.
Ideally, I would like to be able to select any color ( i.e. to
match the background color of the canvas ), but so far the only
choices seem to be black, white or a couple of other non-
desirable colors ( bright red, green, yellow, yuck! ). Is a
custom color palette the ticket?
I realize that many button properties are controlled by Windows.
If this is the case, are there any work-arounds? When I
distribute the application, will I be able to offer my customers
the ability to configure Windows to correctly define the button
colors?
I am sure that others have these same questions. I have not
been able to find any answers. Any help is greatly appreciated.
Mike
[email protected]
nullHi,
1. Disabling Push button.
In PBO loop at sccreen and check the field name is equal to push button name
set screen-input = 0.
modify screen.
endloop.
2.assign a function code to radio button in screen element it will trigger the PAI.
In PAI during loop at table control check the field value is equal to 'X'.then not down the roqw number and in PBO enable the button based on the row number by looping at screen.
3Assign the fcode to push button.Once the user presses the button in PAI check the focde and see for which line it is pressed based on it call the pop up screen using FM or dialog box.
Regards,
Nabheet Madan
Never give Up.
Edited by: nabheet1234 on May 11, 2009 2:26 PM
Edited by: nabheet1234 on May 11, 2009 2:27 PM -
ALV GRID-how to select all the check boxes using push button
Hai All,
I displayed ALV grid & every record contains one check box as first column.
If user clicks on one push button all the check boxes needs to selected.
Could any one tell me how to do this?
Regards,
BhaskarHi Bhaskar,
Try this code :
*" Table declarations...................................................
TABLES :
spfli. " Flight Schedule
*" Data declarations...................................................
Work variables *
DATA :
w_checkbox TYPE c, " Check Box
w_checkbox1 TYPE c, " Check Box
w_lineno LIKE sy-lilli, " Current Line No
w_lines TYPE i. " No. Of Records in Int.Table
Internal table to hold Flight Schedule data *
DATA :
t_spfli LIKE
STANDARD TABLE
OF spfli.
Structure to hold Function Codes *
DATA :
fs_fcode LIKE LINE OF t_fcode.
TOP-OF-PAGE EVENT *
TOP-OF-PAGE.
PERFORM top_of_page.
START-OF-SELECTION EVENT *
START-OF-SELECTION.
PERFORM fetch_spfli_data.
SET PF-STATUS 'YMENU1'.
DESCRIBE TABLE t_spfli LINES w_lines.
fs_fcode = 'EXIT'.
APPEND fs_fcode TO t_fcode.
fs_fcode = 'SELECT'.
APPEND fs_fcode TO t_fcode.
fs_fcode = 'DESELECT'.
APPEND fs_fcode TO t_fcode.
fs_fcode = 'RETRIEVE'.
APPEND fs_fcode TO t_fcode.
AT USER-COMMAND EVENT *
AT USER-COMMAND.
PERFORM user_command.
FORM top_of_page .
WRITE :/50 'Flight Schedule Information'(008).
ULINE.
FORMAT COLOR 1.
WRITE :/10 'Carrier ID'(001),
25 'Connection ID'(002) ,
43 'Airport From'(003),
59 'Airport To'(004),
74 'Departure Time'(007),
93 'Arrival Time'(011),
106 space.
ENDFORM. " FORM TOP_OF_PAGE
FORM fetch_spfli_data .
SELECT carrid " Carrier ID
connid " Connection ID
airpfrom " Airport From
airpto " Airport To
deptime " Departure Time
arrtime " Arrival Time
FROM spfli
INTO CORRESPONDING FIELDS OF
TABLE t_spfli.
IF sy-subrc EQ 0.
PERFORM display_spfli_data.
ENDIF. " IF SY-SUBRC EQ 0
ENDFORM. " FORM FETCH_SPFLI_DATA
FORM display_spfli_data .
SORT t_spfli BY carrid ASCENDING.
LOOP AT t_spfli INTO spfli.
FORMAT COLOR 2.
WRITE :/2 w_checkbox AS CHECKBOX,
spfli-carrid UNDER text-001,
spfli-connid UNDER text-002,
spfli-airpfrom UNDER text-003,
spfli-airpto UNDER text-004,
spfli-deptime UNDER text-007,
spfli-arrtime UNDER text-011.
ENDLOOP. " LOOP AT T_SPFLI...
ENDFORM. " FORM DISPLAY_SPFLI_DATA
FORM user_command .
CASE sy-ucomm.
WHEN 'SELECT'.
w_checkbox1 = 'X'.
DO w_lines TIMES.
w_lineno = sy-index + 3.
READ LINE w_lineno FIELD VALUE w_checkbox.
IF w_checkbox = '*'.
CONTINUE.
ELSE.
MODIFY LINE w_lineno FIELD VALUE w_checkbox FROM w_checkbox1.
ENDIF. " IF W_CHECKBOX = '*'
ENDDO. " DO W_LINES TIMES.
WHEN 'DESELECT'.
w_checkbox1 = ' '.
DO w_lines TIMES.
w_lineno = sy-index + 3.
READ LINE w_lineno.
IF w_checkbox = '*'.
CONTINUE.
ELSE.
MODIFY LINE w_lineno FIELD VALUE w_checkbox FROM w_checkbox1.
ENDIF. " IF W_CHECKBOX = '*'
ENDDO. " DO W_LINES TIMES.
WHEN 'RETRIEVE'.
w_checkbox = ' '.
DO w_lines TIMES.
w_lineno = sy-index + 3.
READ LINE w_lineno FIELD VALUE w_checkbox INTO w_checkbox.
IF w_checkbox = 'X'.
PERFORM fetch_sflight_data.
PERFORM display_sflight_data.
ENDIF. " IF W_CHECKBOX = 'X'
ENDDO. " DO W_LINES TIMES.
ENDCASE. " CASE SY-UCOMM
ENDFORM. " FORM USER_COMMAND
This report gives you the SPFLI Data and places a check box in front of each record. When u click on select all button it will select all the records. And if you click on deselect all it will deselect all the records. When you are trying this maintain the pf-status 'YMENU1' and give the function codes as in the code.
Regards,
Swapna. -
How do I use a push button digital trigger with my 6034E DAQ board?
I am only a Lab View toddler.
I am currently using a push button, wired to PFIO/TRIG1 and DGND, with a anolog trigger. However noise is causing my program to be triggered. I was told that a digital trigger would help to reduce the random triggering. How do I create a push button digital trigger?
Thanksimplement a schmitt trigger.
Struggling with Labview wrote in message
<[email protected]>...
>I am only a Lab View toddler.
>I am currently using a push button, wired to PFIO/TRIG1 and DGND, with
>a anolog trigger. However noise is causing my program to be triggered.
>I was told that a digital trigger would help to reduce the random
>triggering. How do I create a push button digital trigger?
>Thanks -
Push button query!!!!!!! help needed
hello all,
I HAVE USED THIS LOGIC FOR MAKING THE DATA ASCENDING AND
DESECENDING,AND TRIED ALL THE
SOLUTIONS THAT WERE SUPPLIED BY MY FRIENDS IN THIS GROUP,BUT COULD NOT
CHANGE THE
VISUAL ATTRIBUTE OF THE BUTTON.I AM REPEATING MY QUERY.I WANT TO HAVE
THE
PUSH BUTTON TO SIGNIFY VISUALLY THE ASCENDING AND DESCENDING DATA I.E
WHEN THE
DATA COMES IN THE ASCENDING WAY,THE PUSH BUTTON
SHOULD HAVE A "inverted v"ACC CODE"" ALONG WITH NAME "ACC CODE" I.E IT SHOULD
LOOK LIKE "ACC CODE "ACC CODE inverted v "
AND WHEN THE DATA COMES IN THE DESCENDING WAY,THE PUSH BUTTON
SHOULD HAVE A " v".I.E IT SHOULD
LOOK LIKE "ACC CODE "ACC CODE' v' ".SO PLZ HELP me TO GET THIS .
Any changes should be made to nls_lang parameter in registry???????????
PLZ LET ME KNOW WHAT IS FONT THAT I SHOULD USE.U CAN CHANGE THE CODING
THAT I HAVE WRITTEN
IN THE "WHEN BUTTON PRESSED" TRIGGER OF ACC_CODE.
BEGIN
go_block('age_tran');
BEGIN
IF
get_item_property('PB_ACC_ORDER',LABEL)='&Acc Code' THEN
set_block_property('age_tran',order_by,'acc_code ASC');
execute_query(no_validate);
SET_ITEM_PROPERTY('PB_ACC_ORDER',LABEL,'&Acc Code'||'
'||upper(chr(94)));
ElSIF
get_item_property('pb_acc_order',LABEL)='&Acc Code'||'
'||upper(chr(94)) THEN
Set_block_property('age_tran',order_by,' acc_code DESC');
execute_query(no_validate);
SET_ITEM_PROPERTY('pb_acc_order',LABEL,'&Acc Code'||' '||'v');
ELSE
Set_block_property('age_tran',order_by,'BALANCE DESC');
execute_query(no_validate);
SET_ITEM_PROPERTY('pb_acc_order',LABEL,'&Acc Code');
END IF;
END;
END;
THANKING UHi Shiju,
U can use the combination of fornt slash(/) and back slash(\) to fulfil ur requirement.
For ascending u can use /\ and for descending u can use \/. Does this solve the purpose?
I think it will.
Suprabhat. -
Help with getting button color.
I'm trying to make a little paint program. i want to be able to click on a color button and then assign the color of that button to a variable Color brushColor.
funny thing is, when i compile this, it tells me that
C:\java\javaprograms\TryPainting.java:21: getBackground() in java.awt.Component cannot be applied to (java.awt.Button)
brushColor = paintTheBrush(getBackground(source));
strange, getBackground is explicitly listed as a method that Button inherits from Component in the API.
any suggestions on a way to accomplish this?
thanks in advance,
jason
------code follows-------
import javax.swing.*;
import javax.swing.text.*;
import java.awt.*;
import java.awt.event.*;
//colored buttons of "paint"
class OilPaint extends Button{
Color brushColor = Color.white;
OilPaint(String label, Color color) {
setLabel(label);
setForeground(color);
setBackground(color);
addActionListener(new ActionListener() {
public void actionPerformed(ActionEvent e) {
Button source = (Button)e.getSource();
brushColor = getBackground(source);
public Color paintTheBrush(Color color) {
return color;
// canvas to paint on - this isn't working yet. can't even get the
// setSize to work, though it does compile.
class Canvas extends JPanel{
Canvas(){
setBackground(Color.white);
Dimension canSize = new Dimension(300,300);
setSize(canSize);
// displays the lsit of color button choices in a small panel at bottom
// of window
class ColorChoices extends JPanel{
ColorChoices() {
setBackground(new Color(220,255,255));
add(new OilPaint("paint",Color.blue));
add(new OilPaint("paint",Color.red));
add(new OilPaint("paint",Color.green));
add(new OilPaint("paint",Color.white));
add(new OilPaint("paint",Color.black));
//this is the main class of the program TryPainting.java
class TryPainting {
public static void main(String[] args) {
JFrame window = new JFrame();
Toolkit toolkit = window.getToolkit();
Dimension winSize=toolkit.getScreenSize();
window.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
window.setBounds(5,5,winSize.width/2,winSize.height/2);
Container content = window.getContentPane();
content.setLayout(new BorderLayout());
content.add("North",new Canvas());
content.add("South",new ColorChoices());
window.setVisible(true);duh.. thanks man, that did the trick. i'm pretty new at this. i really appreciate the help. i got stuck thinking of the getBackground() as a function, rather than a method. this oop stuff is wacky weird fun!
jason -
How can I open a .pdf file in a browser on a click on a push button
I am using oracle 10g developer suit for form designing.
There is a .pdf file in the application server.
I want it to open it in a browser when a push button is clicked.
Could you please tell me how can I do that?
Regardshi
u can use web.show_document() for that.
but if you want to open pdf file only then use
client_host()
sarah -
How to get GUI Status(Push Buttons) in ALV Report
Hi Friends
I have a requirement in a way that:
Once selection-screen was processed,an ALV report has to come and above the ALV List,I need a custom GUI Status(4 Push Button) with Push Buttons Logic.
Once I had clicks on thesse push button,I need to display one more ALV List and above this List,again I need a custom GUI Status(2 Push Buttons) with Push Buttons Logic.
Can anyone throw some light how we can achieve this.
Thanks for your cooperation!
Regards,
Madisettydata: rt_extab type slis_t_extab,
g_ucomm like sy-ucomm ,
g_selfield type slis_selfield.
form alv_display .
call function 'REUSE_ALV_LIST_DISPLAY'
exporting
i_callback_program = g_repid
i_callback_pf_status_set = 'PF_STATUS'
i_callback_user_command = 'USER_COMM'
it_fieldcat = it_fldcat
tables
t_outtab = it_final1
perform pf_status using rt_extab.
perform user_comm using g_ucomm g_selfield .
endform.
form pf_status using p_rt_extab.
set pf-status 'PF_STATUS' excluding p_rt_extab.
endform.
form user_comm using p_ucomm like sy-ucomm
p_selfield type slis_selfield.
data: l_row type i.
case p_ucomm.
when 'DISPLAY_PO'.
loop at it_final1 into wa_final1.
if wa_final1-sel eq 'X' .
l_row = l_row + 1.
endif.
if l_row gt 1.
message e004.
endif.
clear wa_final1.
endloop.
p_selfield-fieldname = 'SEL'.
read table it_final1 into wa_final1 index p_selfield-tabindex .
set parameter id 'BES' field wa_final1-ebeln.
call transaction 'ME23N'.
endcase.
endform.
*create user interface for gui status by double clicking on 'PF_STATUS'.
*Check the above sample code . -
Dear Experts,
How to add pushbutton in alv report.....
*& Report ZTT_TEST_ALV
REPORT ZTT_TEST_ALV.
*data declarations
type-pools : SLIS.
* data : BEGIN OF wa_kna1,
* kunnr type kunnr,
* name1 type name1,
* end of wa_kna1,
* it_kna1 like tABLE OF wa_kna1.
data : begin of wa_mara,
matnr type matnr,
end of wa_mara,
it_mara like table of wa_mara.
data : it_fcat type slis_t_fieldcat_alv,
wa_fcat like line of it_fcat.
*selection screen
SELECTION-SCREEN begin of block k with frame title text-001.
* select-OPTIONS : s_kunnr for wa_kna1-kunnr.
select-OPTIONS : s_matnr for wa_mara-matnr.
SELECTION-SCREEN end of block k.
*select auery
*SELECT kunnr name1 INTO table it_kna1 from kna1 where kunnr in s_kunnr.
select matnr into table it_mara from mara where matnr in s_matnr.
*for displaying fieldcatalog
PERFORM fcat using '1' 'MATNR' 'material Number' 'C410' '20'.
* PERFORM fcat using '2' 'NAME1' 'Customer Name' 'C410' '36'.
*for displaying output
CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
EXPORTING
* I_INTERFACE_CHECK = ' '
* I_BYPASSING_BUFFER = ' '
* I_BUFFER_ACTIVE = ' '
* I_CALLBACK_PROGRAM = ' '
I_CALLBACK_PF_STATUS_SET = 'SET_PF_STATUS'
* I_CALLBACK_USER_COMMAND = ' '
* I_CALLBACK_TOP_OF_PAGE = ' '
* I_CALLBACK_HTML_TOP_OF_PAGE = ' '
* I_CALLBACK_HTML_END_OF_LIST = ' '
* I_STRUCTURE_NAME =
* I_BACKGROUND_ID = ' '
I_GRID_TITLE = 'Report for Customer Details'
* I_GRID_SETTINGS =
* IS_LAYOUT =
IT_FIELDCAT = it_fcat[]
* IT_EXCLUDING =
* IT_SPECIAL_GROUPS =
* IT_SORT =
* IT_FILTER =
* IS_SEL_HIDE =
* I_DEFAULT = 'X'
* I_SAVE = ' '
* IS_VARIANT =
* IT_EVENTS =
* IT_EVENT_EXIT =
* IS_PRINT =
* IS_REPREP_ID =
* I_SCREEN_START_COLUMN = 0
* I_SCREEN_START_LINE = 0
* I_SCREEN_END_COLUMN = 0
* I_SCREEN_END_LINE = 0
* I_HTML_HEIGHT_TOP = 0
* I_HTML_HEIGHT_END = 0
* IT_ALV_GRAPHICS =
* IT_HYPERLINK =
* IT_ADD_FIELDCAT =
* IT_EXCEPT_QINFO =
* IR_SALV_FULLSCREEN_ADAPTER =
* IMPORTING
* E_EXIT_CAUSED_BY_CALLER =
* ES_EXIT_CAUSED_BY_USER =
TABLES
t_outtab = it_mara.
* EXCEPTIONS
* PROGRAM_ERROR = 1
* OTHERS = 2
IF sy-subrc <> 0.
* MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
* WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
*CALL FUNCTION 'REUSE_ALV_HIERSEQ_LIST_DISPLAY'
* EXPORTING
**** I_INTERFACE_CHECK = ' '
**** I_CALLBACK_PROGRAM =
**** I_CALLBACK_PF_STATUS_SET = ' '
**** I_CALLBACK_USER_COMMAND = ' '
**** IS_LAYOUT =
* IT_FIELDCAT = it_fcat
**** IT_EXCLUDING =
**** IT_SPECIAL_GROUPS =
**** IT_SORT =
**** IT_FILTER =
**** IS_SEL_HIDE =
**** I_SCREEN_START_COLUMN = 0
**** I_SCREEN_START_LINE = 0
**** I_SCREEN_END_COLUMN = 0
**** I_SCREEN_END_LINE = 0
**** I_DEFAULT = 'X'
**** I_SAVE = ' '
**** IS_VARIANT =
**** IT_EVENTS =
**** IT_EVENT_EXIT =
*** i_tabname_header =
*** i_tabname_item =
**** I_STRUCTURE_NAME_HEADER =
**** I_STRUCTURE_NAME_ITEM =
*** is_keyinfo =
**** IS_PRINT =
**** IS_REPREP_ID =
**** I_BYPASSING_BUFFER =
**** I_BUFFER_ACTIVE =
**** IR_SALV_HIERSEQ_ADAPTER =
**** IT_EXCEPT_QINFO =
**** I_SUPPRESS_EMPTY_DATA = ABAP_FALSE
**** IMPORTING
**** E_EXIT_CAUSED_BY_CALLER =
**** ES_EXIT_CAUSED_BY_USER =
* tables
** t_outtab_header = it_
* t_outtab_item = it_kna1.
**** EXCEPTIONS
**** PROGRAM_ERROR = 1
**** OTHERS = 2
***IF sy-subrc <> 0.
**** MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
**** WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
***ENDIF.
*& Form FCAT
* text
* -->P_0052 text
* -->P_0053 text
* -->P_0054 text
form FCAT using fp_col_pos
fp_fieldname
fp_seltext_m
fp_emphasize
fp_outputlen..
wa_fcat-col_pos = fp_col_pos.
wa_fcat-fieldname = fp_fieldname.
wa_fcat-seltext_m = fp_seltext_m.
wa_fcat-emphasize = fp_emphasize.
wa_fcat-outputlen = fp_outputlen.
append wa_fcat to it_fcat.
clear : wa_fcat.
endform. " FCAT
FORM SET_PF_STATUS .
SET PF-STATUS 'ZNEWSTATUS' .
"Copy of 'STANDARD' pf_status from fgroup SALV
endform.
i need one push button in alv output display.
Thanks and Regards,
Thirukumaran. RHI THIRU TRY FOLLOWING CODES:
*& Report ZSAMPLE
REPORT ZSAMPLE.
TABLES:MARA.
TYPE-POOLS: SLIS.
TYPES:BEGIN OF TY_ITAB,
MATNR LIKE MARA-MATNR,
ERSDA LIKE MARA-ERSDA,
END OF TY_ITAB.
DATA:ITAB TYPE STANDARD TABLE OF TY_ITAB WITH HEADER LINE.
DATA:FCAT TYPE SLIS_T_FIELDCAT_ALV,
WA_FCAT TYPE SLIS_FIELDCAT_ALV,
LAYOUT TYPE SLIS_LAYOUT_ALV,
WA_LAYOUT TYPE SLIS_LAYOUT_ALV.
SELECTION-SCREEN BEGIN OF BLOCK B1 WITH FRAME TITLE TEXT-001.
PARAMETERS:P_MATNR TYPE MARA-MATNR.
SELECTION-SCREEN END OF BLOCK B1.
START-OF-SELECTION.
PERFORM FIELDCAT.
LAYOUT-ZEBRA = 'X'.
PERFORM OUTPUT.
*& Form PF_STATUS
text
-->RT_EXTAB text
FORM PF_STATUS USING RT_EXTAB TYPE SLIS_T_EXTAB.
SET PF-STATUS 'BUTT'.
ENDFORM. "PF_STATUS
*& Form PUSH_BUTT1
text
-->R_UCOMM text
-->RS_SELFIELD text
FORM GET USING R_UCOMM LIKE SY-UCOMM RS_SELFIELD TYPE SLIS_SELFIELD.
CASE R_UCOMM.
WHEN 'GET'.
IF SY-SUBRC EQ 0.
CALL TRANSACTION 'SE11'.
ELSE.
ENDIF.
WHEN 'EXIT' OR 'CANCEL' .
LEAVE PROGRAM.
ENDCASE.
ENDFORM. "PUSH_BUTT1
*& Form FIELDCAT
text
--> p1 text
<-- p2 text
FORM FIELDCAT .
WA_FCAT-SELTEXT_L = 'Select'.
WA_FCAT-COL_POS = '1'.
WA_FCAT-FIELDNAME = 'CHECK'.
WA_FCAT-CHECKBOX = 'X'.
WA_FCAT-TABNAME = 'ITAB'.
WA_FCAT-OUTPUTLEN = '4'.
WA_FCAT-INPUT(1) = 'X'.
WA_FCAT-EDIT_MASK(1) = 'X'.
WA_FCAT-EDIT(1) = 'X'.
APPEND WA_FCAT TO FCAT.
CLEAR WA_FCAT.
WA_FCAT-SELTEXT_L = 'Material Number'.
WA_FCAT-COL_POS = '2'.
WA_FCAT-FIELDNAME = 'MATNR'.
WA_FCAT-TABNAME = 'ITAB'.
WA_FCAT-OUTPUTLEN = '18'.
APPEND WA_FCAT TO FCAT.
CLEAR WA_FCAT.
WA_FCAT-SELTEXT_L = 'Date'.
WA_FCAT-COL_POS = '3'.
WA_FCAT-FIELDNAME = 'ERSDA'.
WA_FCAT-TABNAME = 'ITAB'.
WA_FCAT-OUTPUTLEN = '8'.
APPEND WA_FCAT TO FCAT.
CLEAR WA_FCAT.
ENDFORM. " FIELDCAT
*& Form OUTPUT
text
--> p1 text
<-- p2 text
FORM OUTPUT .
SELECT MATNR ERSDA FROM MARA
INTO TABLE ITAB
WHERE MATNR EQ P_MATNR.
IF SY-SUBRC EQ 0.
PERFORM GRID.
ELSE.
MESSAGE 'No Records Found' TYPE 'I'.
ENDIF.
ENDFORM. " OUTPUT
*& Form GRID
text
--> p1 text
<-- p2 text
FORM GRID .
CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
EXPORTING
I_CALLBACK_PROGRAM = SY-REPID
I_CALLBACK_PF_STATUS_SET = 'PF_STATUS'
I_CALLBACK_USER_COMMAND = 'GET'
IS_LAYOUT = LAYOUT
IT_FIELDCAT = FCAT
I_DEFAULT = 'X'
TABLES
T_OUTTAB = ITAB.
ENDFORM. " GRID
REGARDS,
SAKTHIVEL.VT
Maybe you are looking for
-
Importing video from old camcorder to mac without using a newer camcorder?
I'm trying to import old home videos from a camcorder (from about 1991) that uses cassettes, onto my Mac. I tried searching for this here and I found this: http://discussions.apple.com/thread.jspa?messageID=1943045�. But I actually don't have
-
Facetime No Longer Works After 4.3.4 Update
Has anyone else experienced this issue on their iPhone? After my wife upgraded her iPhone 4 to 4.3.4 her FaceTIme no longer sends a video signal. My iPhone 4 upgraded without a hitch, but hers doesn't send a video signal at all. She cannot see hersel
-
More Never ending custom build problems
One more time / have never seen so many problems with just buying a new computer: Are you our there Harm or others.. Never seen anything like this.. Gigabyte X58-UD5 Motherboard / USB-3 and ESata-3 600 Win-7 Pro 64 bit.. WD eSataV-Raptor 600gb system
-
Hi: I have a newbie question: Do I gain anything by going to an HDV camera, if I only plan to output to standard DVD? Is the extra resolution an advantage, in terms of having 'more information' to work with, even if the final output will be standard
-
Foreign Key Null Pointer Exception
Hi, java.lang.NullPointerException at oracle.jdeveloper.cm.dt.ui.table.FKPanel._initConstraint(FKPanel.java:310) at oracle.jdeveloper.cm.dt.ui.table.FKPanel.init(FKPanel.java:231) at oracle.jdeveloper.offlinedb.panels.OfflineFKPanel.in