Customized DataTips
Hi,
I am using a Flex 3 Plot chart component which takes its data from an external XML file
I am showing the dataTips on mouse over the plot.
1) I would like to have the dataTip to remain / appear as long as the mouse is over the DataTip box also.
Only on removing the mouse out from the plot point (or) the DataTip box, the dataTip should disappear.
2) Also, the DataTip can disappear when the user forces to close the Tip by clicking the close icon in the DataTip.
How do I achieve the above functionality?
- Sen
Hi Shery,
Based on your description, my understanding is that you want to send notification to an addition approver when the request is pending for two days.
I recommend to use the Expiration function to send the email notification after the task is pending for two days.
1. Set the Duration per Task to be 2 days in the approval workflow in SharePoint Designer.
2. Click Approval in the Start Approval Process step in the workflow, then click Change the behavior of a single task under Customization, and then change the user in the email step under When a Task Expires or reassign the task to another user based on
your need.
Please refer to the image below:
Best regards.
Thanks
Victoria Xia
TechNet Community Support
Similar Messages
-
How do I make a Custom DataTip with Custom ItemRenderer
I can't seem to find any documentation or examples of
displaying a dataTip (similar to those used with charting) with my
custom itemRenderer (mxml component). This is for use in a
dataGridColumn. I Could someone give me an example? The closest
I've been able to find is
http://www.mail-archive.com/[email protected]/msg61624.html,
which doesn't say how to do it.
Thanks!http://blog.bigfatstogie.com/?p=42
run the example towards the end of the page -
Slow AdvancedDataGrid rendering
Hello -
I have a project that uses an AdvancedDataGrid with over 60
dynamically generated columns, grouped dynamically (there are three
sub groupings above each actual colum), and fed with Hierarchical
data. So each row of my ADG will expand one level to reveal another
set of rows: Usually 5 at a time.
This means, currently I'm drawing about 300 cells with
colored backgrounds.
Initially I used a Box for my custom item renderer to draw
the colored backgrounds but found that the grid timed out when
rendered. By switching to extend the AdvancedDataGridItemRenderer I
picked up a SIGNIFICANT performance improvement. I set my
background color in the set data( ) method of the item renderer.
For the grouping column that expands, I use something derived from
AdvancedDataGridGroupItemRenderer, coupled with setting the
groupLabelFunction function.
I overrode the AdvancedDataGridColumn to provide a custom
dataTip function. Beyond that, I let default behavior happen.
So what I'm noticing is that when I expand or contract the
tree it takes a second or two of waiting before it draws. The set
data( ) gets called on just about everything in the grid each time.
Is this timing expected for my number of grouped columns and cells?
I get the impression that others have larger tables with no lag. So
maybe I'm missing something.
I've been reading all sorts of thing to improve the
performance. Eventually this table will be much much larger. By the
time the application is fully mature, I will be responsible for
displaying up to 20,000 colored cells. So I worry about having this
not be usable as more data hits it.
Initially I was setting the color in the validateNow
function of the renderer. Moving it to setData and not overriding
validateNow helped. What else do people suggest?
So - to summarize:
1) Should I be seeing a lag at all with 300 data points and
60 grouped columns?
2) What are other things to look for to make this faster
rendering?
Thank you all,
Joel"dalejoel" <[email protected]> wrote in
message
news:[email protected]...
> Hello -
>
> I have a project that uses an AdvancedDataGrid with over
60 dynamically
> generated columns, grouped dynamically (there are three
sub groupings
> above
> each actual colum), and fed with Hierarchical data. So
each row of my ADG
> will
> expand one level to reveal another set of rows: Usually
5 at a time.
>
> This means, currently I'm drawing about 300 cells with
colored
> backgrounds.
>
> Initially I used a Box for my custom item renderer to
draw the colored
> backgrounds but found that the grid timed out when
rendered. By switching
> to
> extend the AdvancedDataGridItemRenderer I picked up a
SIGNIFICANT
> performance
> improvement. I set my background color in the set data(
) method of the
> item
> renderer. For the grouping column that expands, I use
something derived
> from
> AdvancedDataGridGroupItemRenderer, coupled with setting
the
> groupLabelFunction
> function.
>
> I overrode the AdvancedDataGridColumn to provide a
custom dataTip
> function.
> Beyond that, I let default behavior happen.
>
> So what I'm noticing is that when I expand or contract
the tree it takes a
> second or two of waiting before it draws. The set data(
) gets called on
> just
> about everything in the grid each time. Is this timing
expected for my
> number
> of grouped columns and cells? I get the impression that
others have larger
> tables with no lag. So maybe I'm missing something.
>
> I've been reading all sorts of thing to improve the
performance.
> Eventually
> this table will be much much larger. By the time the
application is fully
> mature, I will be responsible for displaying up to
20,000 colored cells.
> So I
> worry about having this not be usable as more data hits
it.
>
> Initially I was setting the color in the validateNow
function of the
> renderer. Moving it to setData and not overriding
validateNow helped. What
> else
> do people suggest?
>
> So - to summarize:
> 1) Should I be seeing a lag at all with 300 data points
and 60 grouped
> columns?
> 2) What are other things to look for to make this faster
rendering?
I'd either go with a style function or move it to
commitProperties and set a
flag in set data and call invalidateProperties(). There's a
lightweight
itemRenderer in my extended datagrid with style function you
might want to
look at. It doesn't include icon functionality, but you can
look at it for
the types of things you might want to do.
http://flexdiary.blogspot.com/2008/09/extended-datagrid-with-stylefunction.html
HTH;
Amy -
Simple Flex Chart question - Plot Chart labels
I'm playing around with displaying data from WDA as charts in Flex 3.
I'm able to bind my internal table, which has 3 fields, to the plot chart.
The table looks like this
ext_id type string " bound to prjname in Flex
cost type string " bound to prjcost in Flex
benefit type string " bound to prjbenefit in Flex
These are all bound to my island's DataSource.
I have bound these in Flex and the Cost and Benefits are showing up as points on my chart. However, I can't seem to get the Project Name to display on the plot points. All I see when I mouse over the point is EXT_ID, and the values for cost and benefits.
The cost/benefit values are coming across correctly, just not the project name (ext_id) value. any ideas?
here's the Flex code for the chart
[Bindable]
public var dataSource:ArrayCollection;
[Bindable]
public var prjcost:String;
[Bindable]
public var prjbenefit:String;
[Bindable]
public var prjname:String;.
<mx:PlotChart id="plotchart1" dataProvider="{dataSource}" showDataTips="true">
<mx:series>
<mx:PlotSeries displayName="{prjname}" yField="{prjcost}" xField="{prjbenefit}" dataProvider="/>
</mx:series>
</mx:PlotChart>This is really a Flex question not an Islands specific one. I don't think the displayName properity is what you want to use here. This is the name for the entire series as it will be displayed in the legend. I think what you want is a dataTip. You register a callback for the dataTip rendering and then fill the custom dataTip quick info.
This is an example from a bar chart, but the theory is the same:
<mx:BarChart id="barChart" dataTipFunction="dtFunc" xmlns:mx="http://www.adobe.com/2006/mxml" type="clustered" width="100%" showDataTips="true" height="100%">
<mx:verticalAxis>
<mx:CategoryAxis categoryField="{SalesOrd}" dataProvider="{dataSource}" />
</mx:verticalAxis>
<mx:series>
<mx:BarSeries id="bsGross" xField="{grossAmt}" displayName="Gross Amount" dataProvider="{dataSource}" fill="{otdFill}" showDataEffect="{slideIn}" />
<mx:BarSeries id="bsNet" xField="{netAmt}" displayName="Net Amount" dataProvider="{dataSource}" fill="{rtyFill}" showDataEffect="{zoomIn}" />
</mx:series>
</mx:BarChart>
private function dtFunc(hd:HitData):String {
switch(BarSeries(hd.element).id){
case "bsGross":
return "Sales Order #: " + hd.item.SO_ID + "\n" + FlashIsland.formatNumber(hd.item.TTL_GROSS_AMOUNT) + " " + hd.item.CURRENCY_CODE;
break;
case "bsNet":
return "Sales Order #: " + hd.item.SO_ID + "\n " + FlashIsland.formatNumber(hd.item.TTL_NET_AMOUNT) + " " + hd.item.CURRENCY_CODE;
break;
return "Amount"; -
CustomDataTip function in Main application....
Hi,
I have one main application and one custom component..In custom component i have pie chart..I want to write the custom datatip function in main application and call this custom data tip function in custom component in pie chart's dataTipFunction..How can this be done???
Thanks,
VibhutiI would put a dataTipFunction variable on the custom component and bind the chart’s dataTipFunction to it.
-
Simple gant chart with parent_id
Hi,
I'm trying to recreate the following project gant chart on my system
http://apex.oracle.com/pls/apex/f?p=36648:4:896508273706037::NO
I don't understand why on my side the 'chart integration' task is not having the red arrow for drill down.
What I'm doing wrong?
Many thanks in advance,
Florin
this is my table:
CREATE TABLE "GANTT_TEST"
( "TASK_ID" NUMBER,
"TASK_NAME" VARCHAR2(55),
"START_DATE" DATE,
"END_DATE" DATE,
"STATUS" NUMBER,
"PARENT_ID" NUMBER,
"PLANNED" DATE,
"PLANNED_END" DATE
I have 3 lines. 2 of them have on the PARENT_ID the TASK_ID=1This is really a Flex question not an Islands specific one. I don't think the displayName properity is what you want to use here. This is the name for the entire series as it will be displayed in the legend. I think what you want is a dataTip. You register a callback for the dataTip rendering and then fill the custom dataTip quick info.
This is an example from a bar chart, but the theory is the same:
<mx:BarChart id="barChart" dataTipFunction="dtFunc" xmlns:mx="http://www.adobe.com/2006/mxml" type="clustered" width="100%" showDataTips="true" height="100%">
<mx:verticalAxis>
<mx:CategoryAxis categoryField="{SalesOrd}" dataProvider="{dataSource}" />
</mx:verticalAxis>
<mx:series>
<mx:BarSeries id="bsGross" xField="{grossAmt}" displayName="Gross Amount" dataProvider="{dataSource}" fill="{otdFill}" showDataEffect="{slideIn}" />
<mx:BarSeries id="bsNet" xField="{netAmt}" displayName="Net Amount" dataProvider="{dataSource}" fill="{rtyFill}" showDataEffect="{zoomIn}" />
</mx:series>
</mx:BarChart>
private function dtFunc(hd:HitData):String {
switch(BarSeries(hd.element).id){
case "bsGross":
return "Sales Order #: " + hd.item.SO_ID + "\n" + FlashIsland.formatNumber(hd.item.TTL_GROSS_AMOUNT) + " " + hd.item.CURRENCY_CODE;
break;
case "bsNet":
return "Sales Order #: " + hd.item.SO_ID + "\n " + FlashIsland.formatNumber(hd.item.TTL_NET_AMOUNT) + " " + hd.item.CURRENCY_CODE;
break;
return "Amount"; -
Custom graph datatip doesn't hide on mouseout
Hi all, I've got a custom DataTipRenderer class I use for my
graph that displays correctly on mouse over, but when mouse gets
out the graph, it doesn't hide sometimes, if I move the mouse over
other items or so...
there's anyway to force the datatip to hide?
thanks,Can you post the source code for your custom data tip
renderer? If it extends DataTip, you should only have to override
updateDisplayList(), which wouldn't affect the showing and hiding
of the data tip.
matt horn
flex docs -
Customizing Chart DataTip position
Hi,
I am using Flex 3 Column Chart with Stacked property
I use two column series
On mouseOver the column bars, the dataTip appears near the bar.
I use a dataTip function to provide the contents for the DataTip & it might take 4 - 5 lines.
I would like to have the DataTip box always appear on the top left corner of the chart.
So, I create a DataTip renderer as shown below by shifting the DataTip to x:20 & y:15
import flash.display.*;
import flash.display.Graphics;
import mx.charts.chartClasses.DataTip;
public class MyDataTip extends DataTip
public function MyDataTip()
super();
override protected function createChildren():void
super.createChildren();
override protected function updateDisplayList(unscaledWidth:Number, unscaledHeight:Number):void
super.updateDisplayList(unscaledWidth, unscaledHeight);
this.x = 20;
this.y = 15;
I apply this to the chart like (during application creationComplete() event:
myChart.setStyle("dataTipRenderer",MyDataTip);
But even when I do this, I do get a flickering when I mouseOver the chart bar and the DataTip box appears near the bar, then in the top left position
and When I mouseOver the bars the display refresh problem takes place
How to override this so that the box always appear the top left corner without any flickering
- SenSince DataTip inherits from UIComponent, you should use the move method to position it. Also use the setActualSize method in the override.
super.updateDisplayList(unscaledWidth, unscaledHeight);
this.move(20, 15);
this.setActualSize(unscaledWidth, unscaledHeight); -
Problem with FTE in DataTips of PlotChart (missing texts)
Hi @all,
we have decided to use the Flex 4.1 and Flash text engine in our projects.
Now I have the following problem with the dataTips: the texts are appearing only partly if datatips of more than one point are showing. The behavior is not regularly.
Here is my code for testing (compiler options: hook at "Use Flash Text engine in MX components":
<?xml version="1.0" encoding="utf-8"?>
<s:Application xmlns:fx="http://ns.adobe.com/mxml/2009"
xmlns:s="library://ns.adobe.com/flex/spark"
xmlns:mx="library://ns.adobe.com/flex/mx"
minWidth="955"
minHeight="600"
creationComplete="init()">
<fx:Declarations>
<mx:SolidColor id="sc1" color="#EC6605" alpha=".3"/>
<mx:SolidColorStroke id="s1" color="#EC6605" weight="1"/>
</fx:Declarations>
<fx:Script>
<![CDATA[
import mx.charts.HitData;
import mx.collections.ArrayCollection;
[Bindable]
private var seriesAverageScores:ArrayCollection = new ArrayCollection(new Array());
private static const tipDataString:String = "zeile 1 zeile 1 zeile 1\nzeile 2 zeile 2 zeile 2\nzeile 3 zeile 3 zeile 3\nzeile 4 zeile 4 zeile 4\n -\n -\n -";
private function init():void {
seriesAverageScores.addItem({x: 1, y: 2, dataTip: tipDataString});
seriesAverageScores.addItem({x: 2, y: 2, dataTip: tipDataString});
seriesAverageScores.addItem({x: 3, y: 2, dataTip: tipDataString});
seriesAverageScores.addItem({x: 1.1, y: 2, dataTip: tipDataString});
seriesAverageScores.addItem({x: 2, y: 2, dataTip: tipDataString});
seriesAverageScores.addItem({x: 3, y: 2, dataTip: tipDataString});
seriesAverageScores.addItem({x: 1.05, y: 2, dataTip: tipDataString});
seriesAverageScores.addItem({x: 2, y: 2, dataTip: tipDataString});
seriesAverageScores.addItem({x: 3, y: 2, dataTip: tipDataString});
seriesAverageScores.addItem({x: 0.95, y: 2, dataTip: tipDataString});
seriesAverageScores.addItem({x: 2, y: 2, dataTip: tipDataString});
seriesAverageScores.addItem({x: 3, y: 2, dataTip: tipDataString});
seriesAverageScores.addItem({x: 1.2, y: 2, dataTip: tipDataString});
seriesAverageScores.addItem({x: 2, y: 2, dataTip: tipDataString});
seriesAverageScores.addItem({x: 3, y: 2, dataTip: tipDataString});
seriesAverageScores.addItem({x: 1.15, y: 2, dataTip: tipDataString});
seriesAverageScores.addItem({x: 2, y: 2, dataTip: tipDataString});
seriesAverageScores.addItem({x: 3, y: 2, dataTip: tipDataString});
seriesAverageScores.addItem({x: 1.12, y: 2, dataTip: tipDataString});
seriesAverageScores.addItem({x: 2, y: 2, dataTip: tipDataString});
private function dataTipFunction_average(hd:HitData):String {
var val:String;
var d:Object = hd.item as Object;
return d.dataTip;
]]>
</fx:Script>
<s:VGroup width="100%"
height="100%">
<mx:PlotChart id="myChart1" width="100%" height="100%"
dataTipFunction="dataTipFunction_average" showDataTips="true">
<mx:verticalAxis>
<mx:LinearAxis title="TurnOvers" padding="0.1" minimum="0" maximum="50"/>
</mx:verticalAxis>
<mx:horizontalAxis>
<mx:LinearAxis title="Scores" padding="0.1" minimum="0" maximum="10"/>
</mx:horizontalAxis>
<mx:series>
<mx:PlotSeries dataProvider="{seriesAverageScores}"
name="series 1" fill="{sc1}" stroke="{s1}"
displayName="Average Scores per customer"
xField="x"
yField="y">
</mx:PlotSeries>
</mx:series>
</mx:PlotChart>
</s:VGroup>
</s:Application>
Has anyone an idea how to solve this ?
Thanks, LutzHas noone an idea?
The same problem exists with Legends. For this there was a help from Adobe with a style.
Isn't there a comparable solution for this malfunction? -
Show dataTip on a datagrid column
Hi,
I need to show dataTip on a datagrid column only if its length is greater than 20 chars.
Additionaly, my datagrid is a custom component, I am passing the column names as an array and building the grid dynamically
so that it could be used for any dataprovider (with different set of columns).
when the dataTipFunction is invoked runtime I would not know the column field name
to access the value since the dataTipFunction makes available only the item:Object unlike labelFunction which provides both item and column.
But i would know all the column names at any given point in time.
Is there anyway we can get hold for which column the dataTipFunction is being called for...
Any help is greatly appreciated.Subclass DataGridColumn and add the dataTipFunction to the subclass. Then
the 'this' pointer will be the column. -
DataTip box to appear near the plot for Plot Chart
Hi,
I am using a Plot chart.
I use three Plot series for the chart.
I show the plots for one series at a time.
When I show the Data tips for each plot, I am getting a long line connecting the plot & the DataTip (as shown in attachment).
I would like the DataTip box to appear near the plot.
How to accomplish this ?
- SenThe bottom line is that it does not work reliably, Tim.
I had occasion to scan old Kodachrome slides (2x2" in cardboard mount), and placed identifying markers with "Talk Bubbles."
Open your picture file
Access the Custom Shape Tool (U). On the tool's option bar at the top next to "Shapes", click on the arrow and find the "Talk Bubbles" library. In that there are several shapes which you can drag into position. The shapes fill with the foreground color (see chips, lower left of work-space)
Next, use the Type tool for the name.
Note that you can position the shape and the name with the move tool, and resize with the corner handles of the bounding box -- the advantage of doing things in layers. -
My VScrollBar skin only have two part track and thumb.
I find my VScrollBar can't drag to the end ?
Can somebody give some suggestion ?
I'm using flex4.5.1.
<s:SparkSkin xmlns:fx="http://ns.adobe.com/mxml/2009" xmlns:s="library://ns.adobe.com/flex/spark"
xmlns:fb="http://ns.adobe.com/flashbuilder/2009" minWidth="15" minHeight="35"
alpha.disabled="0.5" top="2" bottom="2">
<fx:Metadata>
* @copy spark.skins.spark.ApplicationSkin#hostComponent
[HostComponent("spark.components.mediaClasses.ScrubBar")]
</fx:Metadata>
<fx:Script fb:purpose="styling">
/* Define the skin elements that should not be colorized. */
static private const exclusions:Array = ["track", "thumb"];
* @private
override public function get colorizeExclusions():Array {return exclusions;}
* @private
override protected function initializationComplete():void
useChromeColor = true;
super.initializationComplete();
</fx:Script>
<s:states>
<s:State name="normal" />
<s:State name="disabled" />
<s:State name="inactive"/>
</s:states>
<fx:Declarations>
<!--- Defines the appearance of the ScrubBar skin's data tip. To customize the data tip's appearance, create a custom ScrubBarSkin class. -->
<fx:Component id="dataTip">
<s:DataRenderer minHeight="24" minWidth="40" y="-34">
<s:RectangularDropShadow id="shadow" distance="3"
angle="90" color="#999999" left="0" top="0" right="0" bottom="0"/>
<s:Rect top="0" left="0" right="0" bottom="0">
<s:fill>
<s:SolidColor color="0x000000" alpha=".9"/>
</s:fill>
</s:Rect>
<s:Label id="labelDisplay" text="{data}"
horizontalCenter="0" verticalCenter="1"
left="5" right="5" top="5" bottom="5"
textAlign="center" verticalAlign="middle"
fontWeight="normal" color="white" fontSize="11">
</s:Label>
</s:DataRenderer>
</fx:Component>
</fx:Declarations>
<!--- The skin pat that defines the video timeline. The timeline shows the current playhead location
in the video, the amount of the video previously played, and the loaded in part of the video. -->
<!--- @copy spark.components.mediaClasses.ScrubBar#loadedRangeArea -->
<s:Group id="loadedRangeArea" x="0" y="0" height="11" includeInLayout="false">
<!-- inset 7 and 6 pixels because that's thumbSize/2 -->
<s:Group left="7" right="6" top="0" bottom="0" minWidth="0">
<!-- fill -->
<s:Rect left="1" right="1" top="1" bottom="1">
<s:fill>
<s:SolidColor color="0xD7D7D7" />
</s:fill>
</s:Rect>
<!-- inner glow -->
<!-- set height to 100%, maxHeight=1, minHeight=0 b/c only want this line to show up
if there's room for it -->
<s:Rect left="1" top="1" bottom="1" width="100%" maxWidth="1" minWidth="0">
<s:fill>
<s:SolidColor color="0x000000" alpha="0.12" />
</s:fill>
</s:Rect>
<s:Rect left="2" right="1" top="1" height="100%" maxHeight="1" minHeight="0">
<s:fill>
<s:SolidColor color="0x000000" alpha="0.12" />
</s:fill>
</s:Rect>
<!-- black line on right -->
<!-- set width to 100%, maxWidth=1, minWidth=0 b/c only want this line to show up
if there's room for it -->
<s:Rect right="0" top="1" bottom="1" width="100%" maxWidth="1" minWidth="0">
<s:fill>
<s:SolidColor color="0x000000" alpha=".5"/>
</s:fill>
</s:Rect>
</s:Group>
</s:Group>
<!--- @copy spark.components.mediaClasses.ScrubBar#playedArea -->
<s:Group id="playedArea" x="0" y="0" height="11" includeInLayout="false">
<!-- inset 7 and 6 pixels because that's thumbSize/2 -->
<s:Group left="7" right="6" top="0" bottom="0" minWidth="0">
<!-- inner glow -->
<s:Rect left="1" right="1" top="1" bottom="1">
<s:fill>
<s:LinearGradient rotation="90">
<s:GradientEntry color="0xFEFEFE"/>
<s:GradientEntry color="0xECECEC"/>
</s:LinearGradient>
</s:fill>
</s:Rect>
<!-- fill -->
<s:Rect left="2" right="2" top="2" bottom="2">
<s:fill>
<s:LinearGradient rotation="90">
<s:GradientEntry color="0xFFFFFF" alpha="0.85"/>
<s:GradientEntry color="0xE1E1E1" alpha="0.85"/>
</s:LinearGradient>
</s:fill>
</s:Rect>
<!-- black line on right -->
<!-- set width to 100%, maxWidth=1, minWidth=0 b/c only want this line to show up
if there's room for it -->
<s:Rect right="0" top="1" bottom="1" width="100%" maxWidth="1" minWidth="0">
<s:fill>
<s:SolidColor color="0x131313"/>
</s:fill>
</s:Rect>
</s:Group>
</s:Group>
<!--- A skin part that defines a button that can be dragged along the track to increase or decrease
the playhead location in the video. -->
<s:Button skinClass="skin.MyTrackSkin" id="track" horizontalCenter="0" minHeight="14"
focusEnabled="false" tabEnabled="false" top="2" bottom="2">
<s:filters>
<s:GlowFilter includeIn="normal" blurX="6.0" blurY="6.0" inner="false" color="0x5380d0" strength="1" alpha="1.0" quality="2" knockout="false"/>
</s:filters>
</s:Button>
<s:Button skinClass="skin.MyThumbSkin" id="thumb" focusEnabled="false" visible.inactive="false" tabEnabled="false" verticalCenter="0">
<s:filters>
<s:GlowFilter includeIn="normal" blurX="13" blurY="13" inner="false" color="#000000" strength="2" alpha="1.0" quality="2" knockout="false"/>
</s:filters>
</s:Button>
<s:transitions>
<s:Transition fromState="normal" toState="disabled" autoReverse="true">
<s:Parallel>
<s:Parallel target="{thumb}">
<s:Move duration="0" autoCenterTransform="true"/>
</s:Parallel>
</s:Parallel>
</s:Transition>
</s:transitions>
</s:SparkSkin>
The track skin:
<s:Skin xmlns:fx="http://ns.adobe.com/mxml/2009"
xmlns:s="library://ns.adobe.com/flex/spark"
xmlns:fb="http://ns.adobe.com/flashbuilder/2009"
alpha.disabled="0.5">
<fx:Metadata>
<![CDATA[
* @copy spark.skins.spark.ApplicationSkin#hostComponent
[HostComponent("spark.components.Button")]
]]>
</fx:Metadata>
<!-- states -->
<s:states>
<s:State name="up" />
<s:State name="over" />
<s:State name="down" />
<s:State name="disabled" />
</s:states>
<s:Rect bottom="2" top="2" right="0" width="2" alpha="0.84" radiusX="10" radiusY="10">
<s:fill>
<s:SolidColor color="#5380D0"/>
</s:fill>
</s:Rect>
</s:Skin>
The thumb skin:
<s:SparkSkin xmlns:fx="http://ns.adobe.com/mxml/2009"
xmlns:s="library://ns.adobe.com/flex/spark"
xmlns:fb="http://ns.adobe.com/flashbuilder/2009"
alpha.disabled="0.5" >
<fx:Metadata>
<![CDATA[
* @copy spark.skins.spark.ApplicationSkin#hostComponent
[HostComponent("spark.components.Button")]
]]>
</fx:Metadata>
<!-- states -->
<s:states>
<s:State name="up" />
<s:State name="over" />
<s:State name="down" />
<s:State name="disabled" />
</s:states>
<s:Ellipse left="0" width="15" height="15" >
<!--<s:stroke>
<s:SolidColorStroke color="0x0f0f8f" weight="1"/>
</s:stroke>-->
<s:fill>
<s:SolidColor color="#232323" />
</s:fill>
</s:Ellipse>
</s:SparkSkin>This 's all my code custom the dropdownlist skin and vertical scrollbar skin.
The application.mxml
<s:Application xmlns:fx="http://ns.adobe.com/mxml/2009"
xmlns:s="library://ns.adobe.com/flex/spark"
xmlns:mx="library://ns.adobe.com/flex/mx" minWidth="955" minHeight="600">
<fx:Style>
@namespace s "library://ns.adobe.com/flex/spark";
@namespace mx "library://ns.adobe.com/flex/mx";
s|Application{
fontFamily: "Microsoft YaHei";
s|PopUpAnchor{
</fx:Style>
<fx:Declarations>
<s:ArrayList id="arr">
<fx:String><![CDATA[English]]></fx:String>
<fx:String>Franch</fx:String>
<fx:String>Spanish</fx:String>
<fx:String>Russian</fx:String>
<fx:String>Chinese</fx:String>
<fx:String><![CDATA[English]]></fx:String>
<fx:String>Franch</fx:String>
<fx:String>Spanish</fx:String>
<fx:String>Russian</fx:String>
<fx:String>Chinese</fx:String>
<fx:String>The End</fx:String>
</s:ArrayList>
<!-- Place non-visual elements (e.g., services, value objects) here -->
</fx:Declarations>
<s:DropDownList skinClass="skin.MyDropDownListSkin" dataProvider="{arr}" width="170" borderColor="0xff1010"
contentBackgroundColor="0xffffff" contentBackgroundAlpha=".2" borderVisible="true"/>
</s:Application>
The DropDownList skin, I use my vertical scroll bar skin in this file :
<s:SparkSkin xmlns:fx="http://ns.adobe.com/mxml/2009" xmlns:s="library://ns.adobe.com/flex/spark"
xmlns:fb="http://ns.adobe.com/flashbuilder/2009" alpha.disabled=".5">
<!-- host component -->
<fx:Metadata>
<![CDATA[
* @copy spark.skins.spark.ApplicationSkin#hostComponent
[HostComponent("spark.components.DropDownList")]
]]>
</fx:Metadata>
<fx:Script fb:purpose="styling">
<![CDATA[
/* Define the content fill items that should be colored by the "contentBackgroundColor" style. */
static private const contentFill:Array = ["bgFill"];
* @private
override public function get contentItems():Array {return contentFill};
* @private
override protected function updateDisplayList(unscaledWidth:Number, unscaledHeight:Number):void
if (getStyle("borderVisible") == false)
if (border)
border.visible = false;
if (background)
background.left = background.top = background.right = background.bottom = 0;
if (scroller)
scroller.minViewportInset = 0;
else
if (border)
border.visible = true;
if (background)
background.left = background.top = background.right = background.bottom = 1;
if (scroller)
scroller.minViewportInset = 1;
if (dropShadow)
dropShadow.visible = getStyle("dropShadowVisible");
openButton.setStyle("cornerRadius", getStyle("cornerRadius"));
if (borderStroke)
borderStroke.color = getStyle("borderColor");
borderStroke.alpha = getStyle("borderAlpha");
super.updateDisplayList(unscaledWidth, unscaledHeight);
]]>
</fx:Script>
<s:states>
<s:State name="normal" />
<s:State name="open" />
<s:State name="disabled" />
</s:states>
<!---
The PopUpAnchor control that opens the drop-down list.
<p>In a custom skin class that uses transitions, set the
<code>itemDestructionPolicy</code> property to <code>none</code>.</p>
-->
<s:PopUpAnchor id="popUp" displayPopUp.normal="false" displayPopUp.open="true" includeIn="open"
left="0" right="0" top="0" bottom="0" itemDestructionPolicy="auto" popUpHeightMatchesAnchorHeight="false"
popUpPosition="below" popUpWidthMatchesAnchorWidth="true">
<!---
This includes borders, background colors, scrollers, and filters.
@copy spark.components.supportClasses.DropDownListBase#dropDown
-->
<s:Group id="dropDown">
<!--- @private -->
<s:RectangularDropShadow id="dropShadow" blurX="10" blurY="10" alpha="0" distance="2"
angle="90" color="#000000" left="0" top="0" right="0" bottom="0"/>
<!--- @private -->
<s:Rect id="border" left="0" right="0" top="0" bottom="0">
<s:stroke>
<!--- border stroke @private -->
<s:SolidColorStroke id="borderStroke" weight="1" color="0xff0000"/>
</s:stroke>
</s:Rect>
<!-- fill -->
<!--- Defines the appearance of drop-down list's background fill. -->
<s:Rect id="background" left="1" right="1" top="1" bottom="1" >
<s:fill>
<!---
The color of the drop down's background fill.
The default color is 0xFFFFFF.
-->
<s:SolidColor id="bgFill" color="0x1f1f1f" alpha="0.3"/>
</s:fill>
<s:filters>
<s:BlurFilter blurX="2" blurY="2" quality="2" />
</s:filters>
</s:Rect>
<!--- @private -->
<s:Scroller id="scroller" left="10" top="0" right="10" bottom="0" hasFocusableChildren="false" minViewportInset="1" skinClass="skin.MyScrollerSkin">
<!--- @copy spark.components.SkinnableDataContainer#dataGroup-->
<s:DataGroup id="dataGroup" itemRenderer="spark.skins.spark.DefaultItemRenderer" top="0" bottom="0" left="0" right="0">
<s:layout>
<s:VerticalLayout gap="0" horizontalAlign="contentJustify" requestedMinRowCount="1" requestedMaxRowCount="6"/>
</s:layout>
</s:DataGroup>
</s:Scroller>
</s:Group>
</s:PopUpAnchor>
<!--- The default skin is DropDownListButtonSkin.
@copy spark.components.supportClasses.DropDownListBase#openButton
@see spark.skins.spark.DropDownListButtonSkin -->
<s:Button id="openButton" left="0" right="0" top="0" bottom="0" focusEnabled="false" tabEnabled="false"
skinClass="skin.MyDropDownListButtonSkin" />
<!--- @copy spark.components.DropDownList#labelDisplay -->
<s:Label id="labelDisplay" verticalAlign="middle" maxDisplayedLines="1"
mouseEnabled="false" mouseChildren="false" left="12" right="30"
top="2" bottom="2" width="75" verticalCenter="1" />
</s:SparkSkin>
The scrollbar Skin:
<s:SparkSkin xmlns:fx="http://ns.adobe.com/mxml/2009"
xmlns:s="library://ns.adobe.com/flex/spark">
<fx:Metadata>
<![CDATA[
* @copy
spark.skins.spark.ApplicationSkin#hostComponent
[HostComponent("spark.components.Scroller")]
]]>
</fx:Metadata>
<fx:Script>
<![CDATA[
@private
override public function beginHighlightBitmapCapture()
: Boolean
var needUpdate:Boolean =
super.beginHighlightBitmapCapture();
// Draw an opaque rect that
fill our entire skin. Our background
// is transparent, but we don't want
focus/error skins to
// poke through. This is safe to do since we don't
have any
// graphic elements as direct children.
graphics.beginFill(0);
graphics.drawRect(0, 0, width,
height);
graphics.endFill(); */
return
needUpdate;
* @private
override
public function endHighlightBitmapCapture() : Boolean
var
needUpdate:Boolean = super.endHighlightBitmapCapture();
// Clear
the rect we drew in
beginBitmapCapture();
graphics.clear();
return
needUpdate;
]]>
</fx:Script>
<!--- A
vertical scrollbar that lets you control the portion of data that is displayed
when there is too much data to fit vertically in a display area.
The
Scroller determines whether the vertical ScrollBar is visible.
-->
<s:VScrollBar id="verticalScrollBar" visible="false"
skinClass="skin.MyScrollBarSkin"/>
<!--- A horizontal scrollbar
that lets you control the portion of data that is displayed
when there is
too much data to fit horizontally in a display area.
The Scroller determines
whether the horizontal ScrollBar is visible. -->
<s:HScrollBar
id="horizontalScrollBar" visible="false" />
</s:SparkSkin> -
Skinninng dataTip in spark.HSlider
Hello.
I skinned hslider. It works well, except the dataTip.
as a dataTip in my case I use custom component that shows a pie chart.
<fx:Declarations>
<fx:Component id="dataTip" >
<s:DataRenderer y="50" autoLayout="true">
<ui:Pie percentage="{data}" currentState="reference" dynamic="false" />
</s:DataRenderer>
</fx:Component>
</fx:Declarations>
Everything is working ok, except one small thing:
this dataTip is lagging behind the thumb. Means:
when I change the slider value by dragging the thumb, the dataTip follows the thumb but not consistently.
Sometimes it lags up to 10-15 of pixels and stays in this position until I MouseUP. And only when I click on the thumb
again it centers the dataTip.
Do you know how can I speed it up. Or make it recalculate its own position withing hslider skin?thank you but I have already seen this and am using it to add tick marks I cannot get the same technique to work for labels. slider compoent ends up expanding until its too large to render
-
Custom purchase requsitionto vendor open and cleared payment report
dear all i develop report but i cant ableto show in that open amount and cleared amount of vender in that report so please see this report and feedback me for logic to show open and clear amount of vendor purchase orderwise or vendorwise
report zpo_purchase_history no standard page heading message-id 00.
TABLES : bsik, bsak, lfa1, lfb1, skb1, t001, bapifvdexp_vzzbepp.
type-pools:slis,ICON.
types :begin of ty_po,
banfn type eban-banfn,
"Purchase Requisition Number
bnfpo type eban-bnfpo,
"Item Number of Purchase Requisition
ekgrp type eban-ekgrp, "Purchasing Group
badat type eban-badat,
"Requisition (Request) Date
menge type eban-menge,
KNTTP TYPE EBAN-KNTTP,
PSTYP type eban-PSTYP,
"Purchase Requisition Quantity
meins type eban-meins,
"Purchase Requisition Unit of Measure
lifnr type ekko-lifnr, "Vendor Account Number
bedat type ekko-bedat, "Purchasing Document Date
ebeln type ekpo-ebeln,
"Purchasing Document Number
ebelp type ekpo-ebelp,
"Item Number of Purchasing Document
matkl type ekpo-matkl, "Material Group
mtart type ekpo-mtart, "Material Type
matnr type ekpo-matnr, "Material Number
txz01 type ekpo-txz01, "Short Text
menge1 type ekpo-menge, "Purchase Order Quantity
meins1 type ekpo-meins,
"Purchase Order Unit of Measure
balqty type ekpo-menge, "Balance Quantity
netpr type ekpo-netpr,
"Net Price in Purchasing Document
peinh type ekpo-peinh, "Price Unit
mblnr type mseg-mblnr,
"Number of Material Document
zeile type mseg-zeile, "Item in Material Document
menge2 type mseg-menge, "GR Quantity
meins2 type mseg-meins, "GR Unit of Measure
werks type mseg-werks, "Plant
charg type mseg-charg, "Batch
belnr type rbkp-belnr,
"Document Number of an Invoice Document
bldat type ekbe-bldat, "Document Date in Document
belnr_b type rbkp-belnr,
SHKZG type ekbe-SHKZG , "Debit/Credit Indicator
DMBTR type bsik-dmbtr, "Amount in Local Currency
DMBTR_C type bsAk-dmbtr, "Amount in Local Currency
thick(10) type c, "Thickness
width(10) type c, "Width
length(10) type c, "Length
grade(10) type c, "Grade
BELNR_d type bseg-belnr,
xblnr type bkpf-xblnr,
awkey type bkpf-awkey,
RMWWR type rbkp-RMWWR,
WMWST1 type rbkp-WMWST1,
end of ty_po.
types :begin of ty_ekko,
ebeln type ekko-ebeln,
lifnr type ekko-lifnr,
bedat type ekko-bedat,
end of ty_ekko.
types:begin of ty_ekpo,
ebeln type ekpo-ebeln,
ebelp type ekpo-ebelp,
matnr type ekpo-matnr,
txz01 type ekpo-txz01,
menge type ekpo-menge,
meins type ekpo-meins,
netpr type ekpo-netpr,
peinh type ekpo-peinh,
banfn type ekpo-banfn,
bnfpo type ekpo-bnfpo,
mtart type ekpo-mtart,
end of ty_ekpo.
types :begin of ty_eban,
banfn type eban-banfn,
bnfpo type eban-bnfpo,
matnr type eban-matnr,
menge type eban-menge,
meins type eban-meins,
end of ty_eban.
types : begin of ty_ekbe,
ebeln type ekbe-ebeln,
ebelp type ekbe-ebelp,
belnr type ekbe-belnr,
bldat type ekbe-bldat,
gjahr type ekbe-gjahr,
buzei type ekbe-buzei,
matnr type ekbe-matnr,
DMBTR type ekbe-dmbtr,
shkzg type ekbe-shkzg,
end of ty_ekbe.
types : begin of ty_mseg,
mblnr type mseg-mblnr,
mjahr type mseg-mjahr,
zeile type mseg-zeile,
menge type mseg-menge,
meins type mseg-meins,
ebeln type mseg-ebeln,
ebelp type mseg-ebelp,
matnr type mseg-matnr,
werks type mseg-werks,
charg type mseg-charg,
end of ty_mseg.
types : begin of ty_rbkp,
belnr type rbkp-belnr,
gjahr type rbkp-gjahr,
bldat type rbkp-bldat,
lifnr type rbkp-lifnr,
ZUONR type rbkp-ZUONR,
RMWWR type rbkp-RMWWR,
WMWST1 type rbkp-WMWST1,
end of ty_rbkp.
types : begin of ty_bseg,
bukrs type bseg-bukrs,
belnr type bseg-belnr,
gjahr type bseg-gjahr,
buzei type bseg-buzei,
valut type bseg-valut,
wrbtr type bseg-wrbtr ,
augbl type bseg-augbl,
matnr type bseg-matnr,
lifnr type bseg-lifnr,
ebeln type bseg-ebeln,
end of ty_bseg.
types : begin of ty_rseg,
belnr type rseg-belnr,
gjahr type rseg-gjahr,
ebeln type rseg-ebeln,
ebelp type rseg-ebelp,
matnr type rseg-matnr,
bukrs type rseg-bukrs,
end of ty_rseg.
types : begin of ty_bsik,
belnr type bsik-belnr,
buzei type bsik-buzei,
DMBTR type bsik-DMBTR,
budat type bsik-budat,
shkzg type bsik-shkzg,
ebeln type bsik-ebeln,
lifnr type bsik-lifnr,
end of ty_bsik.
types : begin of ty_bsak,
belnr type bsak-belnr,
lifnr type bsak-lifnr,
ebeln type bsak-ebeln,
DMBTR_C type bsak-DMBTR,
ZUONR type bsak-ZUONR,
end of ty_bsak.
types: begin of ty_bkpf,
BELNR type bkpf-belnr,
xblnr type bkpf-xblnr,
awkey type bkpf-awkey,
end of ty_bkpf.
data: it_po type standard table of ty_po,
it_ekko type standard table of ty_ekko,
it_ekpo type standard table of ty_ekpo,
it_eban type standard table of ty_eban,
it_ekbe type standard table of ty_ekbe,
it_mseg type standard table of ty_mseg,
it_rbkp type standard table of ty_rbkp,
it_rseg type standard table of ty_rseg,
it_bseg type standard table of ty_bseg,
it_bsik type STANDARD TABLE OF ty_bsik with header line,
it_bsak type STANDARD TABLE OF ty_bsak,
it_bkpf type standard table of ty_bkpf,
wa_po type ty_po,
wa_ekko type ty_ekko,
wa_ekpo type ty_ekpo,
wa_eban type ty_eban,
wa_mseg type ty_mseg,
wa_rbkp type ty_rbkp,
wa_rseg type ty_rseg,
wa_bseg type ty_bseg,
wa_ekbe type ty_ekbe,
wa_bsik type ty_bsik,
wa_bsak type ty_bsak,
wa_bkpf type ty_bkpf.
data: it_fcat type slis_t_fieldcat_alv,
it_lshead type slis_t_listheader,
it_sort type slis_t_sortinfo_alv,
wa_fcat type slis_fieldcat_alv,
wa_lshead type slis_listheader,
wa_layout type slis_layout_alv,
wa_sort type slis_sortinfo_alv.
data :it_cl_data like table of clobjdat,
wa_cl_data like clobjdat.
data: values(10) type n.
data: value1(4) type N.
data: c_matkl type ekpo-matkl,
c_matnr type ekpo-matnr,
c_ekgrp type eban-ekgrp,
c_badat type eban-badat,
c_index type sy-tabix,
c_grmenge type mseg-erfmg,
c_low(10) type c,
c_high(10) type c,
c_date type string,
c_bukrs type ekko-bukrs,
c_WERKS type eban-WERKS.
data: gd_date(10).
DATA: V_EVENTS TYPE SLIS_T_EVENT,
WA_EVENT TYPE SLIS_ALV_EVENT.
*********Selection screen variables*********
selection-screen:begin of block b1 with frame title text-001.
select-options: s_bukrs for c_bukrs DEFAULT 'bmp1',
s_WERKS for c_WERKS,
s_matnr for c_matnr DEFAULT 'rm-01',
s_matkl for c_matkl ,
s_badat for c_badat ,"obligatory,
s_ekgrp for c_ekgrp.
parameters: ch_bal as checkbox.
selection-screen:end of block b1.
*initialization.
* PERFORM EVENT_CALL.
* PERFORM POPULATE_EVENT.
start-of-selection.
PERFORM EVENT_CALL.
PERFORM POPULATE_EVENT.
perform getdata.
perform setdata.
perform fieldcat.
perform display.
*& Form GETDATA
form getdata .
select a~BANFN
a~bnfpo
a~ekgrp
a~badat
a~KNTTP
a~PSTYP
b~ebeln
b~ebelp
b~matkl
b~matnr
b~bukrs
into corresponding fields of table it_po
from eban as a inner join ekpo as b
on a~banfn = b~banfn and
a~bnfpo = b~bnfpo AND
A~KNTTP = B~KNTTP and
a~PSTYP = b~PSTYP
where a~badat in s_badat and
a~ekgrp in s_ekgrp and
a~WERKS in s_WERKS and
b~matnr in s_matnr and
b~matkl in s_matkl and
b~bukrs in s_bukrs and
b~loekz <> 'L' and
a~loekz <> 'X'.
if it_po[] is not initial.
select ebeln
ebelp
matnr
txz01
menge
meins
netpr
peinh
banfn
bnfpo
mtart
from ekpo into table it_ekpo
for all entries in it_po
where ebeln = it_po-ebeln and
ebelp = it_po-ebelp and
loekz <> 'L'.
select banfn
bnfpo
matnr
menge
meins
from eban into table it_eban
for all entries in it_po
where banfn = it_po-banfn and
bnfpo = it_po-bnfpo and
loekz <> 'X'.
if it_ekpo[] is not initial.
select ebeln
lifnr
bedat
from ekko into table it_ekko
for all entries in it_ekpo
where ebeln = it_ekpo-ebeln.
select ebeln
ebelp
belnr
bldat
gjahr
buzei
matnr
DMBTR
shkzg
from ekbe into table it_ekbe
for all entries in it_ekpo
where ebeln = it_ekpo-ebeln and
ebelp = it_ekpo-ebelp .
*if it_ekbe-shkzg = 'H'.
**ekbe-dmbtr = ekbe-dmbtr * -1.
**ekbe-menge = ekbe-menge * -1.
*endif.
* select belnr
* gjahr
* ebeln
* ebelp
* from bseg into table it_bseg
* for all entries in it_ekpo
* where ebeln = it_ekpo-ebeln and
* ebelp = it_ekpo-ebelp.
select belnr
gjahr
ebeln
ebelp
matnr
bukrs
from rseg into table it_rseg
for all entries in it_ekpo
where ebeln = it_ekpo-ebeln and
ebelp = it_ekpo-ebelp.
endif.
if it_ekbe[] is not initial.
select mblnr
mjahr
zeile
menge
meins
ebeln
ebelp
matnr
werks
charg
from mseg into table it_mseg
for all entries in it_ekbe
where mblnr = it_ekbe-belnr and
mjahr = it_ekbe-gjahr and
zeile = it_ekbe-buzei and
bwart = '101'.
endif.
if it_rseg[] is not initial.
select belnr
gjahr
bldat
lifnr
ZUONR
RMWWR
WMWST1
from rbkp into table it_rbkp
for all entries in it_rseg
where belnr = it_rseg-belnr.
endif.
*if it_rseg[] is not initial.
* SELECT bukrs
* belnr
* gjahr
* buzei
* valut
* wrbtr
* augbl
* matnr
* lifnr
* ebeln
* INTO TABLE it_bseg
* FROM bseg
* FOR ALL ENTRIES IN it_rseg
* WHERE bukrs = it_rseg-bukrs and ebeln = it_rseg-ebeln and mwskz = ''.
*endif.
*loop at it_BKPF into wa_BKPF.
* values = wa_rbkp-belnr.
* value1 = wa_rbkp-gjahr.
data: aekey_1 type string .
*CONCATENATE values value1 into aekey_1.
* if it_BSEG[] is not initial.
*MESSAGE aekey_1 type 'I'.
SELECT single belnr xblnr awkey into wa_bkpf
from bkpf
where awkey = aekey_1.
SELECT SINGLe belnr
buzei
dmbtr
budat
shkzg
ebeln
lifnr
FROM bsik
INTO CORRESPONDING FIELDS OF wa_bsik
*FOR ALL ENTRIES IN it_bseg
WHERE
bukrs in s_bukrs and
lifnr = wa_rbkp-lifnr
and
*AND gjahr = it_bseg-gjahr
* AND
belnr = wa_bkpf-belnr.
insert wa_bsik into table it_bsik.
CLEAR wa_bsik.
CLEAR it_bsik.
*endloop.
* and ebeln = it_bseg-ebeln .
* select BELNR
** SHKZG
** DMBTR
* from bkpf into table it_bkpf
* for ALL ENTRIES IN it_rbkp
* where belnr = it_rbkp-belnr.
* ENDif.
IF IT_bseg[] IS NOT INITIAL.
select belnr
LIFNR
ebeln
DMBTR
ZUONR
from bsik into table it_bsik
for all entries in it_bseg
where belnr = it_bseg-belnr.
select belnr
LIFNR
ebeln
DMBTR
ZUONR
from bsak into table it_bsak
for all entries in it_bseg
where belnr = it_bseg-belnr.
ENDIF.
else.
message s002.
leave list-processing.
endif.
endform. " GETDATA
*& Form SETDATA
form setdata .
clear wa_po.
loop at it_po into wa_po.
c_index = sy-tabix.
********Calculate PR Quantity**********
clear wa_eban.
read table it_eban into wa_eban
with key banfn = wa_po-banfn
bnfpo = wa_po-bnfpo.
if sy-subrc eq 0.
move:wa_eban-menge to wa_po-menge,
wa_eban-meins to wa_po-meins.
endif.
********Calculate PO Quantity**********
clear wa_ekpo.
read table it_ekpo into wa_ekpo
with key banfn = wa_po-banfn
bnfpo = wa_po-bnfpo .
if sy-subrc eq 0.
move:wa_ekpo-txz01 to wa_po-txz01,
wa_ekpo-netpr to wa_po-netpr,
wa_ekpo-peinh to wa_po-peinh,
wa_ekpo-mtart to wa_po-mtart,
wa_ekpo-menge to wa_po-menge1,
wa_ekpo-meins to wa_po-meins1.
endif.
********Calculate Balance Quantity******
clear wa_mseg.
loop at it_mseg into wa_mseg
where ebeln = wa_po-ebeln and
ebelp = wa_po-ebelp.
c_grmenge = c_grmenge + wa_mseg-menge.
endloop.
move:wa_mseg-mblnr to wa_po-mblnr,
c_grmenge to wa_po-menge2,
wa_mseg-meins to wa_po-meins2,
wa_mseg-werks to wa_po-werks,
wa_mseg-charg to wa_po-charg.
wa_po-balqty = wa_eban-menge - c_grmenge.
clear : wa_rseg,wa_rbkp.
read table it_rseg into wa_rseg with key
ebeln = wa_mseg-ebeln
ebelp = wa_mseg-ebelp.
read table it_rbkp into wa_rbkp
with key belnr = wa_rseg-belnr
gjahr = wa_rseg-gjahr.
if sy-subrc eq 0.
move : wa_rbkp-belnr to wa_po-belnr,
wa_rbkp-bldat to wa_po-bldat,
wa_rbkp-RMWWR to wa_po-RMWWR,
WA_RBKP-WMWST1 TO WA_PO-WMWST1.
endif.
read table it_bseg into wa_bseg with key
ebeln = wa_rseg-ebeln
bukrs = wa_rseg-bukrs.
if sy-subrc eq 0.
move wa_bseg-belnr to wa_po-belnr_d.
endif.
* read table it_bkpf into wa_bkpf
* with key belnr = wa_ekbe-belnr.
* read table it_bseg into wa_bseg
* with key belnr = wa_bkpf-belnr.
CLEAR wa_bsik.
clear it_bsik.
read table it_bsik into wa_bsik
with key belnr = wa_bkpf-belnr.
* if wa_bsik-shkzg = 'H'.
* wa_bsik-DMBTR = wa_bsik-DMBTR * 1.
* endif.
if sy-subrc eq 0.
move : wa_bsik-belnr to wa_po-belnr,
wa_bsik-DMBTR to wa_po-DMBTR.
endif.
* clear wa_bsik.
* read table it_bsik into wa_bsik
* with key belnr = wa_bseg-belnr.
* if sy-subrc eq 0.
* move : wa_bsik-DMBTR to wa_po-DMBTR.
* endif.
*clear wa_bsak.
* read table it_bsak into wa_bsak
* with key belnr = wa_bseg-belnr.
* if sy-subrc eq 0.
* move : wa_bsak-DMBTR_C to wa_po-DMBTR_C.
* endif.
*clear : wa_rbkp.
*loop at it_bsik into wa_bsik.
*read table it_bsik into wa_bsik with key belnr = wa_rbkp-belnr.
*if sy-subrc eq 0.
* move : wa_bsik-DMBTR to wa_po-DMBTR.
* endif.
*endloop.
*********Assign Vendor,PO Date*********
clear wa_ekko.
read table it_ekko into wa_ekko
with key ebeln = wa_po-ebeln.
if sy-subrc eq 0.
move:wa_ekko-lifnr to wa_po-lifnr,
wa_ekko-bedat to wa_po-bedat.
endif.
*clear wa_ekko.
*read table it_ekko into wa_ekko
*with key lifnr = wa_po-lifnr.
*if sy-subrc eq 0.
* move: wa_bsik-DMBTR to wa_po-DMBTR.
* endif.
* call function 'ZSD_BATCH_CLASSIFICATION_DATA'
* exporting
** ch_charg = wa_po-charg
* ch_matnr = wa_po-matnr
* ch_werks = wa_po-werks
* tables
* cl_data = it_cl_data
** I_SEL_CHARACTERISTIC =
loop at it_cl_data into wa_cl_data.
if wa_cl_data-ausp1 ne '?'.
if wa_cl_data-atnam eq 'THICKNESS'.
move wa_cl_data-ausp1 to wa_po-thick.
elseif wa_cl_data-atnam eq 'LENGTH'.
move wa_cl_data-ausp1 to wa_po-length.
elseif wa_cl_data-atnam eq 'WIDTH'.
move wa_cl_data-ausp1 to wa_po-width.
elseif wa_cl_data-atnam eq 'GRADE'.
move wa_cl_data-ausp1 to wa_po-grade.
endif.
endif.
endloop.
modify it_po from wa_po index c_index.
clear :c_grmenge,wa_po,wa_ekpo,wa_mseg,c_index.
endloop.
endform. " SETDATA
*& Form FIELDCAT
* text
* --> p1 text
* <-- p2 text
form fieldcat .
perform buildfields using '1' 'BANFN' 'IT_PO' 'PR Number' '' ''.
* perform buildfields using '2' 'BNFPO' 'IT_PO' 'PR Item Number' '' ''.
perform buildfields using '2' 'KNTTP' 'IT_PO' 'A/c Assignment Cat' '' ''.
perform buildfields using '2' 'PSTYP' 'IT_PO' 'Item Cat' '' ''.
perform buildfields using '3' 'EKGRP' 'IT_PO' 'Purchase Group' '' ''.
perform buildfields using '4' 'BADAT' 'IT_PO' 'Request Date' '' ''.
perform buildfields using '5' 'MENGE' 'IT_PO' 'PR Quantity' 'X' ''.
perform buildfields using '6' 'MEINS' 'IT_PO' 'PR Unit' '' ''.
perform buildfields using '7' 'LIFNR' 'IT_PO' 'Vendor Number' '' ''.
perform buildfields using '8' 'EBELN' 'IT_PO' 'Purchasing Doc No' '' '' .
perform buildfields using '9' 'BEDAT' 'IT_PO' 'PO Date' '' ''.
perform buildfields using '10' 'MTART' 'IT_PO' 'Material Type' '' ''.
perform buildfields using '11' 'MATKL' 'IT_PO' 'Material Group' '' ''.
perform buildfields using '12' 'MATNR' 'IT_PO' 'Material Number' '' ''.
perform buildfields using '13' 'TXZ01' 'IT_PO' 'Material Desc' '' ''.
perform buildfields using '18' 'MENGE1' 'IT_PO' 'PO Quantity' 'X' ''.
perform buildfields using '19' 'MEINS' 'IT_PO' 'PO Unit' '' ''.
perform buildfields using '20' 'NETPR' 'IT_PO' 'Net Price' '' ''.
perform buildfields using '21' 'PEINH' 'IT_PO' 'Price Unit' '' ''.
perform buildfields using '22' 'MBLNR' 'IT_PO' 'GR Number' '' ''.
perform buildfields using '23' 'MENGE2' 'IT_PO' 'GR Quantity' 'X' ''.
perform buildfields using '24' 'MEINS2' 'IT_PO' 'GR Unit' '' ''.
perform buildfields using '25' 'BELNR' 'IT_PO' 'Invoice doc. number' '' ''.
perform buildfields using '26' 'BLDAT' 'IT_PO' 'Invoice Date' '' ''.
* perform buildfields using '26' 'BELNR_D' 'IT_POP' 'A/C Doc. No.' '' ''.
* perform buildfields using '26' 'AUGBL' 'IT_PO' 'Clearing Doc No.' '' ''.
perform buildfields using '26' 'DMBTR' 'IT_PO' 'OPEN AMOUNT' '' ''.
perform buildfields using '26' 'DMBTR' 'IT_PO' 'clear AMOUNT' '' ''.
* perform buildfields using '26' 'DMBTR_C' 'IT_PO' 'Clear balance' '' ''.
if ch_bal = 'X'.
perform buildfields using '27' 'BALQTY' 'IT_PO' 'Balance Quantity'
'X' ''.
endif.
perform buildfields using '26' 'WMWST1' 'IT_PO' 'TOTAL TAX ADDED' 'X' ''.
perform buildfields using '26' 'RMWWR' 'IT_PO' 'TOTAL AMOUNT IN INVOICE' 'X' ''.
endform. " FIELDCAT
*& Form BUILDFIELDS
* text
* -->P_0449 text
* -->P_0450 text
* -->P_0451 text
* -->P_0452 text
form buildfields using value(p_col_pos) like sy-cucol
value(p_fldname) type slis_fieldname
value(p_tabname) type slis_tabname
value(p_reptext) like dd03p-reptext
value(p_do_sum) type char1
value(hotspot) type char1.
wa_fcat-col_pos = p_col_pos.
wa_fcat-fieldname = p_fldname.
wa_fcat-tabname = p_tabname.
wa_fcat-reptext_ddic = p_reptext.
wa_fcat-do_sum = p_do_sum.
wa_fcat-hotspot = hotspot.
append wa_fcat to it_fcat.
clear wa_fcat.
endform. " BUILDFIELDS
*& Form DISPLAY
form display .
clear wa_layout.
wa_layout-zebra = 'X'.
wa_layout-colwidth_optimize = 'X'.
* wa_layout-box_fieldname = 'SEL'.
* wa_layout-edit = 'X'.
perform build_sort using 'BANFN' '1' 'X'.
call function 'REUSE_ALV_GRID_DISPLAY'
exporting
* I_INTERFACE_CHECK = ' '
* I_BYPASSING_BUFFER = ' '
* I_BUFFER_ACTIVE = ' '
i_callback_program = sy-cprog
* I_CALLBACK_PF_STATUS_SET = ' '
I_CALLBACK_USER_COMMAND = 'USER_COMMAND '
i_callback_top_of_page = 'TOP_OF_PAGE'
* I_CALLBACK_HTML_TOP_OF_PAGE = ' '
* I_CALLBACK_HTML_END_OF_LIST = ' '
* I_STRUCTURE_NAME =
i_background_id = 'ALV_BACKGROUND'
* I_GRID_TITLE =
* I_GRID_SETTINGS =
is_layout = wa_layout
it_fieldcat = it_fcat
* IT_EXCLUDING =
* IT_SPECIAL_GROUPS =
it_sort = it_sort
* IT_FILTER =
* IS_SEL_HIDE =
* I_DEFAULT = 'X'
I_SAVE = 'A'
* 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_po[]
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.
endform. " DISPLAY
*& Form top_of_page
* text
form top_of_page. "#EC *
**********Create report header*********
refresh it_lshead.
clear wa_lshead.
**********To display date in header*********
* write: s_badat-low to c_low dd/mm/yyyy,s_badat-high to c_high
* dd/mm/yyyy.
* if s_badat-high is initial.
* concatenate 'Dated on' c_low into c_date separated by space.
* else.
* concatenate 'Dated between' c_low 'and' c_high into c_date separated
* by space.
* endif.
wa_lshead-typ = 'H'.
wa_lshead-info = 'PR To Payment History'.
* 'Pending Indents History -We had a requirement to retrieve "aging of receiveables" by customer. Basically, it goes thru each record and depending on the due date places the amounts in the following buckets (example). 0-30 day Overdue, 31-60 days Overdue, 61-90 days overdue, 30+ days overdue, 60+ days overdue) etc all the way to 6+ years overdue.
There are also cooresponding buckets for coming due analysis. For example, what is: 0-30 days coming due, 31-60 days coming due, 30+ days coming due, etc...
To do this, first I needed to be able be able to produce an open items statement at any given time in the past. Now, this seems impossible because of how the items go from open to cleared all the time. And an item that was open one month ago, may not be open anymore.
What I did was first remove any selections on item status. Then compare the posting date with teh key date in the past, if the posting date is less than or equal to the key date, keep the record.
Then compare the clearing date with the key date. First, keep all that are #. (This keeps all records still open from that posting date/key date)
Then, add another check for all items that were cleared after the key date (GT Key Date). This gives you the open items on that date.
Hope that makes sense. Let me know if you want clarification.
/smw -
Error in creation of custom PD infotype
Hi,
I have a task of creating a custom PD infotype(p9xxx). I created HRI9xxx structure with all the custom fields and when I try to create the infotype using tcode PPCI(selected 'field infotype' option and create button in the 'infotype' block was pressed), it gives an error message that p9xxx-begda is not in ABAP dictionary and then it gives me list of screens, module pools and tables created. This custom infotype entry does not exist in T777I. I have tried regenerating it and same problem persists. If anyone knows the solution, please do let me know.
Thanks in advanceSolved.
Maybe you are looking for
-
My firefox webpage now opens up as a whole page and I am not able to see any any menu bars
All of a sudden my firefox webpage now opens in the whole window and I am not able to see any menu bars in the top or the "start" icon in the bottom of the screen
-
Itunes 10.5 and 11 cant identify my iphone 4s
i dont know what happened. my 4s was charging via usb in my computer. itunes usually starts up when my pc identifies my 4s. this time, my 4s was charging but itunes didnt start so i unplugged my 4s and plugged again. nothing happened. i updated itune
-
I understand the software update for ATV will not be out for a few weeks. However, does anyone know whether a rented movie today from iTunes will still stream to ATV (without the software update)? Thanks
-
Help. When will I get my downlosd???????
-
Best method to subtly remove scuff marks from white floor in a pic?
I shot a model in a studio using a white backdrop. The backdrop under her feet is all scuffed up with marks. These marks are in a shadowed area, so I cannot just clone stamp clean areas from the background, since that is lighter and without shadow. N