chris.whealy

14 Posts

I recently had a Twitter exchange with SAP Mentor DJ Adams (@qmacro) about the "good old days" of Assembler programming on R/2 systems, and I remembered that I still had the original course notes from IT400 "Introduction to Assembler Programming".

This course was first published in August 1989 (actually last Sunday was its 22nd birthday), and it was one of the first courses I attended when I started working with SAP software.

Many of the features that are still present in ABAP have their origins in IBM System 370 Assembler. To name but a few:

  • Why you put an asterisk in column 1 to denote a full line comment
  • Where the offest and length syntax came from E.G. lv_field+4(4)
  • Why an ABAP return code of 0 means success, 4 means warning and 8 means error

This was a very enjoyable and interesting walk down memory lane for two old R/2 hacks like myself and DJ, and I thought that any other old-timers might enjoy the same nostaligic stroll. (In fact, reading the course notes will explain exactly what a Q-Macro is, and hence where DJ got his Twitter handle from).

When R/3 was developed in the early nineties, many of the architectural features and principles developed in R/2 were transferred into the client/server architecture used by R/3 (which is now the NetWeaver ABAP stack).

For those of you however, who have never heard of R/2 (or at least never went to that part of the IT museum), I highly recommend having a look at these course notes because they will show you that the modern versions of SAP software have a pedigree that stretches back to the very stable and solid foundation laid in the IBM Mainframe world of R/2.

For you newbies to programming (by that, I mean anyone with less than 20 years experience :-) ), I would highly recommend that you give good consideration to the principles of Assembler programming.  Far from being "archaic" or "redundant", the principles I learnt 25 years ago gave me the solid foundation I have today for being able to write efficient coding in high level languages.

Enjoy!

Chris W

Deriving the ABAP data model class name from a Gateway service name

The assumption made here is that the Gateway service you are wanting to investigate has been created using the OData Channel technique (good ol' ABAP coding) and not by the Gateway model wizard!

The GAteway service name is the name that appears in the URL when executing the service from a browser.

The first thing you need to know is how your Gateway system has been installed.  There are two possibilities here. Since the Gateway software is nothing more than a set of ABAP add-ons, the first task is to determine whether all the software components exist on your backend business system, or whether the components have been split between your backend business system and a separate Gateway system.

  1. Log on to your Gateway ABAP system and select System -> Status.
  2. Select the "Component Information" button in the section "SAP System Data"
  3. Scroll down the list looking for component IW_BEP.
  4. If IW_BEP does not exist in the Gateway system, then you will need to locate the correct backend system with which the Gateway service communicates.

If the IW_BEP component has not been installed on your Gateway system, then you must log on to whichever system has this component.

  1. In the system where component IW_BEP is located, run txn SM34 and enter the cluster name of /IWBEP/VC_MGW_SG.  Select "Display".
  2. From the left hand navigation tree, select "Define Object Model Group".
  3. The 3rd column lists the external service name seen in the URL.
  4. Scroll down the list to locate  your service name and in the next column (labelled "Runtime Class  Name"), you will see the name of the ABAP class that implements this  service.
  5. You can now look at this ABAP class in SE80

If you want to identify the metadata class that is used to define the Gateway service's interface, then proceed as follows:

  1. Still in SM34, select the "Define Object Model Group" node from the tree display on the left.
  2. Select the row of the table containing your external service name and double click on the "Assign Object Models to Model Groups" tree node on the left side of the display.
  3. You will now see the Technical Model name. Remember this name.
  4. Now, select "Define Object Model" from the tree structure on the left of the screen.
  5. Locate the Technical Model Name in the first column of the table, and once found, the third column of the table will show you the ABAP class that defines the Gateway service's metadata.
  6. You can now look at this ABAP class in txn SE80

Important!

Now that you've located the two ABAP classes that implement a Gateway service, you might be a little puzzled as to how they operate together.

From the perspective of the ABAP coding, there is no direct connection between the Gateway metadata class and the Gateway runtime class.

The only connection between these classes is the configuration you've just reverse engineered by looking at cluster /IWFND/VC_MGW_SG.  The association is like this:

  • The metadata class is wrapped in an Object Model.
  • The runtime class is wrapped in an Object Model Group.
  • The Object Model (wrapping the metadata class) is then assigned to the Object Model Group (that wraps the runtime class).

So there you have it, simple really (!?)

:-)

Chris W

This blog is all about what HTML5 is, what it can do for you and what it really means to "support" the use of HTML5.

Due to the scripting and style sheet limitations of the SDN blogging tool and the fact that this blog uses lots of new features (particularly in CSS3), I have had to host it on my personal website.

Chris W

What Does It Mean For A Business Software Vendor To Support HTML5?<br />(Executive Summary)

 

There are two versions of this blog; this one – aimed at non-technical decision makers, and a second more technical one aimed at developers.

Irrespective of the version you read, the purpose of this blog is to cut through all the marketing phluff and hype that has grown up around HTML5 and get down to the hard facts.

My approach focuses first on examining whether the correct question is being asked, and secondly, on the various standards and recommendations that exist for the functional capabilities of a browser.  This will act as the groundwork for establishing what HTML5 actually is.  Only then we can start to address the opening question of what it means for a software vendor to “support” HTML5.

h2. More Hype ‘n’ Phluff ‘n’ Stuff

Remember all the hype that AJAX generated 6 or so years ago?  Well, history seems to be repeating itself; but this time, the name “Ajax” has been substituted for “HTML5”.

Even though there are an increasing number of websites dedicated to showcasing and explaining what HTML5 is, the public perception of HTML5 still seems to consist of 9 parts disinformation, hype and marketing phluff, mixed with 1 part hard fact.

h2. So, What Really is the Question?

 

Albert Einstein was once asked by a journalist the following question: “What would you do if you knew that in 1 hour, the earth would be hit by an asteroid that could destroy all life on the planet?

 

Einstein replied (no doubt with a wry smile): “I would spend 55 minutes defining the question, and 5 minutes answering it.

Extracting the HTML5 facts from the phluff will require exactly the same approach.  Once we have carefully defined the question, answering it should be very straight forward.

h1. So What Is HTML5?

The most accurate description of HTML5 is to say that it is the next major revision of HTML – the language used to build web pages.  However, this description is not particularly helpful since many people do not have a clear understanding of what the term “HTML”[[1] | https://weblogs.sdn.sap.com/cs/blank/create/wlg#_ftn1] actually describes.

In addition to this, through the indiscriminate use of hype and marketing phluff, the media has expanded the term “HTML5” such that it is now little more than a generic, blanket term covering a wide range of new, Web-based features that you may (or may not) find popping up in the shiny new browser you’ve just installed.

In order to de-phluff the whole “What is HTML5?” question, we must first backtrack few steps and look at how standards for the Web are defined and who defines them.

h2. Is There A Standards Body For The Web?

 

Yes: this organization is the called World Wide Web Consortium (W3C) and was founded (and is currently chaired) by the man who invented the World Wide Web, Tim Berners-Lee.

 

In addition to the W3C, there is the Web Hypertext Application Technology Working Group (WHATWG).  Formed in 2004, the WHATWG is a community of individuals all interested in evolving HTML and its various related technologies.  It was formed by a small group of people who had become somewhat frustrated – not only by the slow progress made on standards development by the W3C, but also on the W3C’s 2004 decision to abandon HTML in favour of XML.[[2] | https://weblogs.sdn.sap.com/cs/blank/create/wlg#_ftn2]

Independently of the W3C, the WHATWG took it upon themselves to develop a major revision of the W3C’s current HTML standard known as HTML4.  This is where the term “HTML5” was first used.

Then In April 2007, the WHATWG proposed that the W3C adopt their new HTML5 proposal as the starting point for their work.  This proposal was accepted and, as of May 2007, the W3C took on WHATWG’s specification for HTML5 as their official proposal for the new HTML standard.

h2. How Is The W3C Organised And What Standards Do They Define?

The W3C exists as a community of individuals, businesses, non-profit organizations, universities and government bodies who have made it their task to bring agreement to the development of software standards for the World Wide Web.  The W3C has an Advisory Committee that oversees the process of standards recommendation.

As of January 2011, the W3C had 324 members.

The W3C defines standards not only for HTML, but also for many other areas of Web based software.
These include:

As you can see, HTML is just one of many different standards defined by the W3C.

h2. How Long Does It Take For The W3C To Create A Recommendation?

Well, let’s just say you shouldn’t hold your breath waiting.

There is a well-defined process through which all recommendations pass, starting with the initial idea and finally ending up at a formal recommendation.  These stages of maturity are as follows:

    Working Draft (WD)<br />This is the first publically available version of a standard that is open for comment by anyone.  Working drafts go through multiple, possibly disruptive revisions.
    Candidate Recommendation (CR)
    The group responsible for the particular standard is now satisfied that the functional requirements have been achieved.  At this point, the development community is approached to determine how viable the standard is as working software.
    Proposed Recommendation (PR)<br />It has now been agreed that the standard both achieves its functional requirements and can be implemented as working software.  It is then submitted to the W3C Advisory Committee for approval.
    W3C Recommendation (REC)<br />The Advisory Committee has approved the standard and now issues it as a formal W3C recommendation.  At this point it becomes a defined standard to which Web-based software should conform.

      The time it takes to get an initial idea to progress through these stages of maturity varies widely and in some cases, can be quite long.  For instance the third revision of the Cascading Style Sheet standard (known as CSS Level 3 or just CSS3) started in 1998.  This standard is still being worked on in 2011![[3] | https://weblogs.sdn.sap.com/cs/blank/create/wlg#_ftn3]

      h2. Once A W3C Recommendation Is Made, What Then?

      Having a standards body for Web based software is all very good and necessary, but the W3C has no direct authority to enforce the adoption of any of its recommendations.  Therefore, browser vendors have implemented only those new features that best suited their development timescales and/or corporate goals.  This piece-meal approach to feature development has created a high degree of inconsistency between different browsers and has been a major source of heart-ache and pain for Web developers – just ask any Web developer how much extra time, effort and expense is required to get a website to function equally well in not just different browsers, but different versions of the same browser.

      In spite of the fact that the bureaucratic processes of the W3C move like a speeding glacier, the hype and media interest surrounding HTML5, together with the fact that the Web has become a ubiquitous part of our business and social lives, has provided sufficient incentive for the major browser vendors to implement many of the new W3C features long before they ever reach even the Candidate Recommendation stage.

      Consequently, the picture today for inter-browser compatibility is still not perfect, but is looking better than it has done in the past.

      h2. So Where Are We Up To With HTML5?

      Back in 2008, Ian Hickson, the editor of the HTML5 specification, quipped[[4] | https://weblogs.sdn.sap.com/cs/blank/create/wlg#_ftn4] that he did not expect HTML5 to become a full W3C Recommendation before 2022.  Fortunately, he has since revised that opinion and stated that he expects HTML5 to reach the Candidate Recommendation stage in 2011, and become an official W3C Recommendation by 2014.

      Writing this blog in February 2011, 2014 still seems like quite a long way off; but unlike the adoption of HTML4 and CSS2 over a decade ago, browser vendors have not waited for the W3C to give the green light; they have just gone ahead and implemented the features anyway.  This is largely because browser vendors can achieve many functional advantages through early adoption of the W3C’s proposed new features – regardless of the fact that most of the proposals are still at the Working Draft stage.

      So let’s look at what HTML5 actually is and what it can offer.

      h1. HTML5 – What Is It Really?

      As we have seen from the previous section, the W3C is currently working on multiple proposals for how Web based software should operate. These recommendations cover a wide range of functionality that includes:

      HTML & CSSDefines the structure for a web page’s content and how it should be presented)
      Scripting and Ajax(Adds dynamic, asynchronous refresh capabilities to a web page)
      Graphics(Defines which picture formats are supported)
      Audio & Video(Defines how audio & video content can be handled without the need for plug-ins)
      Accessibility(Defines how web pages can be accessed by people with disabilities)
      Mobile Web(Defines the standards for accessing the Web from mobile devices)

      These topics are just some of the many currently being dealt with by the W3C.  However, if you look at all the different features that the media are labelling as “HTML5”, you will find that they are drawn from many different W3C proposals – only one of which is actually called HTML5.

      So when the term “HTML5” appears in common usage, it is typically being used simply as a generic term to cover a wide variety of new, browser based features – and not simply the single W3C standard called HTML5.

      h1. So I Can Just Go Ahead And Build Cool New RIA Apps in HTML5!

      Hold on a second there, Tiger!

      As stated above, browser vendors have looked at the wide range of new functionality proposed by the W3C and adopted those parts that best suited their development schedules or corporate needs.  Although the situation is better than it has been in the past, incompatibility still exists between different browsers with regard to support for the full range of “HTML5” functionality.  So the bottom line is this:

       

      You can build a business application using as many of these new, ambiguously named “HTML5” features as you like.

       

      However, it’s your customer’s choice of browser that will determine whether or not your application will work.

       

      So support for all these wonderful new “HTML5” features is provided by the browser used to display the application and not by the company writing the business application!  The limiting factor here is the customer’s choice of browser.

      h1. Ok, So Where Does That Leave Me?

      As someone who writes Web-based business applications, it probably leaves you feeling pretty annoyed at the authors of all those rave blogs and eZine articles who've told you how wonderful life will be in HTML5’s Promised Land.  So here’s how to proceed:

      1. Check with your customer base and find out what browser(s) they are using.
      2. Check to see which of the new “HTML5” features are supported by those browsers.
      3. The list created in step 2) will then define the subset of true “HTML5” features you are free to work with.
      4. Only then can you start to build an “HTML5” application that will work at your customer’s site.
      h2. So Which Browsers Are The HTML5 High Flyers And Which Are The Lame Ducks?

       

      As of Feb 2011, Google’s Chrome 9 and Apple’s Safari 5.0.3 offer the widest range of support for all the new features generically known as “HTML5”.[[5] | https://weblogs.sdn.sap.com/cs/blank/create/wlg#_ftn5]

       

      Coming in second is Firefox 4 which also has good support for “HTML5”, but it’s not quite as extensive as that found in Chrome or Safari.

       

      And unfortunately, trailing in a somewhat distant third place is Microsoft’s Internet Explorer.  The latest version of Internet Explorer (IE9) has some support for “HTML5”, but lacks support for many of the new features in HTML5 Forms and CSS Level 3.

       

      Opinion is also divided as to whether IE9 has as much HTML5 support as is claimed.  Microsoft claim it has around 99% HTML5 support, but the rest of browser-savvy world disagrees.  See http://people.mozilla.com/~prouget/ie9/ for details.

       

      Now for the really bad news – if your customers are using Internet Explorer versions 7 or 8, or worse still, Internet Explorer version 6, then you have to make some tough decisions about the use these new “HTML5” features in your business applications.  The fact of the matter is that these browsers simply do not understand any of the new tags, styles or JavaScript functionality.

      The bottom line here is that you’re nowhere near the Promised Land of “HTML5” – instead, you’re wandering in the HTML4 wilderness without even having satisfactory support for CSS2.

      h2. How Do I Know What HTML5 Features Are Supported By Which Browser?

      Various websites exist that will either present you with tables of which browser supports which feature, or the website will check the capability of your particular browser and give you a simple report.  These include:

      Can I Use?[http://www.camiuse.com | http://www.camiuse.com]Tables of which browsers support which features
      HTML5 Readiness[http://www.html5readiness.com | http://www.html5readiness.com/]Chart of which browsers support which features
      Modernizr[http://www.modernizr.com | http://www.modrnizr.com/]Performs HTML5 feature checks on your browser
      h2. What Should I Do If My Customer’s Browser Really Belongs In a Museum?

      By museum piece, I really mean Internet Explorer 6, but these principles apply to any out-of-date browser.

       

      Under these circumstances, it would be best to enter into discussions with your customers and explain that you would love to deliver them some shiny new, “HTML5” enabled applications, but until they start to use HTML5-enabled browsers, you are unable to provide them with up-to-date applications that deliver a modern UI experience.

      If the customer is willing to upgrade their browsers, then you are free to use whatever HTML5 features are supported by the customer’s choice of browser.

      If, however, the customer is either unwilling or unable to upgrade from their old version(s) of IE, then you can adopt one of three approaches:

      Completely Ignore HTML5

      In this approach, you would deliver your Web application using only those capabilities delivered by HTML4, JavaScript and CSS2.  Generally speaking your application will run successfully in both the old and new browsers; however, you should be aware that you will:

        1. Accept the current limitations of HTML4 and CSS2 to be less of a problem than a browser upgrade
        2. Be unable to deliver an application that provides a modern UI experience

       

      There should be a strong business case against a browser upgrade before this approach can be considered viable.

      Deliver HTML5-like functionality using HTML4, JavaScript and CSS2

      In this approach, you attempt (as much as possible) to make your application look and function like a modern “HTML5” based application – without actually being one.  This approach is widely used at the moment by Web developers who want to make use of the benefits provided by “HTML5”, but are restricted by the limitations of browsers that do not understand the new HTML5 tags, new JavaScript functionality or CSS3 style information.

      Since this approach requires that HTML5-like functionality is re-developed using old technology, a Cost/Benefit analysis is strongly recommended before embarking on such an exercise.

      Dynamic AdaptationTrue support for this new functionality takes place in the browser and not in the business application.
      A business software vendor can make use of as many of these new “HTML5” features as they like, but there is no guarantee that these features have been implemented in the browser used by their customers.
      If your business applications need to accommodate the widely varying capabilities of old and new browsers alike, then the dynamic adaptation approach described above should be followed.
      h1. So let’s go back and look at the original question:

      What Does It Mean For a Business Software Vendor to Support HTML5?

       

      By now it should be clear that the word “support” is not the best choice of verb in this question.  This is because the actual support for these new features takes places within the browser, and not in any application created by a business software vendor.  So it is the browser that supports “HTML5”, and the business software vendor then writes an application that makes use of these various new features.

      Unless you, the business software vendor, also write your own browser, then you are entirely reliant on the 3rd party browser vendor to provide support for the various new “HTML5” features you wish to use.

      Therefore in the above question, we should replace the word “support” with the word “implement” and also be a little more specific on what we mean by the term HTML5.  So the question now reads:

      What Does It Mean For a Business Software Vendor to Implement an Application<br />That Uses the New Features found in HTML5, CSS3 and JavaScript?

       

      And I think you already know the answer to this question...

       

      :-)

       

      Chris Whealy



      [[1] | https://weblogs.sdn.sap.com/cs/blank/create/wlg#_ftnref1] HTML stands for Hypertext Markup Language.

      [[2] | https://weblogs.sdn.sap.com/cs/blank/create/wlg#_ftnref2] XML stands for Extensible Markup Language

      [[3] | https://weblogs.sdn.sap.com/cs/blank/create/wlg#_ftnref3] Due to the slow rate of progress with CSS3, the W3C has now stated that individual style sheet features should be treated as separate units of development (known as modules) that can reach “W3C Recommendation” status independently; yet all are considered part of the wider standard known as “CSS Level 3”.

       

      [[4] | https://weblogs.sdn.sap.com/cs/blank/create/wlg#_ftnref4] See http://blogs.techrepublic.com.com/programming-and-development/?p=718 [[6] | https://weblogs.sdn.sap.com/cs/blank/create/wlg#_ftnref6] A tool such as that found on http://www.html5boilerplate.com could be helpful here</p></div></div>

      How to check whether a WD Java Input Field marked as "required" contains any data

      This blog assumes that you know how to write a Web Dynpro application and have a functional SAP NetWeaver Java AS or a suitably deployed Tomcat server. It will not provide any further explanation beyond stating what steps need to be performed.

       

      The main functionality for this process is an extension of the generic UITreeVisitor class that is documented in section 10.4 of my book "Inside Web Dynpro for Java" (pages 327-331)  If you don't yet own a copy of my book, then shame on you!  :-)The only coding needed in the component controller is that necessary in wdDoInit() to create two elements in the InputData context node.  You can download the wdDoInit() code snippet here .Notice that both messages are of type "error" and that they have a single parameter identified by ""
      After you have created these messages, you must save all your changes by pressing Ctrl-Shift-S.  This forces the code generator to run and allows you programmatic access to the declared messages.
        1. Open the view editor and create the following view layout:
          Set the RootElement's LayoutManager to MatrixLayout
          !http://whealy.com/images/Web%20Dynpro/Input%20Validator/ViewLayout.png|height=496|alt=View layout|width=588|src=http://whealy.com/images/Web%20Dynpro/Input%20Validator/ViewLayout.png|border=0!

          The easiest way to add these UI elements is to right-click on the RootElement in the outline view and select "Apply template".  Then select "Form" and add all the attributes in the node InputData.
        2. In the outline view, Ctrl-click on each of InputField UI elements in order to select all of them.  then change the "state" property from "normal" to "required".  A red star will then appear next to the corresponding label field.
        3. Create an action in the view controller called "DoButtonPush".  Give this action a parameter called "Action" of type integer.  Make sure that this action is a validating action.
        4. Now add two buttons to the screen.  As can be seen from the screen shot above, these buttons are for the "Previous" and "Next" functionality.  Assign the same action "DoButtonPush" to both buttons.
        5. In the Outline view, right-click on the "Previous" button and select "Parameter Mapping".  In the popup window, press the "Create Constant" button and assign the value 0 to the action parameter.
        6. Repeat step 11 for the "Next" button, but this time, assign the constant value of 1.
        7. Switch to the Navigator view (the tab next to the Web Dynpro Explorer) and expand the "Resources" tree until you reach the "input_validator" directory.  Here, create a new Java file called UiTreeVisitor.java as per the screen shot below
          !http://whealy.com/images/Web%20Dynpro/Input%20Validator/ResourcesTree.png|height=410|alt=Resource tree|width=308|src=http://whealy.com/images/Web%20Dynpro/Input%20Validator/ResourcesTree.png|border=0!
      Download the coding for the UiTreeVisitor class and insert it into this file and then save it.
        1. Open the Java editor for the view controller InputValidatorView.  Download the controller coding for each of the following methods and insert it at the appropriate place in the controller:
        1. Now organize the view controller's imports by pressing Ctrl-Shift-O and save the changes.
        2. Create a new application called InputValidatorApp.
        3. Deploy and run this application and you should see something like the following screen
        4. h2. Running the application

      !http://whealy.com/images/Web%20Dynpro/Input%20Validator/StartScreen.png|height=400|alt=Start screen|width=500|src=http://whealy.com/images/Web%20Dynpro/Input%20Validator/StartScreen.png|border=0!

      If you simply press the "Next" or "Previous" buttons, you will swap the display between the two elements in node InputData.

      Now blank out one of the fields and try pressing "Next" or "Previous".

      !http://whealy.com/images/Web%20Dynpro/Input%20Validator/ErrorScreen2.png|height=400|alt=Error screen|width=500|src=http://whealy.com/images/Web%20Dynpro/Input%20Validator/ErrorScreen2.png|border=0!

      You will see an error message that is linked to the UI element that is missing an input value.  Click on the error message at the bottom of the screen and the cursor will be relocated to the field in error.

       If you blank out multiple fields, then you will get multiple error messges, each linked to the approriate UI element.  The error message is tailored to whether the input field should contain a string or numeric value.  This functionality can be extended if you wish to create specific messages for time and date fields.

      !http://whealy.com/images/Web%20Dynpro/Input%20Validator/ErrorScreen1.png|height=614|alt=Error screen with multiple messages|width=500|src=http://whealy.com/images/Web%20Dynpro/Input%20Validator/ErrorScreen1.png|border=0!

      h1. Caveats

      There are a few things to note about this solution!

        This is fine as long as you are disciplined to restrict your access to read-only.
        Please do not start noodling around with IWDView by adding new UI elements outside the scope of wdDoModifyView()!  You risk doing bad things to your data by potentially causing context supply functions run multiple times, or causing the framework to render the screen multiple times.
        The vector of messages passed to the UiTreeVisitor class is rather kludgey, but it saved me having to noodle around with reflection in the UiTreeVisitor class in order to discover what messages were contained if I'd passed the component's IMessage class.

        How to find the exact table cell on which your WD Java Context Menu was created

        Right click on any cell that does not belong to the currently selected table row:

        !http://whealy.com/images/Web%20Dynpro/Table_Context_Menu.gif|height=152|alt=Context Menu Visible|width=255|src=http://whealy.com/images/Web%20Dynpro/Table_Context_Menu.gif|border=0

        Now select the "Select this cell" option and look at the message that appears in the status bar below (in this example, we clicked on the cell containing the value "C3"):

        !http://whealy.com/images/Web%20Dynpro/Selection_Message.gif|height=31|alt=Selection message|width=646|src=http://whealy.com/images/Web%20Dynpro/Selection_Message.gif|border=0

         And there you have it!

        I trust you will find this useful.

         Chris W (@LogaRhythm) 

         

         

        The Great Web Dynpro Java Survey

        Calling all Web Dynpro Java developers!

        If you write (or have written) your own custom applications in Web Dynpro Java, SAP would like to hear from you about your experiences with, and opinion of this UI develpment toolset.

        We'd like to know what your experiences are so that we can improve both its ease of use and functionality.

        Please note!  This survey is aimed at customers/partners who use Web Dynpro Java for the development of custom applications.  If you only ever use Web Dynpro Java to run Employee Self Service or Manager Self Service applications, then this survey is not for you.

        Its time to let SAP know what you think of Web Dynpro Java

        Click Here to take survey

        Be nice...

        :-)

        Marc Chan, Jeff Gebo & Chris Whealy
        SAP NetWeaver RIG

        Update to the Web Dynpro Mind Map

        To download the latest version of the Web Dynpro Mind Map, please visit the new SDN Wiki page on the subject.  You can access this page by starting from the SDN Wiki page and then selecting

        Web Dynpro Java -> Learning Map -> Web Dynpro Mind Map

        New Features

        I have updated the Web Dynpro Java Mind Map to include links to new 7.1 Web Presentations in SDN.  This includes information on development best practices and a new presentation on the Phase Model in 7.1

        Downloading the mind map file

        Please be aware that when you download the mind map file, your browser may identify the file as a ZIP file (which is actually correct).  But then it might tell you to open it using WinZIP (or WinRAR) and then rename the extension from .mmap to .zip.

        This is an annoying feature of the browser (I know, it's just trying to be helpful - or it's just trying... depends on your point of view) and if you don't catch it, you will have to manually rename the file extension back to .mmap before it can be read by the Mind Manager viewer.

        Please do not unZip the file, as this will really confuse the situation!

        Update to the Web Dynpro Mind Map

        To download the latest version of the Web Dynpro Mind Map, please visit the new SDN Wiki page on the subject.  You can access this page by starting from the SDN Wiki page and then selecting

        Web Dynpro Java -> Learning Map -> Web Dynpro Mind Map

        New Features

        Some new content has been added concerning the origins of Web Dynpro, but more importantly, links to the 7 new eLearning presentations have been added.

        The nodes that contain these links have been coloured blue for easy identification.

        Downloading the mind map file

        Please be aware that when you download the mind map file, your browser may identify the file as a ZIP file (which is actually correct).  But then it might tell you to open it using WinZIP (or WinRAR) and then rename the extension from .mmap to .zip.

        This is an annoying feature of the browser (I know, it's just trying to be helpful - or it's just trying... depends on your point of view) and if you don't catch it, you will have to manually rename the file extension back to .mmap before it can be read by the Mind Manager viewer.

        Please do not unZip the file, as this will really confuse the situation!

        Web Dynpro Java eLearning

        As time allows, I am building up a library of eLearning presentations on Web Dynpro Java.

        I have generally called these presentations the "Online Web Dynpro Training Series" and together with alot of other SDN content on the subject, form a core of information that will help you not only get started with Web Dynpro Java, but also learn to develop good coding practices right from the start.

        Update to Web Dynpro Mind Map 

        The Web Dynpro Mind Map has been updated to provide links into these presentations.  Please use the mind map as a tool to give you an overview of the whole topic.

        From the mind map, you'll find links into many different SDN documents and eLearning presentations.

        OK, so how do I find this stuff?

        To find the links to these eLearning presentations, please visit the SDN Wiki page for Web Dynpro Java.  Starting from the SDN Wiki Page, the path is Web Dynpro Java -> Learning Map.

        Here, you will find links to both the eLearning presentations and the latest version of the Web Dynpro Mind Map.

        Have Fun!

        Chris W

        E-Learning for Web Dynpro Java Developers

        Sometimes the best way to communicate programming topics is not by writing lengthy articles or how-to guides or cookbooks, but to create short web presentations that use narration and animation.

        These two web presentations have been designed to give you an insight into two key areas of Web Dynpro Java development: Navigation and Error Handling, and the Web Dynpro Phase Model.

        Both of these presentations are built on the NetWeaver 7.0 version of Web Dynpro Java and can also be accessed through the updated The Web Dynpro for Java Mind Map.

        Navigation and Error handling

        This topic is one that can become awkward in WD applications that grow beyond three or four components.  When you have a large hierarchy of WD components that all have to function together in a single business process, then handling errors is often something that is best done in a centralised manner.  In addition to this, when errors occur during a round trip from the client, those errors frequently interfere with screen navigation (in other words, you have to decide how the error should be handled before allowing screen navigation to continue).

        Therefore, the two topics of error handling and screen navigation should be treated as a single unit of processing in large WD component hierarchies.  This web presentation lays down some principles on how this topic can be handled.

        Navigation and Error Handling in Web Dynpro 7.0

        Understanding the Web Dynpro Phase Model

        This is a topic of fundamental importance to any serious Web Dynpro Java developer!

        Every time there is a round trip from the client to the SAP Java Server, a fixed sequence of processing steps is performed by the Web Dynpro Framework known as the "Phase Model".

        The interface between your business application and the Web Dynpro Framework is achieved through the standard hook methods found in Web Dynpro controllers such as wdDoInit() or wdDoBeforeNavigation().

        However, if you don't understand why these methods exist, or when they are called, you will end up writing very inefficient coding, and generally abusing the Web Dynpro programming model!

        This presentation will show you exactly what happens every time there is a server round trip.  Then you will understand what type of coding should be put inside each standard hook method, and from this understanding, you will then be able to write very efficient Web Dynpro applications.

        Understanding the Web Dynpro Phase Model in NetWeaver 7.0

        Enjoy!

        Web Dynpro for Java Mind Map

        Introduction

        What’s a Mind Map?

        Anyone who’s ever had to try and make sense of a large quantity of information will know that as soon as you try to force that information into some sort of list or sequence, you often loose more than you gain. The list might look neat and tidy, but you will not have an accurate representation of the interrelationships between all the different facts.

        The bottom line here is that information cannot be represented entirely sequentially or hierarchically. In reality, one piece of information is related to multiple other pieces of information to form a web of relationships, associations and dependencies.

        A mind map is a simplified form of a diagram known as a Semantic Network. Mind maps have been used in many different forms for many centuries, but have lately been popularized by the British psychologist and educationalist Tony Buzan.

        A mind map allows you to create a web of relationships between words, ideas and tasks. In creating this network or web of relationships, you can communicate the structure of information in a way that is compact and easy to understand. Rather than having to use several sentences of text to describe the relationship between a set of ideas, you can simply place each idea on the page and draw lines between them. The lines can additionally be labelled in order to add further description to the relationship. Typically, a mind map will start from a central topic, and from this will spread out various related topics.

        When used correctly, this diagramming technique can concisely describe the relationship between multiple ideas and tasks yet require significantly fewer words than an equivalent plain text description would.

        In addition to this, the associations between the information in a mind map often act as triggers to your memory, and help you remember details about that particular topic that you thought you’d forgotten.

        This is why I have chosen to use a mind map to represent the ideas, facts and tasks involved in understanding Web Dynpro for Java.

        Graphics and screen shots

        The screen shots are taken from the Mindjet® MindManager® Viewer 7 running as a stand alone program as opposed to a browser plug-in.

        How to View the Mind Map

        This mind map has been created using the Mindjet software called MindManager. In order to view this mind map, you must install the Mindjet MindManager Viewer either as:

        • A stand alone program
        • As a browser plug-in (Only Internet Explorer v6.0 or higher)

        Stand alone program installation

        To install the Mindjet MindManager Viewer as a stand alone program, please follow the link to the Mindjet website where the software is available for free download (25Mb download).

        The viewer software is available in four different languages (English, German, French and Japanese) for both PC and Mac systems.

        Browser Plug-in

        If you are using Internet Explorer version 6.0 or higher, then the plug-in will install automatically.

        Depending on the security settings of your browser, you may see a security warning message displayed. Click on "Yes" to install the ActiveX plug-in.

        Figure 1: Possible security warning during plug-in installation

        Follow this link to view the Web Dynpro for Java mind map using the browser plug-in.

        Downloading the Mind Map

        If you choose to install the stand alone Mindjet MindManager Viewer, then you need to have a local copy of the mind map file. This is done by right-clicking on this link Web Dynpro mind map and select "Save Target As".

        W A R N I N G !
        It is possible that the browser will mistake the mind map file for a ZIP file, and then try to open it with some tool such as WinZIP or WinRAR. If this happens, you must make sure that the file extension is not changed to .zip. The mind map file must have an extension of .mmap and must not be unzipped.

        Using the Web Dynpro Mind Map

        General Information

        Once you have installed the Mindjet MindManager Viewer as either the stand alone program or the browser plug-in, you will then be able to view and navigate around the Web Dynpro mind map.

        Figure 2: The Default View for the Web Dynpro Mind Map

        As you can see from Figure 2, radiating out from the central subject are nine different topics. Each one of these topics is then broken down into further sub-topics. As these branches are expanded, further relationships will emerge between the different sup-topic areas.

        You will also notice from the diagram above that some of the links have icons to the right of the text. This indicates that a hypertext link is available to take you to a document, presentation or web page within either SDN, or the Online SAP Help or some other relevant information source.

        Figure 3: When the same concepts appear in multiple locations within the mind map, blue association arrows link them together

        Since information cannot be arranged sequentially without significant degradation, you will see the same concepts or topics appearing in multiple places across the map. When they do, you will see a blue association arrow that connects them together. See Figure 3 above.

        Mind map navigation

        Once you have expanded several branches of the mind map, you will find that it rapidly becomes larger than the available screen size. In this situation, you can either change the zoom level (Ctrl + spin mouse wheel) or drag the whole map around to examine a particular area.

        Dragging the map can be done by first left-clicking and holding, and then the mouse pointer changes to a hand and you are then able to drag the whole map in any direction.

        Be careful about expanding too many branches of this map at once! This map can grow to become very large and you will not be able to see all the branches at once. It is recommended that you expand only the particular branch you are interested in.

        Figure 4: Since the mind map is very large, you should only expand the branches you are interested in.

        Printing the mind map

        It is quite possible to print the fully expanded Web Dynpro mind map - as long as you have a sufficiently large printer! For instance, the entire map can be printed successfully on an HP 1055CM printer. The resulting print is about 1 metre wide and 2.5 metres high.

        A word of warning about the print settings though! In the Page Setup menu, always ensure that the "Print Background" option is switched off!

        The reason is that the mind map has an off-white background colour defined for it. This makes it easier to read on the screen, but if you attempt to print the fully expanded mind map, it will generate a print job of around 475Mb (depending on the type of printer being used). Not surprisingly, a print job this size caused the above printer to abort the job.

        The answer is simply to switch off the background colour during printing, and the size of the print job drops to just over 2Mb!

        Figure 5: If you wish to print the fully expanded mind map, then ensure that the Background colour is not printed.

        I have spent the last 2½ years reviewing customer Web Dynpro Java implementations, and I have noticed that there are a common set of problems that pop-up time and time again.  Therefore, to combat these problems, I have created the following two TechEd presentations:

        • CE351: How to Build Low TCO Applications in Web Dynpro Java
        • CE352: Getting the Best From the Web Dynpro Framework

        These two presentations address different aspects of a Web Dynpro Java implementation project.

        CE351 approaches the situation from a semi-technical point of view and deals with how problems can be avoided from the management and architectural perspectives.

        CE352 however, looks under the hood of Web Dynpro Java development and describes the design principles that should be followed when writing the actual coding.

        These two presentations are designed to function as a pair with the combined objective that the attendees go away armed with a solid set of principles and guidelines so that when they start a Web Dynpro implementation, they will not repeat the mistakes of the past.

        These presentations are aimed at helping you build Web Dynpro Java applications that have a genuinely reduced TCO.  The bottom line is that if you do not follow the principles of good Web Dynpro design during the Design and Build phases, then when the software enters the Maintenance and Enhancement phase, you will find that a large number of hidden costs are suddenly waiting to bite you!

        Where did these costs come from?

        They were built into the application during the Design and Build phase because developers either:

        • Lacked the experience or understanding to avoid them
        • Had to work to an aggressive time line that did allow for training and forced people to cut corners
        • Or some other factor such as scope creep increased the quantity of software to be delivered, without allow for extra time and/or resources to deliver it

        Whatever the reasons, the result is that a Web Dynpro application is produced that is functional, but rapidly becomes a maintenance nightmare!

        All of these situations can be avoided if the principles of good Web Dynpro design are understood and implemented.  Then when the software enters the Maintenance and Enhancement phase, the amount of time and effort required to make modifications will be significantly reduced.

        Why?

        Because the software was built to follow known design principles: this means that it does not contain any clever workarounds or redundant complexities (spaghetti code) that do little more then add time, effort and money to an enhancement project.

        CE351 and CE352 will help you understand how to get the best from Web Dynpro not just to simplify development, but also to remove the hidden costs and nasty surprises that the software can so often throw at you during the Maintenance and Enhancement phase.

        So sign up for these presentations, and I’ll see you in Las Vegas or Munich!

        So why shouldn't I use a Web Dynpro Project?

        The project type "Web Dynpro Project" was developed before SAP had any development infrastructure software. The drawback with this type of project is that it behaves like a sealed, non-reusable container.

        Nowadays, we have the NetWeaver Development Infrastructure (NWDI) to manage source versions, build dependencies and transports. This means that unless you are writing a very simple training or demo application, you should not use a project type of "Web Dynpro Project".

        OK, what should I use instead?

        The answer is that you should always use Development Components (DCs) of type "Web Dynpro". Even if you do not have a working NWDI installed, you can still create Local Development objects. In the ABAP world, this is equivalent to creating objects of package (formerly Development Class) $TMP.

        The point here is that a DC is a reusable entity. If you have already created a Web Dynpro Project, then for comparison purposes, it is useful to create a DC of type Web Dynpro, and then expand the first level of the project hierarchy. You will notice that the Web Dynpro Project has three nodes directly under the project branch, but the DC of type Web Dynpro has four. The extra branch is critically important. This is the "DC Metadata" branch, and it is here that you can declare both the usage dependencies to other DCs (under "DC Definition"), and those parts of your DC that will be publicly available (under "Public Parts").

        How should DC's be used then?

        The DC of type Web Dynpro represents a reusable unit of code. This concept gives you a high level of flexibility over how your DCs should be structured, so it is not possible for me to give any exact rules about how much code should be put into one DC. However, there are some general principles to follow:

        1. A DC should be structured such that it represents a self contained unit of business processing.
        2. If a DC is made too small, then you will have highly fragmented reuse situations and end up with a complex network of inter-DC dependencies.
        3. On the other hand, if you make a DC too big, then you restrict its reusability because it will contain more functionality than is required for an individual reuse case.
        4. DCs expose their internal functionality through the concept of Public Parts (PPs). The PP is a compiled and delivered as a separate .jar file.

        When you create the Web Dynpro Components within the DC, you should decide which functionality will be publicly visible, and which will remain hidden within the DC.

        When you have identified a unit of functionality (for instance, a particular component) that needs to be publicly available, you should right mouse click on that entity, and select "Add to Public Part".

        If you have not created a PP before, then the first screen you will see asks you to create the PP. Give some meaningful name that describes the exposed object or functionality, and then the PP will be created and the entity added to it.

        That's pretty easy. Is that all there is to it?

        N O !
        Remember I said that the PPs of a DC are implemented as separate .jar files? Well, the PP jar files need to be built - this is a second, independent build process from the "Rebuild Project" option that you normally use. You must therefore select "Development Component" from the right mouse click menu on the DC node, and then select "Build" from the side-menu. Only then will the PP jar file be built.

        If you forget to do a DC build, then you'll probably be able to deploy your application (though without the PP jar files), but you'll experience runtime dependencies failures.

        So how do I reuse this functionality?

        Once you have developed a DC and built its PPs, you can then declare a usage dependency from another DC. A very useful example here is to split the model objects required by a Web Dynpro application into a separate DC. In this model DC, you create only the model objects - no Web Dynpro components. Then you add each model object to its own PP (don't forget to do a DC build each time a PP changes).

        Lets say that you are now writing another DC that wishes to use one of the model objects in the model DC. So under the "DC definition" branch of "DC Metadata", you will find the "Used DCs" branch. Here is where you can add a usage declaration to the model DC. Once you have done this, when you want to add a model usage to your Web Dynpro component, you will see all the models in the model DC when you select the "Add" option from the Used Models branch (if you don't see any model objects when you select "Add", its probably because you haven't built the PPs of the model DC.

        By putting the model objects into a separate DC, the model object source code only needs to be compiled once (usually a time consuming process), and then the DC that has declared a usage of the model DC only needs to reference the compiled code. This greatly speeds up development time!

        Filter Blog

        By date: