Saturday, May 7, 2011

Tutorial: Table Relation properties in AX 2012

As many of you already know, Microsoft has put in a lot of effort into normalizing the tables in AX 2012 and consolidating all the data modeling tools in one place - the table itself. As part of this effort, a number of new properties have been introduced on Tables, and in this post I would like to cover some of them, namely the properties on Table Relations.

The new properties you will find on a Table Relation in AX 2012 are:
  • Cardinality
  • RelatedTableCardinality
  • RelationshipType
  • Role
  • RelatedTableRole
  • UseDefaultRoleNames
  • CreateNavigationPropertyMethods
  • NavigationPropertyMethodNameOverride

Hua Chu from the AX team has written a Guideline document, explaining how these properties should be set for Relations you add to Tables in AX. Note that in AX 2012 most of the above information is not actually used at runtime. This is something that will happen in future releases.
I have modified the document so that it contains the information relevant for partners and customers extending the standard application and have uploaded it to my SkyDrive.
(Modified: Something weird is happening with SkyDrive, so I have also uploaded the file to my personal site - download)
The document requires certain knowledge of Entity Relationship Modeling (ERM) and UML notation.

Disclaimer:
This document is intended as a guideline only, and should not be used as a Step-by-Step instruction.
Changes to any of the described functionality might still happen before AX 2012 RTM.


Your feedback and questions are, as always, welcome.

Thursday, May 5, 2011

Tutorial: lockWindowUpdate() vs. lock()/unlock()

There are two method pairs in X++, that are used throughout the application by everyone writing some processing on application forms. These are:

element.lock();
element.unLock();


and

element.lockWindowUpdate(true);
element.lockWindowUpdate(false);


Now, not that many people know the difference between the two methods, and only very few think about why and when should each of them be used.
I will try to describe the behavior of these methods and at the end give some recommendations on how to use them. I have done some kernel code reading (with help of kernel dev. Andy Stach, who I would like to mention here), so what I write below is more or less backed up by code.
If you disagree with some of the recommendations though, please share your experience in using these methods through comments for this post.

FormRun.lockWindowUpdate()

is basically a wrapper around the LockWindowUpdate Win32 function. What it does is pretty simple:
When a window is locked, all attempt to draw into it or its children fail. Instead of drawing, the window manager remembers which parts of the window the application tried to draw into, and when the window is unlocked, those areas are invalidated so that the application gets another WM_PAINT message, thereby bringing the screen contents back in sync with what the application believed to be on the screen.
See the link on MSDN for a detailed description.
Note, that according to MSDN, it should not be used for general purpose suppression of redraw operations, but only when dealing with drag&drop operations. This does not hold true for AX, where this method is used all over the place to prevent redraw of controls on the form.
Another interesting point is that only one window can be locked at the same time. So, any nested calls to lockWindowUpdate will be ignored, but when unlocking, only the outer-most unlock will actually invoke the Win32 counterpart. Now, I have not seen this used in X++, which is for the better.

FormRun.lock()

is internally invoking lockWindowUpdate to prevent the redraw of the window, and then also prevents the IntelliMorph control layout engine from running. This is commonly used in scenarios where control properties affecting control arrangement are being set in a loop, which provides a performance optimization as it avoids redundant arrange calls being processed. On the other hand, when calling FormRun.unlock, more work will need to be done, compared to using lockWindowUpdate(false), where the control layout changes were actually processed by the layout engine, but simply not displayed.

So, based on my investigation, I would suggest to use the following recommendations when doing form development:

  • When formRun.resetSize() is used, specifically, when some controls become visible, increasing the form size, always use formRun.lock()/unlock(), otherwise the change in the size of the form might not get reflected on the screen correctly.
  • When changing multiple layout properties (Left, Width, etc.) on one or more controls, use lock/unlock
  • When you modify the properties that do not impact the layout of controls on the form, use formRun.lockWindowUpdate(), or, if there are only very few control properties being modified, do not lock the form window at all.

Thursday, April 28, 2011

Microsoft FY11Q3 Results

What's on your mind as the Microsoft FY11Q3 results get released? Some things I'm thinking of:

Win7 Business being eaten alive by iPads? Oh, those hungry hungry cannibals eating away the post-PCs for your PC dependent iPad slates. Probably no good news in the Win7 OS business could please people seeing Apple having to buy everyone working at Apple pants with ten pockets so that they can continue stuffing money into them.

Office 14 / SharePoint: continued strength? Leveled? Dip?

Kinect: what are the post-holiday sells like?

Xbox Live security: not that we want to be cocky, but if Xbox Live was broken into like Sony's Playstation Network Microsoft would have a big-black eye. Probably two. How confident is Microsoft in the network's security?

WP7 numbers: how has the trend been in activated phones? How is the Nokia deal shaping up? How will Microsoft not be the weepy little toy of the phone carriers crying over a release chart when the Mango update goes out?

Share price: talk about one dead share. It's a dead fish. That a bunch of hippy dock-workers played hacky-sack with and left to rot out in the sun. So dead that we're shifting budgets around to not award stock but give out crisp, sweet-smelling Benjamins instead to the employees we value most. Microsoft millionaire days? A long, long distant memory. I think of that book Microsoft In The Mirror where a number of interviewees were reluctant to share with outside folks that they work at Microsoft because folks would light up, assuming they were rich beyond words. Today's response? "You work at Microsoft? Well bless your heart."

Keeping employees: seems as though we'll need to justify the extra bucks and effort the company is putting into spreading cash to the section of employees most likely to be recruited (aka poached) or give up on Microsoft. I'm sure that the investors could care less about our performance review system, but it's sad we stuck with a 20th-centry industrial review system for a 21st century Gen.Next workforce. Like many opportunities: buh-lown.

The two pressure points I certainly continue to feel:

WP7: the NoDo update was just a Class-A Cluster-Fuck. And I don't use language like that very often. And the fact that the pre-update bricked phones was inexcusable. The WinMo team has to realize that everything they have to do must be perfect and ahead of schedule (wrt running in customer's hands). Any sort of focus other than that is a recipe for disaster. Mr. Ballmer is a fan of Coach John Wooden. WWJWD? Pound excellence into the team such that releasing an update was the easiest thing they had to do. If you're the kind of person looking for a challenge to fix Microsoft and prop-up its future, look for opportunities to join that team. Less Pink, more you.

iPad: it's pretty. It's slick. It comes from a company where design is realized. It doesn't do as much as a PC, but it does enough. And by now everyone has been able to put together the pieces (e.g., Windows 8 demonstrated running on ARM) to figure out when Microsoft might release something that has similar form factor. But will it have the elegance and cohesiveness of the iPad 2, let alone the iPad 3? Will it be too late?

Should Microsoft release an iPad competitor, it will be THE defining moment for Microsoft's future: back in the game or game over.


-- Comments

Thursday, April 21, 2011

Microsoft's New Review and Compensation System - Now With More Cash!

"I am not a number, I am a free man!"

Well, at least we don't have a Six to give out.

Goodbye E/A/U + 20/70/10[I/II] and hello 1 to 5.

Kim, we just don't have a Limited to give to you anymore.

So we have a new review model. And a rework of our compensation. With cash, cash, cash. Forget that Microsoft stock because it's dead in the water and today's Microsoft employee is all about the paycheck. And if you actually work on creating products at Microsoft, you're getting an extra R&D bump.

And with the new 1 to 5 review score we have a new curve, too. 20% of you get a 1 (whoo-hoo!), 20% of you get a 2, 40% of you get a 3, 13% get a 4, and 7% get a 5. And probably fired.

Your review score is now a composite of: your results (where results, not effort, matters), what you did to get your results, and what your proven capability is. With an ideal that teamwork and feedback is now part of the review system, though it's not clear if feedback is mandatory via peer based reviews.

It's too bad that the internal InsideMS blog has been eradicated and wiped out of existence. It could have lived on a little bit longer so that the review system could be discussed there.

So what are your reactions?

Is the InfoPath-based review form dead? Please? Can we go back to a simple little Word form out of respect to our new simplified review score?

The next thing I think of, as a manager, is how is calibration now run. We used to do two stack ranks for the two review scores. Now we either do one or we do three (results, what was done for the results, and proven capability). Three seems crazy.

Next is whether this will indeed help retain employees. We've been losing a lot of good people and the Puget Sound area is ramping up in hiring. Google has always been draining people away. Facebook is now grabbing some great developers and Amazon is hiring like crazy.

So now you have some mystery amount of cash in your future to look forward to. And a simpler review score. But is that what you really want? Is that what you told LisaB during her Listening Tour? Given that Microsoft stock is in the toilet, does the future influx of cash coming in September make you feel better about working at Microsoft and will this make up for having reduced benefits (e.g., a new medical plan with more of that new cash out of your pocket)?

Will you be honestly told during the whole year how well you're doing so that you have frank feedback that helps you be fulfilled with your job? A problem with Stack Ranking is that leadership (once burnt by the review model) holds back praise due to the peer relative Stack Rank pushing a person down and then creating a "surprise" gap between the past praise feedback given and the review result earned. That's not fixed.

Anyway: let's celebrate saying goodbye to the 10% / Limited rating. Since the 10%-ers were not actually fired you ended up keeping people on staff who were designated as now plateaued and limited in there career at Microsoft. They had reached the end of of the ladder. These now demoralized individuals with no hope for future rewards or promotions should have at least been given a Peter Principle plaque or something.

Old school: with respect to the new Scarlet A, I assume that a 4 is the old 3.0 and that a 5 is a 2.5 and that having either a 4 or a 5 now limits other group's interest in your career, which kind of means that we've gone from making 10% of the employees unattractive to making 20% of the employees unattractive. We'll see if that's the case as this plays out of over time.

So, chair-rearranging or just what you were looking for?


-- Comments

Monday, April 11, 2011

Microsoft Dynamics AX 2012 Beta now available for download - please share your feedback

As some might have noticed, I was quiet for quite some time now. I won't go into much detail as to why. What I want to say is that I along with a number of dedicated people have been hard at work on the release of a solution for Process Manufacturing and Distribution industry, which is also available in Beta through the below links.

Those of you working in this industry, I would be grateful for your feedback on our work so far, as well as any bug reports or design change requests for the RTM version or future releases.
Any other feedback, especially on the development tools and environment, is also welcome, of course.


Virtual Machine: 

https://mbs.microsoft.com/customersource/downloads/servicepacks/AX2012DemoToolsMaterials


Installable bits (ISO & IS IExpress pkgs):

https://mbs.microsoft.com/partnersource/support/selfsupport/productreleases/AX2012Beta

MSDN Dev Center:



TechNet Library:

Thursday, January 27, 2011

Microsoft FY11Q2 Results

A quick check from the last Quarterly Results leading up to today's Microsoft Quarterly Results:

  • What's great: Kinect. We sold millions of Kinects and it's full of cool! And we have a 93% customer satisfaction rate with Windows Phone 7. Looking around, I think that's also assuming that 93% of Windows Phone 7 handsets sold are the Samsung Focus.
  • What's good: our reputation is working through the bothersome-hated-defeated-spurned-ignored-renewed-respected cycle compared to Google.
  • What's okay: Windows Phone 7: we sold some to non-employees and two-million licenses are in the channel. I have no idea what that means with-respect-to actually sold hardware. But it's no KIN, so... success! Yeah.
  • What's really, really bad: the iPad is gnawing away our laptop market. And a new version is coming out soon.

Hungry Hungry Cannibals: reading Ms. Friar's last beat-the-hell out of Microsoft Goldman-Sachs report just about made me permanently hungry for human flesh given the repeated fixation on cannibalization. I swear, I'd look up from my print-out occasionally and longingly eye my more fit co-workers.

It's the iPad baby, and - booga booga - it's going to destroy Microsoft. Well, at least destroy Windows.

First all: sure, Microsoft leadership deserves all the head-bashing it gets for both mobile and small form-factor markets. We had the jump on these markets with inelegant, uninspired devices that never had a chance of taking off with consumers and no one was bold enough to reboot the product line without successful leadership from Apple showing us the way.

Next: our iPad-compete strategy is unspoken. For good reason. Just about any application developer at Microsoft can tell you that it's a secret wrapped in red. Most Microsoft-observers have put the pieces together and figured out our strategy could be and realize who could be on point to deliver something exceptionally cool to compete with Apple. This will certainly could be our bet-the-company chance to validate the tortoise-vs-the-hare fable.

How have our past tortoises fared? I can think of three recent late to market responses: Zune HD (iPod - remember those?), Kinect (Wii), and Windows Phone 7 (iPhone / Android). All great devices. In order for our possible iPad compete story to be a success, it has to pull a Kinect and be beyond the competition vs. a me-too or, well, me-kinda-sorta.

CEO Changes: Mr. Ballmer's respect meter in the ephemeral tech-business... news (?) world is still low. Kinect has helped, but questions linger regarding what he's doing with his leadership team given Muglia's upcoming departure. I had always remarked to folks that Bob's a survivor. His time just finally ran out. It will be intriguing to see what leadership steps in or up and what happens to Bob's current team. And who might be next. Bets? Unless HR is about to unleash something huge that's been in the making my first bet is on LisaB. Also, Craig, I'd love to know what successes you've brought to the company as of late.

In the midst of Google and Apple going through leadership changes, you've got to ask: who is on the bench to replace Mr. Ballmer? What is the Board's plan? I have to reject Ms. Foley's point of view that there is no-one that can replace Ballmer. That's a too big to fail leadership jail sentence. Perhaps the decision is that his departure immediately results in a broken up Microsoft and the presidents he is putting in place now would be quite capable of running those sister corporations. Given the convergence and consolidation that is happening internally on a number of fronts for future development, such sister corporations would be much more dependent on each other, so it's not as whacky - or dog-eat-dog cannibalistic - as it might have seemed in the past. Given that the consent decree is considered over, Microsoft self-breaking itself up will certainly help prevent penalties when the inevitable violation occurs.

From another angle: if the Sinofskyfication of the company continues (IEB now with its massive re-org complete, post-Muglia Server & Tools next?) then Mr. Sinofsky ascending over a whole Microsoft will be a moot decision.

Interesting coverage after the results:

In general, no surprise to people that Windows/Live was down and that Entertainment was up on the Kinect. Online (aka Bing aka Partner-Level-Palooza) lost over half-a-billion dollars. And gained a bit of market share.

Pulling out my crystal ball that's covered with dust along with all the other Mini implements used to write this blog (oooo, an unopened bottle of Col Solare! Score!): Microsoft product groups should feel good about WP7 and the influence Metro is having around the company. Like I said, there's a big convergence ahead of us, and it will be good to start aligning a simpler development story, both for Microsoft and its partners. The biggest obvious concern is the development path for the mobile platform compared to the development path for Windows, but even there you can squint and see on the horizon the possibility for that to be successful, too.

IE9 is great technology that yes, has a way to go to score some high compliance number across a bunch of random folk's assessment sites. Still: wow. WP7 is a modern joy to use and is slowly building an app catalog. Kinect. And a whole bunch of developers hunched over and hammering bits to create the next big "Wow." Yeah, "Wow" might be inscribed on the back of a tortoise, but sometimes... the tortoise wins in the end.

The only thing that concerns me right now is (and you're going to love this): hiring. We've got great successes that excite people about working at Microsoft, but really, how many more people are we hiring to work on Kinect? My friends and I have never been so courted by other companies. Not since 2000. And I've got to say, the culture that Ballmer and LisaB have created is really weary. It's enlightened for the mid-1980s. But if crazy stock price jumps are no longer enthusing your employees, you've got to reboot the culture.


-- Comments

Thursday, October 28, 2010

Microsoft FY11Q1 Results

How about some FY11Q1 Microsoft earnings!

My usual suspects for earnings discussion:

Once more, with feeling.

I expect that we'll have yet another break-out quarter, a better idea that Kinect is poised to be a great seller for the holidays (sell-out pre-orders and screaming Oprah audiences can't be too wrong), and some glow from reasonable WP7 reviews (oh, and yes, we all realize that it doesn't have copy and paste - and yet the apocalypse will not arrive).

So this seems like a do-over with more good news from the last quarter. Will Wall Street react with the same "Meh?"

An interesting pre-earnings release article: Sleepy in Seattle - Microsoft learns to mature.

Again, not much love for Mr. Ballmer. So, since the last quarterly earnings, Ms. Friar at Goldman Sachs dropped a bomb on Microsoft and there's been serious concern that Mr. Ballmer is clearing the executive bench at Microsoft. Or is it cleaning house? Since we're unable to criticize any mistakes our departed leaders have made, it remains a big unknown.

iPad, iPad, iPad!

Once it was "Google, Google, Google." Now it's Apple's iPad meant to be Microsoft's undoing. First of all, major props to Apple's continued success. It's been a long journey for Steve Jobs and Apple - especially for those of us who read The Journey is the Reward back when it was new. I like my iPad. It's fun. It's also no notebook replacement. I'm not even going to use it for writing tweets on Twitter, let alone writing emails. It's for screwing around, and I like screwing around... so I like my iPad. I'm blessed that I've got the spare cash for such a luxury device and the spare time to play with it.

It's a new, quick consume experience that our Tablet vision failed to realize because our Tablet vision (like all visions of that time) was so firmly shoved up the Enterprise's butt we didn't care for consumers who'd pay good money to have a fun device to facilitate their screwing around.

We continue an expensive lesson in enlightenment. And spanking: Microsoft's consumer brand is dying.

And goodness help us if Apple TV takes off. Our inability to string together a coherent TV strategy (despite having been in the TV realm for over a decade) is yet another dropped pants embarrassment waiting to happen and represents the anxiety that Wall Street has about our future despite having successes in the present.

Bloodletting

Cost cutting's slippery slope continues. I'm sure if we don't talk about continued overhead management (people, benefits, etc) that it will be an analyst question. I still believe we need to chuck about 15,000 positions (and half of our super-ballooned contingent staff) rather than continue the slow squeeze around the company that's making this an ordinary job with some extraordinary wonderful people who just haven't given up on the company. Yet. I hope that the analysts realize that continued, consistent bloodletting because a negative for hiring, and (allow me to be pro-hiring for a moment) if we can't bring in deep-talented new blood to replace the departed dead wood, our future is doomed to mediocrity.

And that doesn't get you a good dividend.

New Talent

And we're losing the battle for hiring new talent. If you review who we're losing to, it's a big surprise. You look at who is ahead of us in preference and you say, "Really? Graduating students think they are a better place to work than us?" It's a cold splash of reality that makes me - they guy who said we've turned things around and things are going great for our major initiatives - wonder if things are worse outside of the Microsoft bubble than I thought.

Frank, you're fighting an epic battle.


-- Comments