Trace Global Sequenz in BPS
Hi at All,
I´m looking for a possibility to trace an Global Sequenz in BPS!? I would know, which function in the Local Sequenzes under my Global Sequenz is a performance killer... Any ideas? Thx.. a lot!
BR David
After running the global planning sequence, you can observe the statistics in BPS_STAT0 transaction which gives the time taken for each function inside the sequence.
Similar Messages
-
Using global exits from BPS in IP
Do you know if the global exit routines used for validation and derivation that are used in BPS can be used in IP?
They are:
exit_sapupc_services__001 & 002
Thanks
TimHi Tim,
there is no standard functionality to call these exits. I definitely recommend to migrate to the characteristic relationships. Much of the ABAP coding should be reusable so it's cut&paste with some new coding to fit it to the new ABAP class-based exits.
Regards,
Marc
SAP NetWeaver RIG -
How to check if BIA has effect on a BPS function
Dear Experts,
As I know BIA can also improve DB read time (data selection) when performing a BPS function. Currently we are using a BIA test installation to see if it will help us. We have some BPS function with long data selection times.
I know created BIA indexes on all involved real time cubes. By just executing the concerned BPS functions I can see no effect. I now want to check if the BPS functions do access the BIA at all. For queries this is quite easy to check with RSRT.
So my question is:
Is there any tool available to check wether BIA is used by a BPS function or not? Some kind of RSRT for BPS.
Thanks & Regards,
Ulrich MeierHi Jens,
Thanks. I tried this. Strange result is that I get no data in that trace when running a BPS function. I do get data when running that trace during execution of a query which runs on the same InfoCubes as the planning function.
In the meantime I found table RSDDSTATBIAUSE which gets updated each time a InfoProvider is accessed if it has a BIA Index. Here my InfoProviders get a +1 in field BIA_USED when accessing them with the BPS function.
Furthermore I came across OSS-Note 990000 and installed the latest version of report ZBPPOBPS70 (I already knew that from BW 3.5). Here I found that field 'BW:Used Aggregate' is not populated, although within the coding of ZBPPOBPS70 there is indication that it should either show the used aggregate or BIA Index. The data is read from table RSDDSTATDM field AGGREGATE. There I found entries in AGGREGATE for 'normal' query calls but none for BPS calls.
With alll that in mind I'm more and more confused...
Regards,
Ulrich -
Global variable in as3.0
I am doing something with flash cs3,I need to use global
variable in it ,but there is not global variable in as3.0,can
anyone help me ,thanks forever!There is no global in AS3. But you can make values globally
accessible by
using static fields in classes. e.g.
// MyClass.as
package
public class MyClass
public static var globals = new Object();
MyClass.globals["hello"] = "world"
trace(MyClass.globals.hello);
// and if you want to simulate something a little
// closer to the AS2 _global object you can drop
// this into a top level in your class path
// global.as
package
public const global:Object = new Object();
global["hello"] = "world";
trace(global.world) -
Question on a safari symptom that implies dns wierdness
This question is posted here because to problem shows up best in Safari. However, as I understand the process, I do not believe the core of the problem is specifically Safari.
When I try to browse to a nonexistant domain (for example, typing in xyzzy.apple.com into Safari's browser), I am shown a Network Solutions page which reads among other things:
This Site Is Under Construction and Coming Soon.
This Domain Is Registered with Network Solutions
It's not as robust as the usual Network Solutions Under construction page.
A screen shot of this can be seen at
http://www.notnap.com/browsing/UnderConstruction.png
I also get this when I type in partial urls. For example, if I simply type in ford to the address bar in Safari, I get the same page. Once upon a time, the browser would assume I meant to add a .com to the end of the url if I did not do so. While showing as a sign of laziness, I must admit I like this "feature."
I NEVER see the standard Safari page saying "Safari can't find the page you are looking for."
Some details:
- Network consists of a DSL connection to Verizon.
DSL modem - Linksys router = iMac G5, iMac G3
Router is connecting to modem via PPPoE
Router is configuring local network (192.168.1.x) via DHCP
- I see the same results from IE5 on the OS9 Imac G3
- I know I did not have these results until recently. Recent changes include:
- upgrading firmware on linksys
- changing internal network range from 192.0.1.x (wsa a typo) to 192.168.1.x
Here is my thinking:
There are two "problems" going on here.
1) I'd like the browser address bar to assume I mean .com when I do not include a standard TLD
2) I'd like to know how Network Solutions is rerouting my browser when my dns resolver falis to find an ip when searching on behalf of my browser.
(1) is admitedly a behavioral preference.
(2) is getting me worried. Doesn't this mean some local process is doing this?
Here's a simplification of the entire process as I understand how dns and web browsing works...
1) In Safari, I enter a bogus url domain, like "xyzzy.apple.com"
2) the Safari process realizes I have not entered an IP number, and goes to the network stack in search of my dns resolver
3) I've entered no custom host information, so the dns resolver on my system must go to whatever dns servers I have configured for use on my ethernet connection. (The only active connection, by the way). There are two dns servers, both in Verizon's space (they are my ISP)
4) My system makes a query on port 53 to their first server. Let's assume they are playing by the rules and not proxying without my knowledge. Let's also assume there is nothing in their dns server cache for xyzzy.apple.com. After all, why should there be? Finally, let's assume their dns servers are recursive.
5) Their dns server checks it's cache and realizes it has nothing for xyzzy.apple.com. It also quickly realizes it has no zone for apple.com, so it goes out on the quest. It hits the root servers, gets directed to the GTLD-SERVERS, gets directed to nserver.apple.com, which finally answers no such host.
6) Verizon's dns server tells my computer's dns resolver no such host
7) My computers dns resolver tells Safari no such host
8) Safari should display the typical site not found page.
As far as I can tell, when I do the search from a purely dns query standpoint, I get the expected results. Here's a clip from the terminal. Comments in italics:
xxxxx:~ xxxxx$ cat /etc/resolv.conf
domain xxx.com
search xxx.com
nameserver 141.154.0.68
nameserver 151.203.0.84
........these are the correct names servers as provided by my isp........
xxxxxx:~ xxxxxx$ dig @141.154.0.68 xyzzy.apple.com +trace
; <<>> DiG 9.2.2 <<>> @141.154.0.68 xyzzy.apple.com +trace
;; global options: printcmd
. 197789 IN NS C.ROOT-SERVERS.NET.
.........skipping a bit.........
. 197789 IN NS B.ROOT-SERVERS.NET.
;; Received 436 bytes from 141.154.0.68#53(141.154.0.68) in 55 ms
com. 172800 IN NS A.GTLD-SERVERS.NET.
.........skipping a bit.........
com. 172800 IN NS M.GTLD-SERVERS.NET.
;; Received 493 bytes from 192.33.4.12#53(C.ROOT-SERVERS.NET) in 40 ms
apple.com. 172800 IN NS nserver.apple.com.
apple.com. 172800 IN NS nserver.asia.apple.com.
apple.com. 172800 IN NS nserver.euro.apple.com.
apple.com. 172800 IN NS nserver2.apple.com.
apple.com. 172800 IN NS nserver3.apple.com.
apple.com. 172800 IN NS nserver4.apple.com.
;; Received 274 bytes from 192.5.6.30#53(A.GTLD-SERVERS.NET) in 34 ms
apple.com. 86400 IN SOA nserver.apple.com. hostmaster.apple.com. 2006032800 1800 900 2016000 86500
;; Received 88 bytes from 17.254.0.50#53(nserver.apple.com) in 94 ms
In other words, it got what you'd expect - the host does not exist.
So what I want to know is, how is it that Safari is set to shown a Network Solutions page instead of the default Server not Found page? As far as I can tell, that page is not on my system, so Safari must be retrieving it from elsewhere.
But how? When the local process trying to resolve the bogus host xyzzy.apple.com is dig, host, nslookup or the like, I get the correct host not found. How then is that information being changed between my local dig process and the safari process, so that Safari then shows the Network Solutions page? Remember that the only processes which "know" this query was originated by a browser and not by a dns utility like dig are local to my box. So, how can this substitution be done without local access?
Wouldn't this imply a local security problem?
I've tried (although I cannot imagine how some of these would affect a resolution):
- Reset Safari
- emptying cache and history
- manually entering the dns information in system prefs (allowing the system to be configured via dhcp does work - according to network utils, the dns info is there - but they do not show up in the network prefs panel.
- adding ".com" "com" or a few other variations to the default domain in the network prefs.
- Deleting Safari's prefs (~/Library/Safari/)
I did find some discussion about something similar from back around 2002 complaining that similar action could potentially cause host verification problems for email servers and the like. Though, I'd guess most of these kinds of verifications would be for the reverse lookups. Still, I dould not find an exmplanation of how it was done, or more importantly, how to stop it, short of petitioning the ISP's to upgrade their version of BIND.
I'd love to be able to stop this annoying free ad for Network Solutions from appearing whenever I'm wither lazy or sloppy typing in the url. But more importantly, I want to know how this process works. The fact I see similar results on my OS9 ImacG3 strongly implies I'm not looking at a security issue - it's unlikely my conclusion there is a local process intercepting the dns results between my resolver process and my safari process is correct, as the same thing seems to be happening there as well. But I gotta know. How is this happening? How did Network Solutions do this?What you're describing sounds suspiciously like
VeriSign's SiteFinder from ... the
fall of 2003, which is when it was up and running.
That's one thing I did find from my searches. What I didn't find was an understanding of how they did it then, and by inference how they're doing it now, assuming we're seeing a recurrance.
I find thousands of similar hits by searching on the text in the page, though it's unclear how many of these are legit - some of these pages are truthful. Hitting xyzzy.apple.com and being told "This Domain Is Registered with Network Solutions" is another matter entirely.
This looks like your page doesn't it:
http://underconstruction.networksolutions.com/
You know what would be interesting? The output of
this Terminal command:
curl -I
http://xyzzy.apple.comSee what headers get
returned from whatever server is answering the
call...
I'll do you one better... from terminal:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
notnAP:~ notnap$ curl -Iv http://www.apple.com
* About to connect() to www.apple.com port 80
* Trying 17.112.152.32... * connected
* Connected to www.apple.com (17.112.152.32) port 80
HEAD / HTTP/1.1
User-Agent: curl/7.13.1 (powerpc-apple-darwin8.0) libcurl/7.13.1 OpenSSL/0.9.7i zlib/1.2.3
Host: www.apple.com
Pragma: no-cache
Accept: /
< HTTP/1.1 200 OK
HTTP/1.1 200 OK
< Age: 7
Age: 7
< Date: Fri, 31 Mar 2006 03:13:09 GMT
Date: Fri, 31 Mar 2006 03:13:09 GMT
< Content-Length: 30692
Content-Length: 30692
< Content-Type: text/html
Content-Type: text/html
< Expires: Fri, 31 Mar 2006 03:18:09 GMT
Expires: Fri, 31 Mar 2006 03:18:09 GMT
< Cache-Control: max-age=300
Cache-Control: max-age=300
< nnCoection: close
nnCoection: close
< Server: Apache/1.3.33 (Darwin) PHP/4.3.10
Server: Apache/1.3.33 (Darwin) PHP/4.3.10
* Connection #0 to host www.apple.com left intact
* Closing connection #0
notnAP:~ notnap$ curl -Iv http://xyzzy.apple.com
* About to connect() to xyzzy.apple.com port 80
* Trying 216.168.224.70... * connected
* Connected to xyzzy.apple.com (216.168.224.70) port 80
HEAD / HTTP/1.1
User-Agent: curl/7.13.1 (powerpc-apple-darwin8.0) libcurl/7.13.1 OpenSSL/0.9.7i zlib/1.2.3
Host: xyzzy.apple.com
Pragma: no-cache
Accept: /
< HTTP/1.1 200 OK
HTTP/1.1 200 OK
< Server: Sun-ONE-Web-Server/6.1
Server: Sun-ONE-Web-Server/6.1
< Date: Fri, 31 Mar 2006 02:59:12 GMT
Date: Fri, 31 Mar 2006 02:59:12 GMT
< Content-type: text/html
Content-type: text/html
* Connection #0 to host xyzzy.apple.com left intact
* Closing connection #0
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
I'll save you the trouble:
VeriSign Infrastructure & Operations NSI-NETBLK1 (NET-216-168-224-0-1)
216.168.224.0 - 216.168.255.255
Network Solutions, Inc. NETSOL-SWIP-216-168-224 NET-216-168-224-0-2)
216.168.224.0 - 216.168.224.255
So what does it mean, and can anyone tell me how they're doing this? I hate not understanding how this is being done, and it directly proves my understanding of dns and the network stack on my iMacs is wrong, or at least incomplete. Inconceivable! -
Set a default layout for all users via DIAPI
Hello everyone,
I am attempting to set a default report for all users/business partners using the DI-API.
I can accomplish this in the B1 application via Tools> Layout Designer...>Set as Default
If there are entries in the RDFL table for this layout, I am prompted to delete these entries and set this layout as the default for all users/BP's
Based on the SDK Documentation, the following code should accomplish the same thing via the DI-API
(stripped down for clarity)
Dim oDefaultReportParams As DefaultReportParams
oDefaultReportParams = oLayoutService.GetDataInterface(ReportLayoutsServiceDataInterfaces.rlsdiDefaultReportParams)
oDefaultReportParams.LayoutCode = sMyLayoutCode
oDefaultReportParams.ReportCode = sMyReportCode
Me.oLayoutService.SetDefaultReport(oDefaultReportParams)
Code executes fine, but it doesn't have the expected impact on settings. The above code adds an entry to the RDFL table rather than changing the DfltReport field in the RTYP table like I expected, so instead of setting the default report globally for all bps/users, its adding an entry to the RDFL table to set the value for a specific user/bp
I experimented by including and setting the following properties to every combination I could think of with the same results
oDefaultReportParams.UserID = 'tried 1, 0, -1
oDefaultReportParams.CardCode = 'tried "", "0", "-1"
Am I misunderstanding the API, or using the wrong objects/calls...? If all else fails I could accomplish this via the UI-API instead, but the application was intended to be a stand alone app that didn't rely on SAP B1 application running, so any help or suggestions would be much appreciated.
Thanks!Hi,
Please repost at SDK forum to get quick response. Close this thread here with helpful answer.
Thanks. -
I have a dynamic text instance in Flash named dynamic_txt and
I want it to display information from a php file. What command
allows me to do this? Here is the code:
PHP
<?php
print "dynamo_txt=DYNAMIC";
?>
ActionScript (2.0)
var my_lv:LoadVars = new LoadVars();
my_lv.onLoad = function(success:Boolean) {
if (success) {
//HERE IS WHERE I WANT THE COMMAND THAT WILL ALLOW DYNAMO_TXT
TO DISPLAY THE STRING //FROM THE PHP FILE
my_lv.load("cars.php");Read my threads - you use LoadVars and put value-pairs into
an array.
Unfortunately, it was answered in AS 1.0/2.0 forum, not here
so perhaps you didn't find it.
//sqlcache
/* fyi you can always create some valid test data locally by
doing something like this:
var mytest:LoadVars=new LoadVars();
mytest.keyword10="keyword1"
mytest.keyword11="organelle"
mytest.keyword12="photosynthesis"
mytest.keyword13="digestion"
mytest.keyword14=""
mytest.keyword15=""
trace(mytest.toString())
var my_lv:LoadVars = new LoadVars();
my_lv.onLoad = function (success:Boolean):Void {
if (success) {
//assuming _global.keywords is already defined as an array:
//assuming _global.keywords might already have some keywords
in it (otherwise this could be simpler)
//create a temporary array:
var tmpkeywords:Array =[];
// Iterate over properties in my_lv
for (var prop in my_lv) {
if (typeof(my_lv[prop])=="string"){
tmpkeywords.push(my_lv[prop]);
trace("loaded in this order:"+tmpkeywords); //it is reversed,
so:
tmpkeywords.reverse(); //turn it around
trace("reversed:"+tmpkeywords);
//now assuming that the _global.keywords is already an array
with some words... and we want to
//add to the end:
//the following 'function.apply' method lets the 'push'
method take the elements of tempwords as an array an adds them
individually
_global.keywords.push.apply(_global.keywords,tmpkeywords);
trace("global keywords now has:"+_global.keywords)
} else {
trace("Unable to load external file.");
//make _global.keywords an array for testing:
_global.keywords=["hello","world"];
trace("global keywords starts with:"+_global.keywords)
my_lv.load("sqlcache.txt");
//sqlcache.txt
GWD
User is offline
View Profile
Senior Member Posts: 1927
Joined: 06/24/2002
Send Private Message
03/11/2008 05:30:13 AM
Reply | Quote | Top | Bottom
You wouldn't usually want to or need to load the same data in
twice.
I checked the link to your swf and I couldn't see it
attempting to load any external data via http activity. So I don't
think this code is running in your full swf (or perhaps it's only
after signing in etc?)
Also, LoadVars automatically calls its own decode method by
default, so you do not need to use 'decode' in the onLoad handler.
Here's something which might help. Hopefully the comments
etc, explain a little bit. The function.apply line is probably the
one that might be a little difficult to comprehend. Its only there
as a quick way to append the values to the _global.keywords array
(assuming that you want append them). -
News: JDBInsight 2.1EA 40 - XA Transaction Performance Analysis
JInspired has made available a new Early Access milestone build which previews its XA transaction analysis. JDBInsight is the only product on the market providing true in-depth JDBC resource transaction analysis in a J2EE environment. With its new XA support developers and architects can trace global transactions across multiple JDBC datasources. Also the XA support ensures insight into database activity can still be obtained for transactions involving other external technology resources - JCA and JMS.
Downloads and supporting release notes are available at: http://www.jinspired.com/products/jdbinsight/downloads/index.html
To see why JDBInsight was recently voted "The Best Java Application Monitoring Tool" in the JDJ Readers Choice Awards take our Flash product tour online:
Demo 1 : Servers and Clusters
http://www.jinspired.com/products/jdbinsight/video1.html
Demo 2 : Transaction Analysis
http://www.jinspired.com/products/jdbinsight/video2.html
Demo 3 : Call Tracing
http://www.jinspired.com/products/jdbinsight/video3.html
Demo 4 : JDBC Resource Leaks
http://www.jinspired.com/products/jdbinsight/video4.html
Demo 5 : SQL Statements
http://www.jinspired.com/products/jdbinsight/video5.html
About JDBInsight
JDBInsight is an innovative enterprise development product, aimed at simplifying the performance tuning and testing of J2EE applications, which access data through the Java Database Connectivity (JDBC) API. JDBInsight analyses the access of enterprise data by J2EE client-, web-, and bean containers. The analysis can encompass transaction executions, from multiple J2EE containers. JDBInsight captures timing and execution information for enterprise data accessed by Servlets, JavaServer Pages, Session- and Entity Beans using JDBC or an Entity Bean using a container's persistence engine. JDBInsight can also profile non-J2EE applications that access enterprise data through the JDBC API.
About JInspired
JInspired located in Ireland and The Netherlands, delivers JDBInsight, a comprehensive solution for Application Performance Tuning and Testing that focuses directly on early identification within the development and testing lifecycle. Jinspired offers sophisticated analytical tools, that capture transactional behaviour and performance timing information, across multiple containers in a single console, and presents this information intuitively to the user "Visualizing the Invisible.Thank you very much, I am looking from now for a good performance Tuning book writen by Jonathan Lewis. I dont think Jonathan can come to Spain and give lessons...Anyway I will email to him...
But, could you please clarify 2 points to me
1- Should I modify manually memory parameters like buffer cache, shared pool, large pool etc...if those areas are spotted Small and areas causes of performace problem in the AWR, ADDM or ASH reports even if the memory is automatic managed ?
In the case of yes, Why Oracle named it "Memory automatic managed" if I have to set some values of memory manually ?
2- When ADDM report suggests me to increase the SGA size; from where ADDM got this recomandation?. I mean is it recomandation based on statistics collected of Both Oracle and OS ? I am asking this question because, from our report I ran 3 weeks ago, ADDM suggested me to increase the SGA to 10GB (total memeory of the serve is 16GB), I did the change and from that moment the server is SWAP... and now ADDM report suggests me again to increase the SGA to 12GB .
Best reagards -
Dynamically Create Repeater Element in ActionScript
Hi,
I'm trying to dynamically create a repeater control with an
image and a label control. I can do it directly in the MXML file
but when I try and covert it into ActionScript it's not working.
Can anyone see what the problem is with my code?
public function GetPalettes():void{
removeChild(document.FrontPage);
Palettes.method = "GET";
params = {"method": "GetPalettes", "BodyPartNo":
document.PalettesMenu.selectedItem.@partNo};
Palettes.cancel();
Palettes.send(params);
var VerticalBox:VBox = new VBox();
VerticalBox.x = 10;
VerticalBox.y = 10;
VerticalBox.id = "VerticalBox";
var PaletteRepeater:Repeater = new Repeater();
PaletteRepeater.dataProvider =
"{Palettes.lastResult.Palette}";
PaletteRepeater.startingIndex = 0;
PaletteRepeater.id = "PaletteRepeater";
var PaletteImage:Image = new Image();
PaletteImage.setStyle("HorizontalAlign", "left");
PaletteImage.source = "
http://localhost/Flex/Personalised%20Palettes-debug/{PaletteRepeater.currentItem.@PictureS rc}Med.png";
PaletteImage.useHandCursor = true;
PaletteImage.buttonMode = true;
PaletteImage.mouseChildren = false;
PaletteImage.id = "PaletteImage";
var PaletteDescription:Label = new Label();
PaletteDescription.text =
"{PaletteRepeater.currentItem.@Description}";
PaletteDescription.id = "PaletteDescription";
document.MainPage.addChild(VerticalBox);
VerticalBox.addChild(PaletteRepeater);
PaletteRepeater.addChild(PaletteImage);
PaletteRepeater.addChild(PaletteDescription);
Thanks"katychapman85" <[email protected]> wrote in
message
news:[email protected]...
> Hey Amy,
>
> I've put a thread up about this but thought I'd ask you
as well as you've
> been
> a great help to me so far.
>
> I have this function:
> public function GetOptions(Menu:int):void{
> document.MenuOptions.url =
> "
http://localhost/Flex/Personalised%20Palettes-debug/MenuOptions.php?Menu=";
> document.MenuOptions.url += Menu;
> document.MenuOptions.send();
> }
>
> What I'm trying to do is when a user clicks on a Radio
button this
> function is
> called and the number of the Menu required is sent to
the function.
>
> I've added this Event Listener to my Radio Button:
>
>
document.RadioButtons2.addEventListener(MouseEvent.CLICK,
> function():void{GetOptions(2);});
>
> However, it's not working. Everything I've read suggests
using an
> anonymous
> function in the Event Listener to pass the menu
parameter but for some
> reason
> it's not working.
What version of Flex are you using? The Help for Flex 3 has
this to say:
http://www.adobe.com/livedocs/flex/3/html/help.html?content=events_05.html
Defining event listeners inline
The simplest method of defining event handlers in Flex
applications is to
point to a handler function in the component's MXML tag. To
do this, you add
any of the component's events as a tag attribute followed by
an ActionScript
statement or function call.
You add an event handler inline using the following syntax:
<mx:tag_name event_name="handler_function"/>
For example, to listen for a Button control's click event,
you add a
statement in the <mx:Button> tag's click attribute. If
you add a function,
you define that function in an ActionScript block. The
following example
defines the submitForm() function as the handler for the
Button control's
click event:
<mx:Script><![CDATA[
function submitForm():void {
// Do something.
]]></mx:Script>
<mx:Button label="Submit" click="submitForm();"/>
Event handlers can include any valid ActionScript code,
including code that
calls global functions or sets a component property to the
return value. The
following example calls the trace() global function:
<mx:Button label="Get Ver" click="trace('The button was
clicked');"/>
There is one special parameter that you can pass in an inline
event handler
definition: the event parameter. If you add the event keyword
as a
parameter, Flex passes the Event object and inside the
handler function, you
can then access all the properties of the Event object.
The following example passes the Event object to the
submitForm() handler
function and specifies it as type MouseEvent:
<?xml version="1.0"?>
<!-- events/MouseEventHandler.mxml -->
<mx:Application xmlns:mx="
http://www.adobe.com/2006/mxml">
<mx:Script><![CDATA[
import mx.controls.Alert;
private function myEventHandler(event:MouseEvent):void {
// Do something with the MouseEvent object.
Alert.show("An event of type '" + event.type + "'
occurred.");
]]></mx:Script>
<mx:Button id="b1" label="Click Me"
click="myEventHandler(event)"/>
</mx:Application>
It is best practice to include the event keyword when you
define all inline
event listeners and to specify the most stringent Event
object type in the
resulting listener function (for example, specify MouseEvent
instead of
Event).
You can use the Event object to access a reference to the
target object (the
object that dispatched the event), the type of event (for
example, click),
or other relevant properties, such as the row number and
value in a
list-based control. You can also use the Event object to
access methods and
properties of the target component, or the component that
dispatched the
event.
Although you will most often pass the entire Event object to
an event
listener, you can just pass individual properties, as the
following example
shows:
<?xml version="1.0"?>
<!-- events/PropertyHandler.mxml -->
<mx:Application xmlns:mx="
http://www.adobe.com/2006/mxml">
<mx:Script><![CDATA[
import mx.controls.Alert;
private function myEventHandler(s:String):void {
Alert.show("Current Target: " + s);
]]></mx:Script>
<mx:Button id="b1" label="Click Me"
click="myEventHandler(event.currentTarget.id)"/>
</mx:Application>
Registering an event listener inline provides less
flexibility than using
the addEventListener() method to register event listeners.
The drawbacks are
that you cannot set the useCapture or priority properties on
the Event
object and that you cannot remove the listener once you add
it.
don't see anything in there about anonymous functions...? -
Mac OS X Leopard hates my domain address (apparently)
I've had my Mac since December and up until a few weeks ago it had no problem going to any of the websites I own. Problem now is that it refuses to go to them if I use my actual domain address. The sites are blogs that I bought domain names for, but the bookmarks I have had all along no longer work and neither does typing in the actual domain address, BUT if I type in the much longer blogspot-style address my Mac will then connect. My domain server says it's a problem with my ISP, but that doesn't make sense since I can connect with my Windows PC without issue. Why won't my Mac go to my domain names anymore???
Er, that should look like:
{quote:title=dig andmenshallcallitblog.com +trace}
; <<>> DiG 9.2.4 <<>> andmenshallcallitblog.com +trace
;; global options: printcmd
. 503490 IN NS J.ROOT-SERVERS.NET.
. 503490 IN NS K.ROOT-SERVERS.NET.
. 503490 IN NS L.ROOT-SERVERS.NET.
. 503490 IN NS M.ROOT-SERVERS.NET.
. 503490 IN NS A.ROOT-SERVERS.NET.
. 503490 IN NS B.ROOT-SERVERS.NET.
. 503490 IN NS C.ROOT-SERVERS.NET.
. 503490 IN NS D.ROOT-SERVERS.NET.
. 503490 IN NS E.ROOT-SERVERS.NET.
. 503490 IN NS F.ROOT-SERVERS.NET.
. 503490 IN NS G.ROOT-SERVERS.NET.
. 503490 IN NS H.ROOT-SERVERS.NET.
. 503490 IN NS I.ROOT-SERVERS.NET.
;; Received 420 bytes from 127.0.0.1#53(127.0.0.1) in 0 ms
com. 172800 IN NS H.GTLD-SERVERS.NET.
com. 172800 IN NS I.GTLD-SERVERS.NET.
com. 172800 IN NS J.GTLD-SERVERS.NET.
com. 172800 IN NS K.GTLD-SERVERS.NET.
com. 172800 IN NS L.GTLD-SERVERS.NET.
com. 172800 IN NS M.GTLD-SERVERS.NET.
com. 172800 IN NS A.GTLD-SERVERS.NET.
com. 172800 IN NS B.GTLD-SERVERS.NET.
com. 172800 IN NS C.GTLD-SERVERS.NET.
com. 172800 IN NS D.GTLD-SERVERS.NET.
com. 172800 IN NS E.GTLD-SERVERS.NET.
com. 172800 IN NS F.GTLD-SERVERS.NET.
com. 172800 IN NS G.GTLD-SERVERS.NET.
;; Received 499 bytes from 192.58.128.30#53(J.ROOT-SERVERS.NET) in 15 ms
andmenshallcallitblog.com. 172800 IN NS ns45.domaincontrol.com.
andmenshallcallitblog.com. 172800 IN NS ns46.domaincontrol.com.
;; Received 127 bytes from 192.54.112.30#53(H.GTLD-SERVERS.NET) in 87 ms
andmenshallcallitblog.com. 3600 IN A 64.202.189.170
andmenshallcallitblog.com. 3600 IN NS ns45.domaincontrol.com.
andmenshallcallitblog.com. 3600 IN NS ns46.domaincontrol.com.
;; Received 111 bytes from 208.109.78.91#53(ns45.domaincontrol.com) in 88 ms
{quote}
And a simple lookup with dig:
{quote:title=dig andmenshallcallitblog.com}
; <<>> DiG 9.2.4 <<>> andmenshallcallitblog.com
;; global options: printcmd
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 13078
;; flags: qr rd ra; QUERY: 1, ANSWER: 1, AUTHORITY: 2, ADDITIONAL: 2
;; QUESTION SECTION:
;andmenshallcallitblog.com. IN A
;; ANSWER SECTION:
andmenshallcallitblog.com. 1446 IN A 64.202.189.170
;; AUTHORITY SECTION:
andmenshallcallitblog.com. 1446 IN NS ns45.domaincontrol.com.
andmenshallcallitblog.com. 1446 IN NS ns46.domaincontrol.com.
;; ADDITIONAL SECTION:
ns45.domaincontrol.com. 2248 IN A 208.109.78.91
ns46.domaincontrol.com. 2248 IN A 208.109.255.23
;; Query time: 2 msec
;; SERVER: 127.0.0.1#53(127.0.0.1)
;; WHEN: Tue Aug 5 17:26:43 2008
;; MSG SIZE rcvd: 143
{quote}
It seems that the short-form is the address of a service that provides an HTTP redirect for you, so it will only work when using HTTP, and not if you have a plugin (like an Ad blocker or something) that will prevent the redirect. There's no native feature in OS X that would prevent the redirect -- unless it timed out at your ISP and your ISP gave you a bogus page rather than failed the lookup. If that's the case, you probably need to clear your browser cache. -
Hi, I think I wrote this wrong but can't find a solution.
This works:
Parts1_mc.addEventListener(MouseEvent.CLICK, RunTraining);
function RunTraining(e:MouseEvent):void
Global.run = Parts1_mc.Parts1.text;
trace(Global.run);
When I do this, I get a undefined error message:
Parts1_mc.addEventListener(MouseEvent.CLICK, RunTraining);
function RunTraining(e:MouseEvent):void
Global.run = Parts1_mc.event.target.text;
trace(Global.run);Simpler is a relative thing, so I may miss since my understanding of this is also simple (more of an acceptance than an understanding)... greater minds might prevail here with a better explanation (or possibly a more confusing one).
From what you just quoted, the simplest way of stating part of it was just as it is stated...
“currentTarget” is the Movieclip (object) that you applied the listener to.
So if you assigned the listener to Parts1_mc, the currentTarget of the event is Parts1_mc. That will not vary.
But Parts1_mc contains other objects, in your case a textfield, which is an interactive object and if interacted with will trigger the event. Since it is a child of Parts1_mc it still gets detected by the listener that is assigned to Parts1_mc.
You should go thru the explanation you linked and try to see how different elements can end up being the target under different conditions. That same link is where I was going to point you to to explain things.
Another thing you could do is just create a simple movieclip object (named container below) that contains various different types of objects.... a button, a movieclip, a dynamic textfield, a static textfield, a raw shape... and use the code below to see what comes up each time as far as currentTarget and target go...
container.addEventListener(MouseEvent.CLICK, showTargets);
function showTargets(evt:MouseEvent):void {
trace(evt.currentTarget.name);
trace(" "+evt.target.name);
Sometimes you will see they both identify the same object (the container), but other times the target will be different.
The "target" property of the event can end up being helpful in different scenarios, such as if you have a drop down menu. You can assign the listeners to the parent movieclip to make coding the rollover/rollout functionality a quick couple of lines, and then use the target to determine which button within was clicked. Beats the hoops one usually jumps thru when making a drop down menu in AS2.
If the intention is to manipulate the object that has the listener assigned, then using currentTarget will always point you there. -
Hello
Because i need to do 3d transformation on the whole stage, i set the stage transfromation.matrix3d.
I made one test application and find that mouse event doesn't work properly.
In my application, i simply add a sprite containing red circle and test the functions.
Besides, i scale the stage along x-axis half using stage.transform.matrix3D
The problem is that when i click on my red circle, the e.localX/Y and e.stageX/Y are all zeros.
But if i click on places rather than my red circle be, the e.localX/Y and e.stageX/Y work fine.
Here is my code.
public function init():void{
var m:Matrix3D= new Matrix3D();
m.copyRowFrom(0,new Vector3D(0.5,0,0,0));
m.copyRowFrom(1,new Vector3D(0,1,0,0));
m.copyRowFrom(2,new Vector3D(0,0,1,0));
m.copyRowFrom(3,new Vector3D(0,0,0,1));
stage.transform.matrix3D = m;
s.graphics.beginFill(0xff0000);
s.graphics.drawCircle(0,0,50);
s.graphics.endFill();
addChild(s);
s.x = (stage.stageWidth)/2;
s.y = (stage.stageHeight)/2;
s.z = 0;
stage.addEventListener(MouseEvent.CLICK, onStageClick);
private function onStageClick(e:MouseEvent):void{
trace("global" + e.stageX + " " + e.stageY);
trace("local" + e.localX + " " + e.localY);1. In the code, I think it should change the value of the "player" so that it reflects the right turn. E.g. after the user press the mouse, the player should be changed to "computer" and after the computer goes, the player should be changed to "you". Otherwise, the player stays the same value and the program will only print out one symbol, which in this case is "O".
2. To make the previous moves stay, the code has to get some way to remember the moves. So before the repaint, the program will record the context for the next paint method.
Regards, -
A stageX, stageY property for MovieClips - how do you do it?
Getting the absolute position of dynamically created, moving MovieClips can be a real pain, especially if you use radomization and don`t know where or how deeply nested they spawn.
The localToGlobal function can make your code really unreadable, so I tried to come up with a functionality that would give me access to any Sprite/MovieClips position on the stage no matter where.
Kind of a property that some Events have (stageX, stageY).
Basically my goal would be to have no localToGlobal/GlobalToLocal conversions in my document class, but doing all that stuff inside the instances themselves.
What I have so far:
import flash.display.MovieClip;
import flash.geom.Point;
var _nestLevel:int = 0;
var l:int = 0;
var parentList:Array = new Array();
getAbsolutePoint(this);
function getAbsolutePoint(_mc:MovieClip):void
if (_mc != MovieClip(root))
_nestLevel++;
getAbsolutePoint(MovieClip(_mc.parent));
else
while (l<_nestLevel)
l++;
parentList.push("parent");
trace(parentList);
//traces correctly depending on the nesting Level (e.g. parent,parent,parent)
//this throws a 1010 Error
trace("Global coords : " + _mc[parentList].localToGlobal(new Point(_mc[parentList].x,_mc[parentList].y)));
Any ideas how to get this to work?if you answered yes and if the final shape is at 0,0, you can use returnF to return the movieclips position relative to the global coordinate system:
var stageX:int=this.x;
var stageY:int=this.y;
defineF(this);
function defineF(mc:MovieClip):void{
stageX+=mc.parent.x;
stageY+=mc.parent.y;
if(mc.parent.parent is MovieClip){
defineF(MovieClip(mc.parent));
function returnF():Array{
return [stageX,stageY]; -
Problem with accessing dynamically created movie clips, returns null...
Hopefully this is a stupid question with an easy answer, if my code is straight forward enough.
I am using this snippet of code to create menu items, and then use the jCount variable below to give the clips an index number, like so (which seems to be working just fine):
for(var j:Number=0;j<xmlSubMenuLength;j++){
var mcSubMenuItem:mcSubMenu=new mcSubMenu();
addChild(mcSubMenuItem);
jCount++;
mcSubMenuItem.name = "mcSubMenuItem" + jCount;
//traces out names correctly
trace ("---------------------------------jCount NAME = "+ mcSubMenuItem.name);
mcSubMenuItem.x=mcMenuHolder.x+20;
mcSubMenuItem.y =mcMenuHolder.y;
mcSubMenuItem.y+= nextBtnY;
nextBtnY+=subtopicSpace;
global_subi.text = String(jCount); //i see the proper count of 10 in the text field
However, when I try to access the clips using this snippet:
for(var j:Number=0;j<Number(global_subi.text);j++)//
trace("GLOBAL SUBI = "+ String(global_subi.text)); //traces out 10, which it should
var scSubMenuItem:String = "mcSubMenuItem" + j;
var scSubContent:Object = this.getChildByName(scSubMenuItem);
trace(">>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>scSubContent:Object = "+ scSubContent); //returns null!
My last trace statement returns null. Can anyone see my error, or explain why I can't access my clips after they have been created?
Thank you muchly,
~ChiplehHi kglad,
Thanks for the response.
"it's not clear from the shown code that jCount is initialized." - I've posted the relevant code below, which shows that I'm initializing jCount.
"and it's not clear why you don't use j instead of jCount in that for-loop" - j is used as loop for creating the subtopic movie clips within the i for-loop. So, for each topic in i for-loop, create a group of suptopics using the j for-loop. The j for-loop re-initiates j every time the length of the subtopics is reached(if that makes any sense) - i.e. topic1>subtopic 1,2,3,4 : topic2>subtopic>1,2 : topic3>subtopic1,2,3,4
jCount is used to keep a running count of the total number of subtopcs created - i.e. per the example above, jCount will display 10.
var topicSpace:uint=button_mc.height;
var subtopicSpace:uint = button_mc.height;
var nextBtnY:uint = 0;//whatever;
var jCount:Number = 0;
function createXMLMenu(menuLength:Number,itemName:XMLList):void{
var navItemText:XMLList = itemName;
for(var i:Number=0;i<menuLength;i++)
var mcMenuItem:mcMenu=new mcMenu();
addChild(mcMenuItem);
mcMenuItem.btnTxt.htmlText = i+1 +". " +navItemText[i];
mcMenuItem.ivar = i;
mcMenuItem.name = "mcMenuItem" + i;
mcMenuItem.x=mcMenuHolder.x;
mcMenuItem.y =mcMenuHolder.y;
//kglad's addition
mcMenuItem.y+= nextBtnY;
nextBtnY+=topicSpace;
var subVar:Number = i;//mcMenuItem.ivar
//Submenu content
var xmlSubMenuLength:Number = xml.sim.bodyText.page[i].subpage.length()
var menuItemAttachment:MovieClip = MovieClip(mcMenuItem);
for(var j:Number=0;j<xmlSubMenuLength;j++)
var xmlSubPageNumber:XMLList = xml.sim.bodyText.page[subVar].subpage;
var subNavLinkNumber:Number = xmlSubPageNumber[j];
var subTitleText:String = xml.sim.bodyText.page[subVar].subpage.subNavItem[j];
var mcSubMenuItem:mcSubMenu=new mcSubMenu();
trace("mcSubMenuItem.ivar = "+ j+1);
var mc2Attach2:MovieClip = MovieClip(menuItemAttachment);
mcSubMenuItem.btnTxt.htmlText = j+1 +". " +subTitleText;
mcSubMenuItem.ivar = Number(subVar);
mcSubMenuItem.jvar = Number(j);
addChild(mcSubMenuItem);
jCount++;
mcSubMenuItem.name = "mcSubMenuItem" + jCount;
trace ("---------------------------------jCount NAME = "+ mcSubMenuItem.name);
mcSubMenuItem.x=mcMenuHolder.x+20;
mcSubMenuItem.y =mcMenuHolder.y;
//kglad's addition
mcSubMenuItem.y+= nextBtnY;
nextBtnY+=subtopicSpace;
global_subi.text = String(jCount);
mcSubMenuItem.lExtend.visible = false;
global_i.text = String(i);
Then I try to access the clips like so:
-The first for-loop access the topic movie clips, no problem, and traces out scContent correctly.
-The second for-loop traces out null everytime, when I would expect it to be tracing out the names of the subtopic movie clips.
function accessClips(){
//This will access the topic movie clips
for(var i:Number=0;i<Number(global_i.text);i++)
var scMenuItem:String = "mcMenuItem" + i;
var scContent:Object = this.getChildByName(scMenuItem);
trace(">>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>scContent:Object = "+ scContent);
//This is supposed to access the subtopic movie clips
for(var j:Number=0;j<Number(global_subi.text);j++)//
var scSubMenuItem:String = "mcSubMenuItem" + j;
var scSubContent:Object = this.getChildByName(scSubMenuItem);
trace(">>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>scSubContent:Object = "+ scSubContent);
Hope this makes sense, Chipleh confused. If the code is not clear enough, let me know and I'll try to further clarify.
Thanks again,
~Chipleh -
Issue sending e-mails to certain domain
I'm having an issue sending e-mails to domain capitaliii.com from my Ironport. I see the following message in the Ironport log.
"DNS Temporary Failure capitaliii.com MX - unable to reach nameserver on any valid IP"
When I issue a nslookup on the MX record from the Ironport, I get the below message.
Temporary query error: "unable to reach nameserver on any valid IP" looking up A record for "capitaliii.com" to nameserver
ns3.digipark.com
I can however do a successful a successful nslookup from my workstation. See the results below. Any ideas? I've done
a flushdns on the Ironport to no avail.
Non-authoritative answer:capitaliii.com MX preference = 10, mail exchanger = mail1.digipark.commail1.digipark.com internet address = 64.111.26.141Hello Doug,
check if your firewall in front of the IronPort appliance allows TCP for DNS on port 53. The query results I get are close to the 512 byte limit, where DNS switches from UDP to TCP:
cisco$ dig mx capitaliii.com +trace
; <<>> DiG 9.6-ESV-R4-P3 <<>> mx capitaliii.com +trace
;; global options: +cmd
. 274955 IN NS f.root-servers.net.
. 274955 IN NS g.root-servers.net.
. 274955 IN NS h.root-servers.net.
. 274955 IN NS i.root-servers.net.
. 274955 IN NS j.root-servers.net.
. 274955 IN NS k.root-servers.net.
. 274955 IN NS l.root-servers.net.
. 274955 IN NS m.root-servers.net.
. 274955 IN NS a.root-servers.net.
. 274955 IN NS b.root-servers.net.
. 274955 IN NS c.root-servers.net.
. 274955 IN NS d.root-servers.net.
. 274955 IN NS e.root-servers.net.
;; Received 260 bytes from xxx.xxx.xxx.xxx in 189 ms
com. 172800 IN NS a.gtld-servers.net.
com. 172800 IN NS b.gtld-servers.net.
com. 172800 IN NS c.gtld-servers.net.
com. 172800 IN NS d.gtld-servers.net.
com. 172800 IN NS e.gtld-servers.net.
com. 172800 IN NS f.gtld-servers.net.
com. 172800 IN NS g.gtld-servers.net.
com. 172800 IN NS h.gtld-servers.net.
com. 172800 IN NS i.gtld-servers.net.
com. 172800 IN NS j.gtld-servers.net.
com. 172800 IN NS k.gtld-servers.net.
com. 172800 IN NS l.gtld-servers.net.
com. 172800 IN NS m.gtld-servers.net.
;; Received 504 bytes from 198.41.0.4#53(a.root-servers.net) in 23 ms
capitaliii.com. 172800 IN NS ns4.digipark.com.
capitaliii.com. 172800 IN NS ns3.digipark.com.
;; Received 109 bytes from 192.55.83.30#53(m.gtld-servers.net) in 50 ms
capitaliii.com. 86400 IN MX 10 mail1.digipark.com.
capitaliii.com. 86400 IN NS ns3.digipark.com.
capitaliii.com. 86400 IN NS ns4.digipark.com.
;; Received 147 bytes from 64.111.26.135#53(ns4.digipark.com) in 148 ms
Hope that helps,
Andreas
Maybe you are looking for
-
Is there a limit on the # of recordsets on a page?
I am experiencing really flaky DW issues when trying to add a 5th recordset to a page. Just by adding a simple recordset the page then appears blank in a browser. I remove the recordset and it's fine. Just a minute ago I tried adding a 5th recordset
-
Connecting Macbook to windows network
I am trying to make my macbook join my dads network as he wants to backup to my 500gb WD My Book Harddrive. I can access all of his shared files on his desktop, his laptop and my moms laptop. They however do not even see my computer in the network. W
-
Create table query taking too long..
Hello experts... I am taking the backup of table A which consist of 135 million records... for this am using below query.. create table tableA_bkup as select * from tableA; it is taking more than hour..still running.... is there any other way to quer
-
I just got my blackberry a few days ago and while I was moving my icons around my "options" icon disappeared. I tried the "hide", "show all" and everything, but it is still not showing up. Maybe it got deleted, but I don't think so... Can someone hel
-
What Version of Subversion Is Recommended for SDDM 4.0 Production
Subversion 1.8.5 is the latest. What Client does SDDM 4.0.0.833 use?