Exception Colors in Excel
When I define an exception with any of the Medium conditions (codes 4,5,6), it displays in orange instead of yellow. User wants to see yellow. Same thing happens when I save the view global and define a Web template. How do I correct the color palette? We're running on Citrix.
Thanks,
Geoff
Hi Geoff,
If you are running the web report, then the way to manage the exception colrs is through the stylesheet. Please check which style sheet your web temaplates employ. You can download this from the MIME reporsitory (SE80) and make changes in the notepad. Save and upload it back. You cannot see any changes made until you invalidate the global cache (from SMICM).
Hope this helps...
Similar Messages
-
Exception color can not display at another key figure in BEx query desinger
I have a report requirement, the user want to display the average price on each month ,such as:
Jan. Feb. Mar. Apr. etc.
100 105 104 95 ....
and the user want to compare each other months with Jan's price.
they want to display the exception color when the rise or down rate greater or less than 5%.
Now ,I can only change the output structure such as:
Jan. Feb. Rate2-1 Mar. Rate3-1 etc.
100 105 (105-100)/100=5% 104 (104-100)/100=4% ....
Now I can set Exception on the formula Rate2-1 Rate3-1....
But the Exception color can only display on Rate2-1,Rate3-1...
and Not the Keyfigure Feb. Mar...
I am using the BI 7.0 and the new Query Designer.
Who can help me to solve this question .
Thanks.
Yours Youming.ZhaoHi,
its simply not supported for BEx Analyzer. Exception reporting on another key figure is only possible for Web Reporting.
Check this actual SAP Help Link:
[Restrictions in the BEx Analyzer|http://help.sap.com/saphelp_nw70/helpdata/en/45/5038f28cce08d2e10000000a11466f/content.htm]
Sorry that i dont have a better answer
Cheers -
Bubble Chart: missing exception colors, mousover text etc.
Hi,
I have some problems with a bubble chart. The definition of the query is like this:
project status sfactor rfactor budget
1--1---30-100--
30
2--2---10---15--
30
3--1---234--
45
4--3---50---10-----140
Project and status are characteristics, the other objects are key figures. A project has a status. There are 6 stati. Based on the status the bubble in the bubble chart shall have a specific color. So I set an exception for each status level. I use a BW 3.1 SP19.
Based on this query I create a bubble chart in web. I have now the following problems:
1.The bubble chart shows only 3 different colors (red, yellow, green) and not these colors that are also used in the BEx query. In BW3.5 more colors are displayed. Is there any restriction in 3.1?
2.In case of mouseover (over the bubble of the last project see above) the text "project 4: 140" is displayed. Is it possible to display also the description and value of the status, sfactor and rfactor?
3.I configured the chart options in such a way, that rfactor and sfactor shall be displayed above the bubble. But this works not for all buubles. Any explanation for that?
4.If I restrict the displayed bubbles only to one status level (by means of a dropdownbox), then the displayed bubble is bigger than before. I fixed x- and y-axis. So why do I get now an other size for the selected status level. Any chance to avoid this?
5. The chart legend still shows the original bubble colors, so not the exception colors. Is it possible to force the legend to show the correct colors?
I would be very grateful for any help.
BR, Andreas
Message was edited by: Andreas AppeltHi Andreas
1.) http://help.sap.com/saphelp_nw04/helpdata/en/c4/274b795a809a4da0f3c991284e1cee/frameset.htm
2.) Only with own javascript on not released HTML objects
3) Could be a problem of size (is there enough place to see the text?)
5) No
Heike -
What is the best way to lay out color-coded Excel data in InDesign?
I’ve been away from layout for some time. I now need to lay out color-coded Excel data (3 columns, 200 rows) in InDesign 5.5. The data will need to be in alpha order and each row will be color coded, with a color key at the top of the page. What is the best way to lay this out? Should I use the table tool and create a new style for each color that I need to use?
Thanks for your help.I think this will work in CS3.
Start off by inserting Styles of WEEK, Mon to Friday (as per left)
Set the Week No. to Bullets and Numbering and insert as per screen shot
Do the same for Days Monday through to Sunday
Also set up Monday style NEXT STYLE to be Tuesday
When you get to Sunday - loop the Styles back to WEEK style.
Then as per first screen shot you just have to insert RETURNS all the way down to initiate the style. -
How to change series or line color in excel 2007 using ActiveX
I am trying to change series color using Excel 2007 with ActiveX as below. It seems the color cannot be controlled correctly. For example, if I chosse red color, my curve will be changed to blue. Any ideas?
Also, I googled and found a guy ran into similiar problem using VBA for Excel 2007. See the link below:
http://help.wugnet.com/office/change-series-line-color-excel-2007-vba-ftopict1062646.html
Set ch = Worksheets("Chart").ChartObjects(1)
Set objSeries = ch.Chart.SeriesCollection(1)
objSeries.Format.Line.ForeColor.RGB = RGB(255, 127, 0)
According to the post, it need to be done as follows
objSeries.Border.Color = RGB(255, 127, 0) . But I cannot find the border property/method in ActiveX.
The color seems to be abitrary. and I found the Xubuli,
I looked into your question and confirmed that Border.Color is not located under the Excel.Series library. Instead, you must locate it under _Worksheet.UsedRange as seen below in the figure. I am attaching the VI file where I located the the Border.Color property node, and I am also including a SubVI on the block diagram that goes into explicitly set the cell color and border. This SubVI can be found under Programming>>Report Generation>>Excel Specific>>Excel Format>>Excel Set Cell Color and Border.vi, if you have the Report Generation Toolkit installed. I hope this helps.
Larry H
Applications Engineer
National Instruments
Attachments:
CellBorder.vi 8 KB -
I am using the type pools OLE2 to put colors in the Excel sheet.
What is the property to fill color in the Excel sheet cell.
Also I need to merge cells in the excel sheet.
Can some one send me some sample code if you have?
Please help.Its urgent.hi rowal,
Hi Ashutosh...Use the below code i think it will be helpful
This program demonstrates how to send abap data to excel sheet
using OLE automation
include ole2incl.
*handles for OLE object
data: h_excel type ole2_object, " Excel object
h_mapl type ole2_object, " list of workbooks
h_map type ole2_object, " workbook
h_zl type ole2_object, " cell
h_f type ole2_object. " font
data: h type i.
types: begin of t_bkpf,
bukrs type bkpf-bukrs,
belnr type bkpf-belnr,
gjahr type bkpf-gjahr,
blart type bkpf-blart,
budat type bkpf-budat,
end of t_bkpf.
data: it_bkpf type standard table of t_bkpf,
wa_bkpf type t_bkpf.
********start-of-selection*******************
start-of-selection.
select bukrs
belnr
gjahr
blart
budat into table it_bkpf
from bkpf
up to 10 rows.
call function 'SAPGUI_PROGRESS_INDICATOR'
exporting
PERCENTAGE = 0
text = text-001
exceptions
others = 1.
Start excel
create object h_excel 'EXCEL.APPLICATION'.
perform err_hdl.
set property of h_excel 'Visible' = 1.
perform err_hdl.
call function 'SAPGUI_PROGRESS_INDICATOR'
exporting
PERCENTAGE = 0
text = text-002
exceptions
others = 1.
call method of h_excel 'workbooks' = h_mapl.
perform err_hdl.
Add a new workbook
call method of h_mapl 'Add' = h_map.
perform err_hdl.
call function 'SAPGUI_PROGRESS_INDICATOR'
exporting
PERCENTAGE = 0
text = text-003
exceptions
others = 1.
Output Column Headings to active excel sheet
perform fill_cell using 1 1 1 text-004.
perform fill_cell using 1 2 1 text-005.
perform fill_cell using 1 3 1 text-006.
perform fill_cell using 1 4 1 text-007.
perform fill_cell using 1 5 1 text-008.
Copy internal table to excel sheet
loop at it_bkpf into wa_bkpf.
h = sy-tabix + 1.
perform fill_cell1 using h 1 0 wa_bkpf-bukrs.
perform fill_cell2 using h 2 0 wa_bkpf-belnr.
perform fill_cell1 using h 3 0 wa_bkpf-gjahr.
perform fill_cell1 using h 4 0 wa_bkpf-blart.
perform fill_cell1 using h 5 0 wa_bkpf-budat.
endloop.
disconnect from Excel
free object h_excel.
perform err_hdl.
*& Form err_hdl
text
--> p1 text
<-- p2 text
form err_hdl .
if sy-subrc <> 0.
write: / 'Error in OLE Automation'.
stop.
endif.
endform. " err_hdl
*& Form fill_cell
text
-->P_1 text
-->P_1 text
-->P_1 text
-->P_TEXT_004 text
form fill_cell using i j bold val.
call method of h_excel 'Cells' = h_zl exporting #1 = i #2 = j.
perform err_hdl.
set property of h_zl 'Value' = val .
perform err_hdl.
get property of h_zl 'Font' = h_f.
perform err_hdl.
set property of h_f 'Bold' = bold .
perform err_hdl.
set property of h_f 'colorindex' = 10.
endform. " fill_cell
*& Form fill_cell1
text
-->P_H text
-->P_1 text
-->P_0 text
-->P_WA_BKPF_BUKRS text
form fill_cell1 using i j bold val.
call method of h_excel 'Cells' = h_zl exporting #1 = i #2 = j.
perform err_hdl.
set property of h_zl 'Value' = val .
perform err_hdl.
get property of h_zl 'Font' = h_f.
perform err_hdl.
set property of h_f 'Bold' = bold .
perform err_hdl.
endform. " fill_cell1
*& Form fill_cell2
text
-->P_H text
-->P_2 text
-->P_0 text
-->P_WA_BKPF_BELNR text
form fill_cell2 using i j bold val.
call method of h_excel 'Cells' = h_zl exporting #1 = i #2 = j.
perform err_hdl.
set property of h_zl 'Value' = val .
perform err_hdl.
get property of h_zl 'Font' = h_f.
perform err_hdl.
set property of h_f 'Bold' = bold .
perform err_hdl.
set property of h_f 'colorindex' = 13.
endform. " fill_cell2
hope the code will help you to solve the problem,
reward points if usefull,
Thanks ,
kalyan. -
Hi experts,
We've created a query under BEx Query Designer with Exception and on the <b>Display</b> tab flagged options "<b>Exception affects characteristic cells</b>" and chose "<b>Rows</b>"; and option "<b>Exception Affects Data cells</b>" and "All <b>structure elements</b>".
When we execute the query on Internet Explorer, the result is ok, the characteristic and all the KF's are colored according the definitions, but on Excel it doesn't. Only the KF that is chosen in the "<b>Definition</b>" tab has the colors.
BW is version 7.0 with SP 13 and on Front-End/BEx SP 13.
Does anybody has a solution?
Thanks in advance,
MarcioHi Marcio,
This is documented as a restriction for BEx Analyzer. See here:
http://help.sap.com/saphelp_nw70/helpdata/en/45/5038f28cce08d2e10000000a11466f/content.htm
Hope this helps... -
Hi!
i want to color(yellow) the last line of an excel.
here is a part of the code :
DESCRIBE TABLE excel_2 LINES w_lines.
CREATE OBJECT application 'excel.application'.
SET PROPERTY OF application 'visible' = 1.
CALL METHOD OF application 'Workbooks' = workbook.
CALL METHOD OF workbook 'Open'
EXPORTING
#1 = pa_file.
CALL METHOD OF application 'Worksheets' = sheet
EXPORTING
#1 = 1.
SET PROPERTY OF sheet 'Name' = 'Employee Performance'.
CALL METHOD OF sheet 'Activate'.
DATA: w_test TYPE string.
DATA: w_test_lines TYPE string.
w_test_lines = w_lines.
CONCATENATE 'A' w_test_lines INTO w_test.
CONCATENATE w_test ':Z' w_test_lines INTO w_test.
CONDENSE w_test NO-GAPS.
*CALL METHOD OF application 'RANGE' = gs_range
* EXPORTING
* #1 = 'w_test'.
* SET PROPERTY OF gs_range 'HORIZONTALALIGNMENT' = 1.
* CALL METHOD OF gs_range 'FONT' = gs_font.
* SET PROPERTY OF gs_font 'BOLD' = 1.
CALL METHOD OF application 'RANGE' = gs_range
EXPORTING
#1 = 'A1:Z1'.
SET PROPERTY OF gs_range 'HORIZONTALALIGNMENT' = 1.
CALL METHOD OF gs_range 'FONT' = gs_font.
SET PROPERTY OF gs_font 'BOLD' = 1.
CALL METHOD OF application 'Columns' = h_columns
EXPORTING
#1 = 'A:Z'.
GET PROPERTY OF h_columns 'EntireColumn' = h_entirecol.
SET PROPERTY OF h_entirecol 'Autofit' = 1.
CALL METHOD OF sheet 'SAVE' "'Save'
EXPORTING
#1 = pa_file
#2 = pa_file."filename
"fileFormatCheck out this code
handles for OLE objects
DATA: H_EXCEL TYPE OLE2_OBJECT, " Excel object
H_MAPL TYPE OLE2_OBJECT, " list of workbooks
H_MAP TYPE OLE2_OBJECT, " workbook
H_ZL TYPE OLE2_OBJECT, " cell
H_F TYPE OLE2_OBJECT. " font
TABLES: SPFLI.
DATA H TYPE I.
table of flights
DATA: IT_SPFLI LIKE SPFLI OCCURS 10 WITH HEADER LINE.
*& Event START-OF-SELECTION
START-OF-SELECTION.
read flights
SELECT * FROM SPFLI INTO TABLE IT_SPFLI UP TO 10 ROWS.
display header
ULINE (61).
WRITE: / SY-VLINE NO-GAP,
(3) 'Flg'(001) COLOR COL_HEADING NO-GAP, SY-VLINE NO-GAP,
(4) 'Nr'(002) COLOR COL_HEADING NO-GAP, SY-VLINE NO-GAP,
(20) 'Von'(003) COLOR COL_HEADING NO-GAP, SY-VLINE NO-GAP,
(20) 'Nach'(004) COLOR COL_HEADING NO-GAP, SY-VLINE NO-GAP,
(8) 'Zeit'(005) COLOR COL_HEADING NO-GAP, SY-VLINE NO-GAP.
ULINE /(61).
display flights
LOOP AT IT_SPFLI.
WRITE: / SY-VLINE NO-GAP,
IT_SPFLI-CARRID COLOR COL_KEY NO-GAP, SY-VLINE NO-GAP,
IT_SPFLI-CONNID COLOR COL_NORMAL NO-GAP, SY-VLINE NO-GAP,
IT_SPFLI-CITYFROM COLOR COL_NORMAL NO-GAP, SY-VLINE NO-GAP,
IT_SPFLI-CITYTO COLOR COL_NORMAL NO-GAP, SY-VLINE NO-GAP,
IT_SPFLI-DEPTIME COLOR COL_NORMAL NO-GAP, SY-VLINE NO-GAP.
ENDLOOP.
ULINE /(61).
tell user what is going on
CALL FUNCTION 'SAPGUI_PROGRESS_INDICATOR'
EXPORTING
PERCENTAGE = 0
TEXT = TEXT-007
EXCEPTIONS
OTHERS = 1.
start Excel
CREATE OBJECT H_EXCEL 'EXCEL.APPLICATION'.
PERFORM ERR_HDL.
SET PROPERTY OF H_EXCEL 'Visible' = 1.
CALL METHOD OF H_EXCEL 'FILESAVEAS' EXPORTING #1 = 'c:\kis_excel.xls'
PERFORM ERR_HDL.
tell user what is going on
CALL FUNCTION 'SAPGUI_PROGRESS_INDICATOR'
EXPORTING
PERCENTAGE = 0
TEXT = TEXT-008
EXCEPTIONS
OTHERS = 1.
get list of workbooks, initially empty
CALL METHOD OF H_EXCEL 'Workbooks' = H_MAPL.
PERFORM ERR_HDL.
add a new workbook
CALL METHOD OF H_MAPL 'Add' = H_MAP.
PERFORM ERR_HDL.
tell user what is going on
CALL FUNCTION 'SAPGUI_PROGRESS_INDICATOR'
EXPORTING
PERCENTAGE = 0
TEXT = TEXT-009
EXCEPTIONS
OTHERS = 1.
output column headings to active Excel sheet
PERFORM FILL_CELL USING 1 1 1 'Flug'(001).
PERFORM FILL_CELL USING 1 2 0 'Nr'(002).
PERFORM FILL_CELL USING 1 3 1 'Von'(003).
PERFORM FILL_CELL USING 1 4 1 'Nach'(004).
PERFORM FILL_CELL USING 1 5 1 'Zeit'(005).
LOOP AT IT_SPFLI.
copy flights to active EXCEL sheet
H = SY-TABIX + 1.
PERFORM FILL_CELL USING H 1 0 IT_SPFLI-CARRID.
PERFORM FILL_CELL USING H 2 0 IT_SPFLI-CONNID.
PERFORM FILL_CELL USING H 3 0 IT_SPFLI-CITYFROM.
PERFORM FILL_CELL USING H 4 0 IT_SPFLI-CITYTO.
PERFORM FILL_CELL USING H 5 0 IT_SPFLI-DEPTIME.
ENDLOOP.
changes by Kishore - start
CALL METHOD OF H_EXCEL 'Workbooks' = H_MAPL.
CALL METHOD OF H_EXCEL 'Worksheets' = H_MAPL." EXPORTING #1 = 2.
PERFORM ERR_HDL.
add a new workbook
CALL METHOD OF H_MAPL 'Add' = H_MAP EXPORTING #1 = 2.
PERFORM ERR_HDL.
tell user what is going on
SET PROPERTY OF H_MAP 'NAME' = 'COPY'.
CALL FUNCTION 'SAPGUI_PROGRESS_INDICATOR'
EXPORTING
PERCENTAGE = 0
TEXT = TEXT-009
EXCEPTIONS
OTHERS = 1.
output column headings to active Excel sheet
PERFORM FILL_CELL USING 1 1 1 'Flug'(001).
PERFORM FILL_CELL USING 1 2 0 'Nr'(002).
PERFORM FILL_CELL USING 1 3 1 'Von'(003).
PERFORM FILL_CELL USING 1 4 1 'Nach'(004).
PERFORM FILL_CELL USING 1 5 1 'Zeit'(005).
LOOP AT IT_SPFLI.
copy flights to active EXCEL sheet
H = SY-TABIX + 1.
PERFORM FILL_CELL USING H 1 0 IT_SPFLI-CARRID.
PERFORM FILL_CELL USING H 2 0 IT_SPFLI-CONNID.
PERFORM FILL_CELL USING H 3 0 IT_SPFLI-CITYFROM.
PERFORM FILL_CELL USING H 4 0 IT_SPFLI-CITYTO.
PERFORM FILL_CELL USING H 5 0 IT_SPFLI-DEPTIME.
ENDLOOP.
changes by Kishore - end
disconnect from Excel
CALL METHOD OF H_EXCEL 'FILESAVEAS' EXPORTING #1 = 'C:\SKV.XLS'.
FREE OBJECT H_EXCEL.
PERFORM ERR_HDL.
FORM FILL_CELL *
sets cell at coordinates i,j to value val boldtype bold *
FORM FILL_CELL USING I J BOLD VAL.
CALL METHOD OF H_EXCEL 'Cells' = H_ZL EXPORTING #1 = I #2 = J.
PERFORM ERR_HDL.
SET PROPERTY OF H_ZL 'Value' = VAL .
PERFORM ERR_HDL.
GET PROPERTY OF H_ZL 'Font' = H_F.
PERFORM ERR_HDL.
SET PROPERTY OF H_F 'Bold' = BOLD .
PERFORM ERR_HDL.
ENDFORM.
*& Form ERR_HDL
outputs OLE error if any *
--> p1 text
<-- p2 text
FORM ERR_HDL.
IF SY-SUBRC <> 0.
WRITE: / 'Fehler bei OLE-Automation:'(010), SY-SUBRC.
STOP.
ENDIF.
ENDFORM. " ERR_HDL -
Exception color with formula variable(replacement path)
Hello,
I tried to define exceptions in a query which "from" and "to" values
are determined by formula variables with replacement path. I checked
the values of the formula variables and they are right. <b>But <b>the cells
are not colored</b></b>. When I set the same values in the field "from" and "to" without variables : the colors appear.
Could help me to resolve this problem please ?
Catherine BellecHi Alec,
You are right, the user exit permits to color the lines.
But the value of my variable needs to change for each line of the infocube so I can't do this with the user exit RSR00001 because it concerns global variables.
That's why I used a replacement path on a virtual characteristic. -
Alternating text color of excel cell items after each space?
Hello. I have a script that emails a table of info which works fine and that looks like this:
name, samaccountname, date, memberof
In the email table I was able to have it do a line break on each space so that the memberof groups are on on separate lines for easier reading.
Well I've been wanting to send the data to store in a csv sheet as well. I can get it going in there but for the member of column it puts in memberof1 memberof2 memberof3 etc etc on one line. The CNs OUs etc are all removed and its just the group
names separated by spaces. Works but a little hard to read.
I was thinking maybe there was a way to open the excel file for writing and on that one column have it alternate text colors using the space as the delimiter? Everything would be easier to read that way. Is this possible ?
ThanksThanks. I did look at that and have this so far. Im just trying to echo it out right now, but Im guessing that somehow in the foreach ($item in $groups) I need to create an array or something? Then Id want to apply one color to each item in the array.
Ive tried several different combinations and was trying $item.spli(" ") but it always comes back looking the same.
So right now $item echos like this
Group1 Group2 Group3 Group4 Group5
Id just want to alternate each space delimited item one of two colors. Then take those appened colors of each item and write it back to the cell that I read it from in the column so that its easier to read. Is this even possible?
$objExcel = new-object -comobject excel.application
$objExcel.Visible = $True
$ExcelFilesLocation = "c:\"
$UserWorkBook = $objExcel.Workbooks.Open($ExcelFilesLocation + "groups.csv")
$UserWorksheet = $UserWorkBook.Worksheets.Item(1)
$intRow = 2
Do {
# Reading the first column of the current row
$groups = $UserWorksheet.Cells.Item($intRow, 4).Value()
foreach ($item in $groups)
$regex = [regex] "\s"
$split = $regex.split($item)
Write-Host $split
# Move to next row
$intRow++
While ($UserWorksheet.Cells.Item($intRow,1).Value() -ne $null) -
After changing LookAndFeel: Exception: Colors cannot be null
Hi All!
I've just created a frame and an internal frame. But after I close the internal frame and change the look and feel (for example from windows to windows classic) and reuse of the internal frame I've get the following exception:
Exception in thread "AWT-EventQue-0" java.lang.NullPointerException: Colors cannot be null.
Here's my codes:
package myprojects.probe_1;
import javax.swing.SwingUtilities;
public class Probe_1
private static JProbeMainFrame frmMain;
public static void main( String[] args )
javax.swing.SwingUtilities.invokeLater(
new Runnable()
public void run()
frmMain = new JProbeMainFrame();
frmMain.setVisible( true );
package myprojects.probe_1;
import java.awt.*;
import java.awt.event.*;
import javax.swing.JFrame;
import javax.swing.JMenuBar;
import javax.swing.JMenu;
import javax.swing.JMenuItem;
import javax.swing.JRadioButtonMenuItem;
import javax.swing.ButtonGroup;
import javax.swing.KeyStroke;
import javax.swing.JInternalFrame;
import javax.swing.JDesktopPane;
import javax.swing.UIManager;
import javax.swing.SwingUtilities;
public class JProbeMainFrame extends JFrame
private JDesktopPane dskDesktop;
private JCountriesEditor frmCountriesEditor;
public JProbeMainFrame()
super( "JProbeMainFrame" );
int inset = 50;
Dimension screenSize = Toolkit.getDefaultToolkit().getScreenSize();
setBounds( inset, inset, screenSize.width - inset * 2, screenSize.height - inset * 2 );
dskDesktop = new JDesktopPane();
setContentPane( dskDesktop );
setJMenuBar( createMainMenuBar() );
this.addWindowListener(
new WindowAdapter()
public void windowClosing( WindowEvent evt )
JProbeMainFrame.this.closeWindow();
setLookAndFeelTo( UIManager.getSystemLookAndFeelClassName() );
// Main menu.
protected JMenu createFileMenu()
JMenu mnuMenu;
JMenuItem mniMenuItem;
mnuMenu = new JMenu( "File" );
mnuMenu.setMnemonic( KeyEvent.VK_F );
mnuMenu.getAccessibleContext().setAccessibleDescription( "Standard file menu." );
// Items.
mniMenuItem = new JMenuItem( "Exit", KeyEvent.VK_X );
mniMenuItem.setAccelerator(
KeyStroke.getKeyStroke( KeyEvent.VK_X, ActionEvent.ALT_MASK ) );
mniMenuItem.getAccessibleContext().setAccessibleDescription(
"Terminates the application." );
mniMenuItem.addActionListener(
new ActionListener()
public void actionPerformed( ActionEvent evt )
JProbeMainFrame.this.closeWindow();
mnuMenu.add( mniMenuItem );
return mnuMenu;
protected JMenu createSettingsMenu()
JMenu mnuMenu;
JMenu smnSubMenu;
JMenuItem mniMenuItem;
ButtonGroup rbgRadioButtonGroup;
JRadioButtonMenuItem rmiRadioMenuItem;
mnuMenu = new JMenu( "Settings" );
mnuMenu.setMnemonic( KeyEvent.VK_S );
mnuMenu.getAccessibleContext().setAccessibleDescription( "Set up how to work the application." );
// Items.
mniMenuItem = new JMenuItem( "Countries", KeyEvent.VK_C );
mniMenuItem.setAccelerator(
KeyStroke.getKeyStroke( KeyEvent.VK_C, ActionEvent.ALT_MASK ) );
mniMenuItem.getAccessibleContext().setAccessibleDescription(
"Maintenance the available countries." );
mniMenuItem.addActionListener(
new ActionListener()
public void actionPerformed( ActionEvent evt )
if ( frmCountriesEditor != null && frmCountriesEditor.isClosed() )
// Resue of the internal frame!!!
dskDesktop.add( frmCountriesEditor );
frmCountriesEditor.setVisible( true );
else if ( frmCountriesEditor == null )
frmCountriesEditor = new JCountriesEditor();
dskDesktop.add( frmCountriesEditor );
frmCountriesEditor.setVisible( true );
if ( frmCountriesEditor.isIcon() )
try
frmCountriesEditor.setIcon( false );
catch ( Exception exc ) { }
try
frmCountriesEditor.setSelected( true );
catch ( Exception exc ) { }
mnuMenu.add( mniMenuItem );
mnuMenu.addSeparator();
smnSubMenu = new JMenu( "Look and Feel" );
smnSubMenu.setMnemonic( KeyEvent.VK_S );
smnSubMenu.getAccessibleContext().setAccessibleDescription( "Set the Look and Feel to desired one." );
rbgRadioButtonGroup = new ButtonGroup();
UIManager.LookAndFeelInfo[] lafiLookAndFeelInfo = UIManager.getInstalledLookAndFeels();
String strLookAndFeelName;
ActionListener alActionListener = new alLookAndFeelActionListener();
for ( int idxIndex = 0; idxIndex < lafiLookAndFeelInfo.length; idxIndex++ )
strLookAndFeelName = lafiLookAndFeelInfo[ idxIndex ].getName();
rmiRadioMenuItem = new JRadioButtonMenuItem( strLookAndFeelName );
if (UIManager.getSystemLookAndFeelClassName() == lafiLookAndFeelInfo[ idxIndex ].getClassName() )
rmiRadioMenuItem.setSelected( true );
rmiRadioMenuItem.getAccessibleContext().setAccessibleDescription(
"Set the look and feel like " + strLookAndFeelName + "." );
rmiRadioMenuItem.setActionCommand( lafiLookAndFeelInfo[ idxIndex ].getClassName() );
rmiRadioMenuItem.addActionListener( alActionListener );
rbgRadioButtonGroup.add( rmiRadioMenuItem );
smnSubMenu.add( rmiRadioMenuItem );
mnuMenu.add( smnSubMenu );
return mnuMenu;
protected JMenuBar createMainMenuBar()
JMenuBar mbrMainMenuBar = new JMenuBar(); // Create menu bar.
mbrMainMenuBar.add( createFileMenu() );
mbrMainMenuBar.add( createSettingsMenu() );
return mbrMainMenuBar;
private class alLookAndFeelActionListener implements ActionListener
public void actionPerformed( ActionEvent evt )
setLookAndFeelTo( evt.getActionCommand() );
protected void setLookAndFeelTo( String strLookAndFeel )
try
UIManager.setLookAndFeel( strLookAndFeel );
SwingUtilities.updateComponentTreeUI( this );
catch ( Exception exc ) { }
protected void closeWindow()
System.exit( 0 );
package myprojects.probe_1;
import java.awt.event.*;
import java.awt.*;
import javax.swing.JInternalFrame;
public class JCountriesEditor extends JInternalFrame
public JCountriesEditor()
super( "JCountriesEditor", true, true, false, true );
setSize( 200, 400 );
setLocation( 100, 100 );
}What should I take to avoid the exception or this is a bug in the JSE 1.6.0-beta2-x86 library. Before I forget, running on WinXP SP2 Hun.
Thanks!
Best Regards:
GeorgeeFor a short bit of informatin: I also tried setting up the Calendar's configured Incoming E-Mail Address in AD as a contact - no difference.
-
Re:colors in Excel sheet (first row should be completely filled with yellow
I am using the type pools OLE2 to put colors in the Excel sheet.
What is the property to fill color in the Excel sheet cell.
i got the text in colors but not the background...
for example:
i need the first row ie..the heading to be in yellow.
Can some one send me some sample code .plz its urgent..........Hi,
Check to see the following code:
Sub Find_match()
Dim Range1 As Range
Dim Range2 As Range
Set Range1 = Application.InputBox("Select the range on the first sheet to Compare", Type:=8)
Set Range2 = Application.InputBox("Select the range on the second sheet to Compare", Type:=8)
Dim range_row1 As Integer
Dim range_row2 As Integer
Dim loop_row1 As Integer
Dim loop_row2 As Integer
Dim find_value As String
range_row1 = Range1.Rows.Count
range_row2 = Range2.Rows.Count
For loop_row1 = 1 To range_row1
find_value = Range1.Cells(loop_row1, 1)
For loop_row2 = 1 To range_row2
If Range2.Cells(loop_row2, 1) = find_value Then
If Range1.Cells(loop_row1, 2) = Range2.Cells(loop_row2, 2) Then
Range1.Rows(loop_row1).Interior.Color = vbYellow
End If
End If
Next
Next
End Sub
When the macro run, it will prompt to select the range in both sheet, the range is where the cells contain the data, it contains two columns.
Jaynet Zhang
TechNet Community Support
Jaynet,
Thank you so much. This is exactly how I wanted it to work. The only thing I wanted to know which I will try and figure out while I await your answer is if I can make this work between workbooks instead of worksheets? Currently, it does not allow me to switch
workbooks when running the macro to select the second range. Thank you. -
Hi all!
I'm trying to fill the header of a table from SAP to Excel. Does anyone now
the correct steps of set get and properties needed to do this?
Thanks!Hi Ashutosh...Use the below code i think it will be helpful
This program demonstrates how to send abap data to excel sheet
using OLE automation
include ole2incl.
*handles for OLE object
data: h_excel type ole2_object, " Excel object
h_mapl type ole2_object, " list of workbooks
h_map type ole2_object, " workbook
h_zl type ole2_object, " cell
h_f type ole2_object. " font
data: h type i.
types: begin of t_bkpf,
bukrs type bkpf-bukrs,
belnr type bkpf-belnr,
gjahr type bkpf-gjahr,
blart type bkpf-blart,
budat type bkpf-budat,
end of t_bkpf.
data: it_bkpf type standard table of t_bkpf,
wa_bkpf type t_bkpf.
********start-of-selection*******************
start-of-selection.
select bukrs
belnr
gjahr
blart
budat into table it_bkpf
from bkpf
up to 10 rows.
call function 'SAPGUI_PROGRESS_INDICATOR'
exporting
PERCENTAGE = 0
text = text-001
exceptions
others = 1.
Start excel
create object h_excel 'EXCEL.APPLICATION'.
perform err_hdl.
set property of h_excel 'Visible' = 1.
perform err_hdl.
call function 'SAPGUI_PROGRESS_INDICATOR'
exporting
PERCENTAGE = 0
text = text-002
exceptions
others = 1.
call method of h_excel 'workbooks' = h_mapl.
perform err_hdl.
Add a new workbook
call method of h_mapl 'Add' = h_map.
perform err_hdl.
call function 'SAPGUI_PROGRESS_INDICATOR'
exporting
PERCENTAGE = 0
text = text-003
exceptions
others = 1.
Output Column Headings to active excel sheet
perform fill_cell using 1 1 1 text-004.
perform fill_cell using 1 2 1 text-005.
perform fill_cell using 1 3 1 text-006.
perform fill_cell using 1 4 1 text-007.
perform fill_cell using 1 5 1 text-008.
Copy internal table to excel sheet
loop at it_bkpf into wa_bkpf.
h = sy-tabix + 1.
perform fill_cell1 using h 1 0 wa_bkpf-bukrs.
perform fill_cell2 using h 2 0 wa_bkpf-belnr.
perform fill_cell1 using h 3 0 wa_bkpf-gjahr.
perform fill_cell1 using h 4 0 wa_bkpf-blart.
perform fill_cell1 using h 5 0 wa_bkpf-budat.
endloop.
disconnect from Excel
free object h_excel.
perform err_hdl.
*& Form err_hdl
text
--> p1 text
<-- p2 text
form err_hdl .
if sy-subrc <> 0.
write: / 'Error in OLE Automation'.
stop.
endif.
endform. " err_hdl
*& Form fill_cell
text
-->P_1 text
-->P_1 text
-->P_1 text
-->P_TEXT_004 text
form fill_cell using i j bold val.
call method of h_excel 'Cells' = h_zl exporting #1 = i #2 = j.
perform err_hdl.
set property of h_zl 'Value' = val .
perform err_hdl.
get property of h_zl 'Font' = h_f.
perform err_hdl.
set property of h_f 'Bold' = bold .
perform err_hdl.
set property of h_f 'colorindex' = 10.
endform. " fill_cell
*& Form fill_cell1
text
-->P_H text
-->P_1 text
-->P_0 text
-->P_WA_BKPF_BUKRS text
form fill_cell1 using i j bold val.
call method of h_excel 'Cells' = h_zl exporting #1 = i #2 = j.
perform err_hdl.
set property of h_zl 'Value' = val .
perform err_hdl.
get property of h_zl 'Font' = h_f.
perform err_hdl.
set property of h_f 'Bold' = bold .
perform err_hdl.
endform. " fill_cell1
*& Form fill_cell2
text
-->P_H text
-->P_2 text
-->P_0 text
-->P_WA_BKPF_BELNR text
form fill_cell2 using i j bold val.
call method of h_excel 'Cells' = h_zl exporting #1 = i #2 = j.
perform err_hdl.
set property of h_zl 'Value' = val .
perform err_hdl.
get property of h_zl 'Font' = h_f.
perform err_hdl.
set property of h_f 'Bold' = bold .
perform err_hdl.
set property of h_f 'colorindex' = 13.
endform. " fill_cell2 -
Adobe Captivate 5- Color Issues (excel 2007)
Please help me!
I am using Adobe Captivate 5 and am recording 2007 excel. When I have completed the movements, the images and background appear to be fine.
As soon as I preview or publish the colours of the cells and objects (e.g. highlight box) get mixed up:
Either the colors start moving into different areas, or dissapear or randomly move as the screen moves (This image was taken when the screen wasn't moving). Is this a software bug? Anyone had the same issue? Any way to resolve this?
I appreciate the help!Hello,
Could you check the video quality of the slides? You find this in the Properties panel of the slide, region General. Perhaps it is set to 'Low, 8-bit. Try to change to one of the other settings. On the Captivate blog you'll find a great explanation about this Video Quality. Have a look at:
http://blogs.adobe.com/captivate/?s=Slide+Quality
Lilybiri
PS: see this is your first post, so 'Welcome on the forum!' -
Can't print color in Excel Spread sheets on a HP 2605dn
We are using a PCL 6 driver. Other types of files print color ok. No Excel files will print color on the HP 2605dn printers. The same files will print on other model printers. We have changed all of the various color settings in the printer Properties. Window XP SP2. MS Office XP. Any ideas will be appreciated.
Hi,
Based on its manual (document c03026243.pdf, pp 164, 165 & 166) you can't use tray 2 to print envelopes, you can ONLY use tray #1.
Hope this answers your question.
BH
**Click the KUDOS thumb up on the left to say 'Thanks'**
Make it easier for other people to find solutions by marking a Reply 'Accept as Solution' if it solves your problem.
Maybe you are looking for
-
I have a MS-6340 with an AMD 1000 Megahertz processor. I currently have 256 mb of Crucial 133 memory installed. I bought another upgrade of 256 MB of Crucial 133 memory and when I install it it is recognized when the computer boots up. When I start
-
Hi , My requirement is to call WD java in portal from WD ABAP . I Searched and found it is possible by using PCD Path but i am not able to do . I tried it and now called application is opening up but full portal opens up in a separate browser , i wan
-
Help trying to locate local server applications directory in configuration manager
I am going through the configuration of lifecycle and I have no idea where the locaql server applications directory is. Can anyone provide some hints.
-
How do I get flash player download to finish??
Windows 7 64bit starts installation, never leaves step 2 of 3. I have tried online and hard drive installation, same results.
-
Link to ping iTunes now redirects to the iTunes store
iTunes provided a link when it accepted my podcast feed in order to ping it when I've added a new episode. I've been using it for the last 35 episodes with little trouble, usually a few hours to a day after I ping it my episode will show up in iTunes