Formula to Calculate Cell Above in the Same Column?
How do you write a formula that looks if two cells (with dates) are identical in the same column; and if they are not identical, subtract 1 day from the date in the above cell to determine the date for the cell below it.
=IF($A1=$A2,B1-1,B2+28)
How do you write a formula that looks if two cells (with dates) are identical in the same column; and if they are not identical, subtract 1 day from the date in the above cell to determine the date for the cell below it.
=IF($A1=$A2,B1-1,B2+28)
Similar Messages
-
I am having trouble getting a numbers spreadsheet to hold different formats in the same column. A column with a date formatted heading will not convert to $ for the cells below. Any suggestions would help.
Hi Wayne,
Thank you for this response. I have tried this but when I start enterring $ amounts some, such as $6.00, go in OK others such as $4.00 appear as a date ie 4 Oct 12.
Kind regards
Paul -
I meet a lot of 3G signal when a call signal disappears 3G! I read the manuals and anything I find the problem! I do so with other brands and other cell does not, the same goes when I receive a call!
Who is your carrier? Are you actually on 3G?
Do you have 3G turned on or off? Settings > General > Network > Enable 3G -
ALV List in the same Column for the row CELL i need button or value
Hi,
In my ALV list for the same column I need Button or Value for the different rows (CELL) depending upon my condition.
as well as I have to make read only of 3 rd column CELL based on my first column dropdown value CELL for this Row Only.
Depends upon the value in column 1 / row 2 I have to read only the CELL of column 5 / row 2 ie for the same row.
Depends upon the value in Column 1/ row 3 I have to EDITABLE or Button the CELL of column 5 / row 3 ie for the same row
How to do the logic for this.
I tried and got it for the entire column only.
But my requirement is for the sepecific cell in the column.
Kindly help to proceed further.
Thanks in advance.
DavHere is how you can make a particular cell in the row read-only based on certain conditions.
In my example I am displaying the flight details in an ALV. Here I am checking the airline id and if it is "AA' I am making the cell in the column airline id as readonly. In my example I am putting a check and readonly on the same column. However you can do this for different columns as well.
In order to achieve this you need to add a new context attribute 'READONLY' of type abap_bool to the context node which is bound to data node of ALV.
The method where I populate the node has the following code to populate the data.
data: lr_input_node type ref to if_wd_context_node,
lr_flight_node type ref to if_wd_context_node,
lv_cityfrom type s_from_cit,
lv_cityto type s_to_city,
ls_from type bapisfldst,
ls_to type bapisfldst,
lt_flights type table of bapisfldat,
ls_flights type bapisfldat.
data: lt_final type if_mainview=>elements_node_flighttab,
ls_final type if_mainview=>element_node_flighttab.
* Instantiate the variable lr_input_note to the node NODE_FLIGHT
lr_input_node = wd_context->get_child_node( name = 'NODE_FLIGHT' ).
* Instantiate the variable lr_flight_note to the node NODE_FLIGHTTAB
lr_flight_node = wd_context->get_child_node( name = 'NODE_FLIGHTTAB' )
* Get the attributes CityFrom und CityTo
lr_input_node->get_attribute( exporting name = 'CITYFROM'
importing value = lv_cityfrom ).
lr_input_node->get_attribute( exporting name = 'CITYTO'
importing value = lv_cityto ).
* Fill the stuctures ls_from and ls_to
ls_from-city = lv_cityfrom.
ls_to-city = lv_cityto.
* Call the function BAPI_FLIGHT_GETLIST
call function 'BAPI_FLIGHT_GETLIST'
exporting
destination_from = ls_from
destination_to = ls_to
tables
flight_list = lt_flights.
Now I am going to check if the airline id is 'AA' and based on that I will fill the readonly context attribute.
loop at lt_flights into ls_flights.
MOVE-CORRESPONDING ls_flights to ls_final.
if ls_flights-airlineid = 'AA'.
ls_final-readonly = abap_true.
else.
ls_final-readonly = abap_false.
endif.
append ls_final to lt_final.
endloop.
Finally bind the data to the context node.
* Bind the data to the node NODE_FLIGHTTAB
lr_flight_node->bind_elements( lt_final ).
Now you need to do the ALV configuration settings.
* create an instance of ALV component
DATA:
lr_salv_wd_table_usage TYPE REF TO if_wd_component_usage.
lr_salv_wd_table_usage = wd_this->wd_cpuse_alv( ).
IF lr_salv_wd_table_usage->has_active_component( ) IS INITIAL.
lr_salv_wd_table_usage->create_component( ).
ENDIF.
* get ALV component
DATA:
lr_salv_wd_table TYPE REF TO iwci_salv_wd_table.
lr_salv_wd_table = wd_this->wd_cpifc_alv( ).
wd_this->alv_config_table = lr_salv_wd_table->get_model( ).
CALL METHOD wd_this->alv_config_table->if_salv_wd_table_settings~set_read_only
EXPORTING
VALUE = ABAP_FALSE
* set visible row count
DATA:
lr_table_settings TYPE REF TO if_salv_wd_table_settings.
lr_table_settings ?= wd_this->alv_config_table.
lr_table_settings->set_visible_row_count( '10' ).
DATA:
lr_column_settings TYPE REF TO if_salv_wd_column_settings,
lr_column TYPE REF TO cl_salv_wd_column.
lr_column_settings ?= wd_this->alv_config_table.
DATA: lr_input_field TYPE REF TO cl_salv_wd_uie_input_field.
lr_column = lr_column_settings->get_column( 'AIRLINEID' ).
CREATE OBJECT lr_input_field EXPORTING value_fieldname = 'AIRLINEID'.
lr_column->set_cell_editor( lr_input_field ).
lr_input_field->set_read_only_fieldname( value = 'READONLY' ).
CALL METHOD lr_column_settings->delete_column
EXPORTING
id = 'READONLY' -
Datagrid scrolling problem when different items are in the same column
I have a datagrid which I am populating with different items (LinkButtons, Images, Labels). However when there are different types of items in the same column and when i try to scroll everything gets messed up (Images get overlapped with each other or the labels get overlapped with images).
I am overloading the "IDropInListItemRenderer" to create different types of items in each cell and I am overloding the "updateDisplayList" function
Any ideas as to why the items get messed up during scrolling? Is there some other preperty of IDropInListItemRenderer that should be overloaded?Hi Subeesh Arakkan,
Thanks. This is the exact problem that I have. Althought my overloaded functions are a little different and Im trying to resolve it. But htis is a good lead.
Thanks,
Prashanth -
How to display 2 lines in the same column header of jTable?
Please could you help me to display 2 character lines in the same column header of a JTable?
And how to make a fusion between to cells?
Thank you very muchIn Swing, most components will accept text in the html format
http://java.sun.com/docs/books/tutorial/uiswing/components/html.html
You can then use <br> tags to make your header text multiline -
Showing navigation attributes in the same column of a query
Hi,
I would like to know if there is a way to define a query such that TWO navigation attributes that reference the same underlying characteristic can be displayed in the SAME column rather than TWO separate columns.
I will describe an example scenario to clarify the requirement. We are using a BI Content InfoCube (0COOM_C02) that has the navigation attributes 0COSTCENTER__0PROFIT_CTR and 0WBS_ELEMT__PROFIT_CTR activated. Both of these attributes reference the characteristic 0PROFIT_CTR. The InfoCube contains transaction data for Cost Centres and WBS Elements.
The requirement is to define a query that summarizes the data by profit centre. At the moment, in order to combine Cost Centre and WBS (Project) data in the same query by Profit Centre, both navigation attributes need to be selected, resulting in the following output:
0COSTCENTER__0PROFIT_CTR......0WBS_ELEMT__PROFIT_CTR......AMOUNT
PC01...............................................Not assigned...................................10,000
PC02...............................................Not assigned...................................20,000
PC03...............................................Not assigned...................................12,000
PC04...............................................Not assigned....................................2,000
Not Assigned....................................PC02..............................................5,000
Not Assigned....................................PC03..............................................8,000
Not Assigned....................................PC05..............................................30,000
Not Assigned....................................PC06..............................................50,000
However, the desired result is to display only one profit centre column using the two profit centre navigation attributes as shown below:
PROFIT CENTRE......AMOUNT
PC01..........................10,000
PC02..........................25,000
PC03..........................20,000
PC04............................2,000
PC05..........................30,000
PC06..........................50,000
Is there a way to achieve the above result using the two navigation attributes only, without having to add 0PROFIT_CTR as a characteristic to the InfoCube?
Any suggestions would be appreciated.
Thanks,
Mustafa.Hi Mustafa,
You have to use enhancement RSR00001 in the transaction CMOD to start developing your code.
For more information how the customer exit variables are processed, refer to the documentation:
http://help.sap.com/saphelp_nw70/helpdata/EN/f1/0a56f5e09411d2acb90000e829fbfe/frameset.htm
A short example can be found here:
http://help.sap.com/saphelp_nw70/helpdata/EN/1d/ca10d858c2e949ba4a152c44f8128a/frameset.htm
This should help.
Regards,
Daniel -
REPORT WITH CHANGING ITEM ON THE SAME COLUMN
Hi to all,
i'm trying to build a report with different item in the same column.
Is that possible in any way using other Oracle technique?
i'm not doing anything specific here, only i would like to know if the following possibility exist or not and how can i let apex render the htmldb_item fields 'dynamically'.
Using this CODE inside a PL/SQL function body returning sql query I obtain the following report content. Such the code of htmldb_item.fields is written, as a field value the HTML_ITEM is not rendered, so only the description of them appear in the report.
Does somebody know some tricks to make it work?
Thanx a lot
1 2 LAST_CALL htmldb_item.date_popup (4, ROWNUM, FLD_VALUE,'dd/mon/yyyy') VALUE
21 1 AGE htmldb_item.text(4,FLD_VALUE,10,10) VALUE
create or replace FUNCTION FNC_GEN_GUI_ITEM(ITEM_TYPE NUMBER) RETURN VARCHAR2 AS
STRHTMLDITEM VARCHAR2(4000);
BEGIN
CASE ITEM_TYPE
WHEN 1 THEN STRHTMLDITEM:=' htmldb_item.text(4,FLD_VALUE,10,10) VALUE ';
WHEN 2 THEN STRHTMLDITEM:=' htmldb_item.date_popup (4, ROWNUM, FLD_VALUE,''dd/mon/yyyy'') VALUE ';
END CASE;
RETURN STRHTMLDITEM;
END FNC_GEN_GUI_ITEM;
MY TABLE AS FOLLOWS:
CREATE TABLE "NEWPROJ"."DINFIELDGUI"
( "ID" NUMBER NOT NULL ENABLE,
"FLD_TYPE" NUMBER,
"FLD_NAME" VARCHAR2(4000 BYTE),
"FLD_VALUE" VARCHAR2(4000 BYTE),
CONSTRAINT "DINFIELDGUI_PK" PRIMARY KEY ("ID"));
Message was edited by:
Marcello NocitoHi to all,
i've solved, is very simple using decode inside the select:
SELECT
ID,
FK_HTMLDB_ITEM, DECODE(FK_HTMLDB_ITEM,1,HTMLDB_ITEM.DATE_POPUP(3,rownum,VAL,'dd-mon-yyyy'),2,HTMLDB_ITEM.TEXT(3,VAL)) VALORE
FROM TESTID
my table is:
CREATE TABLE "DEV"."TESTID"
( "ID" NUMBER NOT NULL ENABLE,
"FK_HTMLDB_ITEM" NUMBER,
"VAL" VARCHAR2(4000 BYTE))
Bye Bye -
F4 help based on the records in the same column
Dear All
its an fantastic blog....i have one different question for u....n u can check the below..
is it possible to get F4 functionality for a record in column in ALV based on the first 3 records of the same column....
material vendor shipping contract
2 4 6 -
> 5(f4 help)
3 2 4 6(f4 help)
the contract value should only come based on the first 3 records of the coulumn and it shouldnt show any other value...other than combination values of first 3 records.....
hope u got me know.....
please let me know if you need further clarification....thanks in advance....
Regards,
Kartheek.....Hi Kartheek,
do a where-used-list on function F4_INT_HELP_VALUE_REQUEST, start with B* programs.
Or do a search on SCN and find [ABAP Code Sample to Attach F1 and F4 Help Fields in ALV Grid|http://www.sdn.sap.com/irj/scn/index?rid=/library/uuid/b3d5e890-0201-0010-c0ac-bba85ec2ae8d] and [view the code sample|http://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/b3d5e890-0201-0010-c0ac-bba85ec2ae8d?quicklink=index&overridelayout=true].
I hope your approved programming skills allow you to copy&paste.
Regards.
Clemens -
Different ItemRenderer's in the same column of a datagrid
I am using actionscript to read some XML input and dynamically add data into the datagrid.
Currently I am reading the first row and depending on the data type of the coulmn i am creating the column to be a IntemRenderer of Image, or Link button.
Now is there anyway of adding some rows to be LinkButton ItemRenderes and some to be Image ItemRenderers, in the same column?
Any examples are also appreciatedYou can try overriding createColumnItemRenderer
Alex Harui
Flex SDK Developer
Adobe Systems Inc.
Blog: http://blogs.adobe.com/aharui -
Does not do the sorting if I click twice to the same column.
Hello
I am new to winforms.
I have a listview. I want it to toggle the sorting of the records of the listview when the columns are clicked
Please guide me as to how to do the same.
The code that I have attached does not do the sorting if I click twice to the same column. I have to click a different column ten the previous column
The code is attached below
regards
Manoj Gokhale
private void SiteInChargeorSupervisor_Load(object sender, EventArgs e)
this.listView1.ColumnClick += new ColumnClickEventHandler(listView1_ColumnClick);
private void listView1_ColumnClick(object sender, ColumnClickEventArgs e)
ListViewSorter Sorter = new ListViewSorter();
listView1.ListViewItemSorter = Sorter;
if (!(listView1.ListViewItemSorter is ListViewSorter))
return;
Sorter = (ListViewSorter)listView1.ListViewItemSorter;
if (Sorter.LastSort == e.Column)
if (listView1.Sorting == System.Windows.Forms.SortOrder.Ascending)
listView1.Sorting = System.Windows.Forms.SortOrder.Descending;
else
listView1.Sorting = System.Windows.Forms.SortOrder.Ascending;
else
listView1.Sorting = System.Windows.Forms.SortOrder.Descending;
Sorter.ByColumn = e.Column;
listView1.Sort();
public class ListViewSorter : System.Collections.IComparer
public int Compare(object o1, object o2)
if (!(o1 is ListViewItem))
return (0);
if (!(o2 is ListViewItem))
return (0);
ListViewItem lvi1 = (ListViewItem)o2;
string str1 = lvi1.SubItems[ByColumn].Text;
ListViewItem lvi2 = (ListViewItem)o1;
string str2 = lvi2.SubItems[ByColumn].Text;
int result;
if (lvi1.ListView.Sorting == System.Windows.Forms.SortOrder.Ascending)
result = String.Compare(str1, str2);
else
result = String.Compare(str2, str1);
LastSort = ByColumn;
return (result);
public int ByColumn
get { return Column; }
set { Column = value; }
int Column = 0;
public int LastSort
get { return LastColumn; }
set { LastColumn = value; }
int LastColumn = 0;Every time through the ColumnClick event handler, you are creating a new sorter. This means that any values set in the sorter from the previous click are not saved.
Try this.
private void listView1_ColumnClick(object sender, ColumnClickEventArgs e)
// Only create a new sorter if we don't have one already.
if(listView1.ListViewItemSorter == null)
ListViewSorter Sorter = new ListViewSorter();
listView1.ListViewItemSorter = Sorter;
// And so on with the rest of your code. -
Multiple component renderer in the advanced datagrid in the same column
Hi
All I want is to render multiple Components in the same column based on the rowIndex value.
Let me know if it is possible. Right now I am able to render the same components in the multiple rows in the same column.
Example for further clarification:
all in [] needs to be rendered as a compoennt
Name Component-to-be-renedered Chart-component
xyz [ Combobox ] [piechart based on values]
abc [List] [Column Chart based on value]
Many Thanks,
Piyush<mx:states>
<mx:State name="firstComponentsSet">
<mx:AddChild position="lastChild">
<mx:Button />
</mx:AddChild>
</mx:State>
<mx:State name="secondComponentsSet">
<mx:AddChild position="lastChild">
<mx:TextInput />
</mx:AddChild>
</mx:State>
</mx:states>
<mx:Script>
<![CDATA[
override public function set data(value:*):void {
super.data = value;
currentState = '';
// if data requires firstComponetns set
currentState = 'firstComponentsSet';
// else
currentState = 'secondComponentsSet';
]]>
</mx:Script> -
SSRS 2012
Dataset (40 columns) including the first 3 rows for Report layout configuration (eg: the <second> row specifies the column background color).
Starting from the 4th row, the dataset contains data to be displayed.
I would like to change the background color of the ColumnHeader/Column based on the value in the same column in the <second> row.
How can I accomplish the this requirement? (this must be applied for all the columns)
ThanksHi Fasttrck2,
Per my understanding that you want to specify the background color of all the columns/column header based on the value in one special column of the special row, right?
I have tested on my local environment and you can add expression to condition show the background color in the columns properties or the column header properties.
Details information below for your reference:
Specify the background color in the Column header: you can select the entire column header row and in the properties add expression in the Background color :
If you want to specify the background color for the entire column, you can select the entire column and add the expression, repeat to add background color for other columns.
If you want to specify the background color based on the value in the specific columns and row, you can create an hidden parameter to get the list of values from the specific column, specify the Available values and default values by select "Get
values from a query", finally using the expression as below to get the specific value you want:
Expression(Backgroud Color):
=IIF(Parameters!Para.Value(1)="1221","red","yellow")
If your problem still exists, please try to provide some smaple data of the report and also the snapshot of the report structure to help us more effective to provide an solution.
Any problem, please feel free to ask.
Regards
Vicky Liu
If you have any feedback on our support, please click
here.
Vicky Liu
TechNet Community Support -
Can we create two dashboard prompts for the same column in the samepage
hi ,
can we create two dashboard prompts for the same column on the same page,
I have a date column and I am trying to create 2 dashboard prompts on the same page one as from date and the other one as to date.Is this possible to create.When I am trying to create it is giving me error like cannot use same column for creating the prompt
Any suggestions or ideas863997 wrote:
hi ,
can we create two dashboard prompts for the same column on the same page,
I have a date column and I am trying to create 2 dashboard prompts on the same page one as from date and the other one as to date.Is this possible to create.When I am trying to create it is giving me error like cannot use same column for creating the prompt
Any suggestions or ideasYou are correct. You cannot build two prompts on the same column. Use this link for instructions on how to build a "between prompt" because of this fact:
http://oraclebizint.wordpress.com/2008/02/26/oracle-bi-ee-101332-between-prompts-for-date-columns-using-presentation-variables/ -
Keyfigs in the same columns without distrubing eachone
I am a newbie in the BI..and i have some problem.
how can we get two KF in the same column?
i have 52 weeks in the column and along with that i need amount column also.how can it possible.i dont want to see weeks at amount.
.............||<u>|amount||quantity|week 1| week 2|(up to 52 weeks) |total days|</u>
<u>employee</u>||
i took employee as the char and amount,quantity as kf.
but the problem is when i am executing the Query,weeks are comeing along with amount also.i need weeks with quantity only.
could you people please give some clues?
thanks alotSuresh,
Do you need to display the weeks in a column? If you only want the total there, pull the Week characteristic out of there and leave it in the Free Characteristic section.
If you do need the weeks there for another key figure, you are going to have to create a structure - each week will have the key figure within that selection and then a selection with all your weeks selected as a range and the Amount key figure.
Regards
Gill
Maybe you are looking for
-
Pretty clear what happened: the so called upgrade wiped the bookmarks out and got rid of the VERY useful bookmarks bar. The window that now comes up is worthless and cumbersome. I need my bookmarks back. I looked in the profile for a possible second
-
Error while editing PO - deleting service line item and creating material line item.
In SAP SRM Extended classic scenario, PO is in 'ordered' status and contains a service line item. While editing this PO, I delete the service line item and create a new material line item. This gives me the following error. Back end error: Enter G/L
-
What is the best way to import contacts from a spreadsheet to my iphone 4S
Hi, I have around 20,000 contacts that I wish to import onto my iphone 4S. I am currently compiling a spreadsheet from all different sources. I am based in the UK. Would there be any format that I need to used? Is there some sort of application that
-
Search option using a new small window in oracle forms using pl/sql
Hai Friend, Iam Navya Jeevan,regarding Oracle Forms and Reports Doubts. Our project is developed using Forms and Reports In Forms for triggers we are using Pl/SQl language. DOUBT IN a form we require an option like search button when we press the sea
-
Screen size - Is it possible to get an accessor to see it enlarged.
I want to get a remote control but I'd like to be able to see the display without having to be right at the unit. Is there an available option?