tag:blogger.com,1999:blog-304647702009-07-10T22:29:30.512-07:00GonzoMaximus - The Lion in WinterRandom thoughts from a longtime FoxHead.Gonzohttp://www.blogger.com/profile/11393813410159124889noreply@blogger.comBlogger98125tag:blogger.com,1999:blog-30464770.post-16651149088255000822009-07-10T21:16:00.000-07:002009-07-10T22:29:30.524-07:00My Apollo 11 @ 40Looking back, I really can't explain what transfixed me about the space program. <br /><br />I was a little boy held in awe watching the last of the Mercury flights and then the Gemini series, when I could, on our Zenith console TV. I cried real tears when the deaths of the Apollo 1 astronauts were broadcast on the PA of my elementary school while most of my schoolmates looked at me as if I was crazy. I was vaguely familar with whom White and Chaffee were at the time but Gus Grissom was a hero! Gus Grissom died! A hero died!<br /><br />As all small children do I got over it pretty quickly. <br /><br />I recall not being impressed with the Apollo 7 mission because they didn't <em>go</em> anywhere. I didn't understand the concept of a safe mission to try out new hardware at the time. <br /><br />Apollo 8 filled me with a sense of wonder. They were orbitting the moon! The <em>moon</em>! Of course, I was distracted by Christmas and the anticipation of presents as I was all of 8 years old. Frank Borman was the media darling of that mission and he was added to my pantheon of heroes.<br /><br />Apollo 9 is a cypher to me. I can't recall anything about that shot. A pop song, the Monkees; something else must have taken front seat that I can't remember now.<br /><br />Apollo 10 I followed as closely as a 9 year old could. When the LM descended towards the lunar surface I was mentally begging them to continue on and land. I could not understand how they could get so close and not just go all the way. Oh, it was frustrating for a young and impatient space junkie.<br /><br />Then came 11. THE moonshot. I followed every little interview on TV and article in the paper - the Miami Herald in my neck of the woods. It was summertime and I had no school and no other responsibilities so I watched every televised moment of the mission. <br /><br />It's funny - every one talks about Walter Cronkite and Wally Schirra's telecasts of the mission as being the definitive broadcasts. I have to say that Cronkite's lack of technical savvy turned me off even at that young age even though I knew then, somehow, that he was a news icon.<br /><br />My TV hero for Apollo 11 was ABC News' Jules Bergman. The man knew his stuff. He would pick up his little models of the CM and LM and show how they worked and what they would do and you just knew he knew exactly what he was talking about. I also remember bit pieces on NBC by a very enthusiastic Jay Barbree who's still following NASA to this day. I don't know whatever happened to Bergman but he deserves attention for his insights and reporting.<br /><br />July 20 1969: I sat on the floor a few feet from the old Zenith console while my parents sat several feet behind on the couch when the Eagle landed, in the evening our time. It was Christmas and the Fourth of July all rolled into one for me. My parents, alas, were less than elated. The TV said that the astronauts would take a rest period before leaving the LM and that meant BEDTIME to the folks.<br /><br />I whined and cajoled and...just before being forced to bed the TV announced that the astronauts would be coming out soon! I reclaimed my spot on the carpet and watched various news analysts debate whther the men would sink into lunar dust and what other calamities may befell them.<br /><br />Finally, FINALLY, a bit after 10 PM they exited the LM. The static-laced images came through as well as Armstrongs famous first words: "One small step for (a) man, one giant leap for mankind". He then moved around a bit and, belatedly, the TV image was overlaid with a "MAN ON MOON" caption. Or something like that; I'm sure I could look it up but it would steal from the memory.<br /><br />After a while of watching my parent insisted I go to bed. It must have been around midnight and, frankly, I was so tired with anticipation and the excitement that I didn't complain. <br /><br />The next morning the Herald headline was "MAN ON MOON" in the largest type I had ever seen. I sat at our dining room table until my Dad was finished with the paper and passed it over to me (I had been an avid reader for a while by that time). I read it quickly and without depth; I waited for my Dad's attention to move elsewhere. Then I took the front page and stashed it in my room to keep what I thought was forever (It was destroyed by Hurricane Andrew in 1992).<br /><br />The later missions didn't impact me as much. I remember Shepard's golf drive and a few other things from the successful missions. The Apollo 13 crisis was surreal to me - I thought that NASA was infallible and that it was all going to be OK and it wasn't until years later that I understood how wrong I was and the depth of the crisis.<br /><br />I'm 49 now and it's almost 37 years since the end of the moon missions. In 1974 I had to do a report for school on the Space Shuttle. I thought it was a great idea but when I saw it was limited to low earth orbit I knew, even at that age, that human spaceflight was going to be limited to a low ceiling for a long time to come. So when Viking landed on Mars shortly thereafter I wanted; no, I <em>needed</em> proof of life to be found to give us a reason to go out again. <br /><br />Even if the most ambitious plans of NASA are funded to fruition, with typical teething delays, I'll be 70+ before a man walks on Mars. Buzz and Neil will no longer be with us. It doesn't seem fair.<div class="blogger-post-footer"><img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/30464770-1665114908825500082?l=gonzmax.blogspot.com'/></div>Gonzohttp://www.blogger.com/profile/11393813410159124889noreply@blogger.com0tag:blogger.com,1999:blog-30464770.post-13777859260705267162009-06-17T20:43:00.000-07:002009-06-17T20:52:41.258-07:00StandardsA smallish rant.<br /><br />There are a lot of IT departments out there who have rigid standards on every aspect of application development. Coding standards, naming standards, etc etc.<br /><br />Unfortunately, most shops have adopted standards as a means of control. Standards put in place for thus reason are often an actual impediment to the process of software design.<br /><br />Standards should exist for one reason and one reason only - to ensure reproducible quality in work performed. A standard should not detract from the process but should enable a quality bar.<div class="blogger-post-footer"><img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/30464770-1377785926070526716?l=gonzmax.blogspot.com'/></div>Gonzohttp://www.blogger.com/profile/11393813410159124889noreply@blogger.com1tag:blogger.com,1999:blog-30464770.post-39389888410268356092009-06-16T19:46:00.000-07:002009-06-16T20:05:48.473-07:00Hungarian Notation DiatribeSometimes I think coding standards are like fashion standards. Often, styles and notation are fawned all over one year and then criticized and passe the next.<br /><br />The current target of the code fashion moguls is Hungarian notation. That's the idea of prefacing a variable or object name with the type of variable or object.<br /><br />According to what I've researched, this is no longer needed because of Intellisense and cute little popups when you hover over code telling you all about the source of the entity. So, if you still use code conventions like btnEdit for an button with an Edit caption, you're some sort of reprobate.<br /><br />Interestingly, Microsoft stays away from this debate in code samples. To them, a Label is forevermore Label1 in sample code. I can kind of understand that since being an ex-Softie I remember the reluctance to embrace 3rd party"standards".<br /><br />Personally, I still use a type of Hungarian and probably always will. I don't see why it's such a bad thing to name a variable boolActive when it's a boolean flag or intChildren when it's an integer variable. Who does it hurt? It makes hard-printed code easier to read and it's easier to "digest" a block of code with its intent. The name of the variable or object has no impact on the stack or heap so what does it matter?<br /><br />Stupid code standard dweebs. Get a real job.<div class="blogger-post-footer"><img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/30464770-3938988841026835609?l=gonzmax.blogspot.com'/></div>Gonzohttp://www.blogger.com/profile/11393813410159124889noreply@blogger.com0tag:blogger.com,1999:blog-30464770.post-80787464128284992782009-06-11T21:19:00.000-07:002009-06-11T21:27:20.033-07:00VS 2008 Bug with Master PagesThis is really dumb.....<br /><br />I created a template that uses a Master Page with the skmmenu control - a very common menu control. With the template I have a default.aspx file that has nothing but a reference to the master page. Simple enough?<br /><br />When creating a web site based on the template, I get an "Error Creating Control" when I look at default.aspx. However, if I first click on MasterPage and leave it in Source view and then click on default page, the menu bitmap is shown and no error.<br /><br />Obviously, there's a synch issue here but even more obvious to me is that there are a group of testers in DevDiv at MS doing a shit job. <br /><br />It's becoming increasingly apparent to me that MS is pushing out code that isn't being vetted fully and UX (docs, examples) can't keep up either. C'mon guys....all the cool tools in the world won't help us out here in the real world if you don't testit or document it.<div class="blogger-post-footer"><img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/30464770-8078746412828499278?l=gonzmax.blogspot.com'/></div>Gonzohttp://www.blogger.com/profile/11393813410159124889noreply@blogger.com0tag:blogger.com,1999:blog-30464770.post-1689839998602321162009-06-08T14:25:00.000-07:002009-06-08T14:28:15.881-07:00ASP Menu Control and XMLDataSourceAlright, who's the dumbass who decided to make it so that it's very, very counterintuitive to create a horizontal menu strip using the ASP.Net Menu control with an XMLDataSource?<br /><br />Beat my head against this one all day. It's easy in code, easy in markup, but only ONE root node from XML? Gimme a break.<div class="blogger-post-footer"><img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/30464770-168983999860232116?l=gonzmax.blogspot.com'/></div>Gonzohttp://www.blogger.com/profile/11393813410159124889noreply@blogger.com0tag:blogger.com,1999:blog-30464770.post-22976997932073418672009-05-07T01:50:00.000-07:002009-05-07T01:51:27.809-07:00Great Songs/VideosOne of the best of recent years<br /><br /><a href="http://www.youtube.com/watch?v=AMryBJiGGqY">http://www.youtube.com/watch?v=AMryBJiGGqY</a><div class="blogger-post-footer"><img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/30464770-2297699793207341867?l=gonzmax.blogspot.com'/></div>Gonzohttp://www.blogger.com/profile/11393813410159124889noreply@blogger.com0tag:blogger.com,1999:blog-30464770.post-36777968742473484342009-05-01T00:13:00.000-07:002009-05-01T00:35:28.318-07:00Tech Surfing, USA!Sorry....thinking about the title got me to thinking of old 60's beach songs. Anyway...<br /><br />Being jobless for the last month put me into a lot of interview cycles. And, as is the wont, I was asked a lot of leading questions about my experience. How much do I know about Team Foundation Server? SQL Server 2008? WCF?<br /><br />One can always buffalo and claim experience when the truth is that very few have a great amount of experience in any of these things. I opted for the truth - "heard about 'em, read about 'em - and I'll learn 'em when it's needed".<br /><br />IMHO, anyone who claims expertise in anything in the development world with a shelf life of less that 2 years or so is a liar. Let's be honest here - a serious development project takes months of planning and requirements gathering. Serious and/or experienced developers don't bet the farm on brand-new technologies. They just don't unless they have really gullible clients.<br /><br />So...the project kicks off and is projected to last 6-9 months (an IT average - look it up - used to be 18 months). During that time the dev team is doing their best to implement functionality using what they already know, right? So where does the new stuff come in? That's shit they play with at home.<br /><br />SQL Server 2008? Gimme a break. Good DBAs don't mess with infrastructure without a compelling need. Sure, they might standup a SQL 2005 or 2008 database for a limited project but the business will likely be run on SQL Server 2000 ... maybe 2005.<br /><br />TFS is great. From a test perspective it's nirvana in that you can create and manage tests within a development project. And it supplants VSS - a longtime standard. So maybe it has more traction in newer projects.<br /><br />WCF? Everyone wants it, no one seems to really know it. It has reinvigorated looks into SOA architecture but we've had that since Web Services and SOAP and WSDL and all that junk came around in 2000.<br /><br />The botton-line point I am making is that a good skills assessment should be made on what was hot 3 years ago because those are the only technologies that anyone is going to have any real-world experience with. <br /><br />I am proudly ignorant of F#, cloud computing,and other current and future paradigms. Ask me again 3 years from now.<div class="blogger-post-footer"><img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/30464770-3677796874247348434?l=gonzmax.blogspot.com'/></div>Gonzohttp://www.blogger.com/profile/11393813410159124889noreply@blogger.com1tag:blogger.com,1999:blog-30464770.post-1077497638801862482009-03-17T20:21:00.001-07:002009-03-17T20:26:42.571-07:00The Invaders!Something possessed me to add the old series, The Invaders, to my Netflix queue a few months ago. I vaguely remembered liking it when I was a kid when it first came out n 1967. So far, I've seen several of the original episodes and, man!, what a great show that was!<br /><br />It's done by Quinn Martin,the same guys who did The FBI and The Fugitive and it has the same hallmarks: Voiceover intro and ending, "Act I", "Act II", et al.<br /><br />The premise is that some guy sees an alien spacecraft land and can't convince anyone of it. Meanwhile, while he's checking it out, his home is burned down, the police think he's nuts, and his business partner dies. So now he's on the run hunting them down each episode.<br /><br />Great show and it's an obvious influence on later shows like the X-Files.<div class="blogger-post-footer"><img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/30464770-107749763880186248?l=gonzmax.blogspot.com'/></div>Gonzohttp://www.blogger.com/profile/11393813410159124889noreply@blogger.com1tag:blogger.com,1999:blog-30464770.post-57935127234202593872009-01-08T22:13:00.000-08:002009-01-08T22:25:05.018-08:00Cat - Raccoon DetenteIf I hadn't seen it with my own eyes I'd never have believed it.<br /><br />My family owns a cat that is the most peace-loving, mellow cat ever born. This cat had never attacked another animal as far as I know. It loves to go out on our back deck and watch the squirrels carry on and the squirrels have accepted the fact that it's a passive observer and will parade right in front of it without fear.<br /><br />Sometimes I leave unsalted peanuts out for the squirrels and, the other night, there were several that the squirrels had missed. As I was reading on the back porch I saw a raccoon come up to the deck and - timidly - start to grab and each the nuts. Meanwhile, my cat came to the back porch door and wanted out. With some trepidation I let him out.<br /><br />The cat went about halfway across the deck before noticing the raccoon. The raccoon backed off and started making itself look bigger by extending it's forearms and trying to look menacing. My cat just stood there looking left and right and never directly at the raccoon.<br /><br />The raccoon advanced on the cat and got face-to-face and started swishing it's forearms and snarling. The cat continued to act non-chalant. The raccoon then took a few steps back and reapproached the cat peacefully, nodding it's head up and down.<br /><br />It walked right up to the cat and both animals sniffed each other nose to nose. Satisfied, the raccoon resumed eating nuts while the cat sat scant inches away without a care in the world. <br /><br />I called the cat in that night but the next night I let the cat out and a few minutes later saw my cat *playing* with the raccoon. Every few minutes the animals would stop playing and do a "kissy, kissy" with the noses again. It was clear that they enjoyed each others company.<br /><br />Is that normal or am I raising the Gandhi of cats?<div class="blogger-post-footer"><img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/30464770-5793512723420259387?l=gonzmax.blogspot.com'/></div>Gonzohttp://www.blogger.com/profile/11393813410159124889noreply@blogger.com1tag:blogger.com,1999:blog-30464770.post-54272320436717634632008-12-22T21:25:00.000-08:002008-12-22T21:40:27.337-08:00Burnin' For YouMy stupid science project:<br /><br />Sometimes I can be a doggone good engineer but I don't build well. Therefore, half of my projects end up as scattered notes in a drawer or very cool diagrams somewhere else.<br /><br />I've been studying radioisotope thermal generators (RTGs) for some time and think I've come up with a half-decent design for a heliothermal generator using focal mirrors and off-the-shelf thermocouples. Essentially, think a heat collector with thermocouples back-ended into a cool granite block for maximum temperature gradient.<br /><br />My generator would look like a very shiny satellite dish about 18-20" in diameter focusing solar heat on a "hockey puck" containing the ends of about 50 thermocouples. The others ends are sheilded and pass into a granite block or other thermal-negative material to maximize electrical potential.<br /><br />The math indicates I might produce about 380 Watts at 1vA under optimal conditions. Cool, huh? <br /><br />I see more notes in more drawers in my future :-)<div class="blogger-post-footer"><img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/30464770-5427232043671763463?l=gonzmax.blogspot.com'/></div>Gonzohttp://www.blogger.com/profile/11393813410159124889noreply@blogger.com0tag:blogger.com,1999:blog-30464770.post-12442249746278163472008-12-16T20:04:00.000-08:002008-12-16T20:42:40.967-08:00Live! (Almost) From the Atlanta MSDN Developer ConferenceSorry there was no "heads-up" on this one; I've only known that I would be attending for the last few weeks. Normally I'd have posted something that I'll be at event X on day Y but my work schedule and the craziness of this time of year precluded that.<br /><br />The Atlanta (and other cities) MDC is meant to distill critical developer sessions from PDC into a one-day event. I talked with a 'Softie about the purpose and execution of the event (dude, sorry, didn't note the name) and it seems that MS was not entirely convinced this was not a good idea since, at $99 per registration with speakers and MVPs comped, it was going to cost the company money.<br /><br />Well, IMHO, I got more bang from the buck at this one day event than I have from any other in quite some time. If you'll excuse the phrase, MS went balls-to-the-walls and showed off a lot of stuff coming down the road that was definitiely ooh-and-ahh. <br /><br />In the keynote alone, superbly managed by Ron Jacobs, we got doses of Azure and cloud computing, "Geneva", new SQL Services, Live Services, Silverlight/VS 2010 stuff, and Windows 7.<br /><br />Ron used an interesting analogy to being aware of future technologies - he said is what like playing Age of Empires online and managing your kingdom only to find it rushed by your competitior without warning. I thought at first he was a bit melodramatic and was heavu-handed with the point but then, later, settled into more concrete and less fearful uses of the analogy.<br /><br />My main take-away from the keynote was the unbridled enthusiasm and hope for Windows 7. Yes, "hope" not "hype". Ron was very open about what Vista falldowns are overcome by Windows 7 and showed a bit of a cool demo using the new HP touchscreen PC (which further justified my upcoming purchase of that machine - In your face, Tray!!)<br /><br />Yeah, I could post a kool-aid faux knowledgable lie about the other things he talked about and say how wonderful they were since he used the stock phrase "isn't that cool?" enough times but, honestly, I am not familiar enough with the technologies to pass judgement and I'm not one to gush on hype. I have grown very conservative over the years judging upfront how a new platform or technology will service me and my customers so no insult intended for Ron or my former employer.<br /><br />A friend from the Fox world, Alan Stevens, presented on the future of managed languages and cool stuff like JQuery (damn, now I'm doing the cool thing). Alan did a great, great job. Allow me an aside for a moment, this conference had a room christened the "Community Courtyard" with whiteboards and seats to discuss things. Alan *openly* sought out people looking for more information and then ran informal seminars in that room using the whiteboards and a clear, consistant manner to answering questions and directing the discussion. A few of the other speakers added commentary but Alan captivated about a dozen folks with expert insight into a variety of web architectural scenarios. It's easy to find technology experts, people persons, and great teachers, but it's RARE to find all in one guy. If MS doesn't hire this guy or make him a permanent addition to their speaker list they're missing the boat.<br /><br />I continued to attend sessions in the Tools and Languages track and, thankfully, my co-workers attended sessions in other tracks so Advanced Systems Design got a full knowledge spread from their attendees.<br /><br />I'm still digesting and I'll undoubtedly post more in the coming days as it occurs to me. It's almost midnight and I'm really tired from the 5 hour drive. I didn't immediately learn a lot but I never do from 75 minutes of being dictated to. However, I did have my interest piqued a-plenty and saw many things to be on the lookout for in the future.<br /><br />Hey, Microsoft! Great job by your regional folks and you should do this every year. Thanks!<div class="blogger-post-footer"><img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/30464770-1244224974627816347?l=gonzmax.blogspot.com'/></div>Gonzohttp://www.blogger.com/profile/11393813410159124889noreply@blogger.com1tag:blogger.com,1999:blog-30464770.post-41764533350336562782008-12-12T23:04:00.001-08:002008-12-12T23:14:02.616-08:00Being There (Part Two)I have to make this post to clarify a position since my Inbox indicates that my message was received as an indictment against VFP.<br /><br />In a nutshell I said in my last post that I had disengaged from speaking about Fox or otherwise encouraging the Fox community because I thought it was akin to leading folks down a dead-in path.<br /><br />What I <strong>DIDN'T</strong> say is that Visual FoxPro is a bad product or development platform. In fact it is my opinion that to this day and for some time to come Fox is a superior tool for delivering Windows-based line-of-business applications. It is also a superior tool for creating COTS applications involving heavy data.<br /><br />VFP is the victim of indifferent marketing and secondary product placement. Not bad engineering. Good Fox apps will trump a lot of other apps in the Windows environment when written by good devs.<div class="blogger-post-footer"><img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/30464770-4176453335033656278?l=gonzmax.blogspot.com'/></div>Gonzohttp://www.blogger.com/profile/11393813410159124889noreply@blogger.com1tag:blogger.com,1999:blog-30464770.post-26477084406818324672008-12-06T23:59:00.000-08:002008-12-07T00:29:20.487-08:00Being ThereMy current employer has invited me to attend a one-day DevCon in Atlanta later this month. I accepted the invitation not because I was all that keen on attending but because I really like these guys and if they want me there I'll go.<br /><br />As is probably obvious to thoise who know me, I've totally backed off of the conference scene - with the possible exception of the March MVP Summit. I don't respond to Call To Speakers and I don't solicit invitations to speak or attend conferences.<br /><br />Why?<br /><br />Several reasons. <br /><br />While I cherish my part in the Fox community I can't see myself speaking to that community anymore because I don't have a good feeling about the viability of being a Fox developer in the future. Yeah, I could stand there and give a rousing presentation on CursorAdaptors or MemberClasses; I mean, I really know that stuff. But it would feel wrong to me; I would feel like the 50's actor standing on stage talking about the motivations of his character in a lesser-known movie from that era.<br /><br />I am busting butt to ramp up my .Net skills. That's what I now do for a living but it'll take time for me to get to the same level of skill that I have/had in Fox. Therefore, I don't feel comfortable presenting in that area as well.<br /><br />Finally, as a former member of the Microsoft VS Data team, people may expect me to have knowledge and skills that I don't have since all of my time there was spent on VFP. I don't want to look like a doofus. I'm not ready to live up to the expectations others would have of me because I was at MS during the release of .Net.<br /><br />It would be easy - very easy I imagine - to parley my past into numerous speaking and writing engagements centered around Fox. But whom would I be serving? If I go out and tell developers that Fox is great, Fox is cool, and look what can be done!, aren't I forestalling them from considering other languages and professional growth?<br /><br />Maybe I'm being maudlin but I believe I have an obligation to the hundreds of friends and the thousands of people who know me by reputation. That obligation is to not push folks towards technologies that are dying. It's to hold up a lamp in the storm and help point a way through the storm knowing I'm not a navigator.<div class="blogger-post-footer"><img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/30464770-2647708440681832467?l=gonzmax.blogspot.com'/></div>Gonzohttp://www.blogger.com/profile/11393813410159124889noreply@blogger.com2tag:blogger.com,1999:blog-30464770.post-38723641078610060472008-11-26T11:08:00.000-08:002008-11-26T11:24:44.404-08:00Common Table ExpressionsSomeone I work with turned me on to SQL Server 2005 Common Table Expressions (CTEs) a few months ago and I'm really starting to get into them. <br /><br />CTEs are ways to create a derived set of data; sort of like a view but it doesn't persist in the database after being used. Here's a simple example:<br /><br /><span style="font-family:courier new;font-size:85%;">WITH ProductSales (ProductID, ProductName, TotalSales)</span><br /><span style="font-family:courier new;font-size:85%;">(</span><br /><span style="font-size:85%;"><span style="font-family:courier new;"> SELECT product.ProductID,</span><span style="font-family:courier new;">product.ProductName, </span></span><br /><span style="font-family:courier new;font-size:85%;"> TotalSales = (SELECT SUM(Quantity) </span><br /><span style="font-family:courier new;font-size:85%;"> FROM salesdetail </span><br /><span style="font-family:courier new;font-size:85%;"> WHERE salesdetail.ProductID = product.ProductID)</span><br /><span style="font-family:courier new;font-size:85%;"></span><br /><span style="font-family:courier new;font-size:85%;"> FROM product</span><br /><span style="font-family:courier new;font-size:85%;">)</span><br /><br />You then use SELECT * FROM ProductSales to get the results. Actually, you have to immediately query the results before doing any other non-CTE SQL.<br /><br />I wonder if this is something we should have thought of for Visual FoxPro 9. Probably would have if Gene Goldhammer hadn't retired since he tended to think about new data features.<div class="blogger-post-footer"><img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/30464770-3872364107861006047?l=gonzmax.blogspot.com'/></div>Gonzohttp://www.blogger.com/profile/11393813410159124889noreply@blogger.com0tag:blogger.com,1999:blog-30464770.post-36452377155200488262008-11-22T19:45:00.000-08:002008-11-22T20:12:30.069-08:00Bits of MadnessI ran into an odd situation this week while coding a webform with Yes and No radiobuttons using the RadioButtonList control. <br /><br />Traditionally, Yes and No are presented in a control with Yes being first. Therefore, in a .Net RadioButtonList control, the Index value for Yes is 0 (zero), while the Index value for No is 1. Being the old traditionalist that I am, I assigned 0 to the Value property for No and 1 to the Value for Yes.<br /><br />This is an unbound control but is sourced to a Bit column in a SQL Server table. A Bit column is referenced in T-SQL as 0 for No and 1 for Yes, for example:<br /><br />UPDATE mytable SET mybitfield = 0<br /><br />This would set MyBitField to No.<br /><br />When I grab this column into a Dataset in Visual Studio and want to convert it into an integer, I use the CInt function. CInt, though, converts a Yes to -1 and No to 0.<br /><br />So now we have the following for my simple radiobuttons:<br /><br /> Yes No<br />Control.Index 0 1<br />Control.Value 1 0<br />MyBitField 1 0<br />CInt("mybitfield") -1 0<br /><br />And this makes my head hurt <g><br /><br />The simple solution is to assign Control.SelectedValue to Abs(CInt("mybitfield")) which will convert the -1 to 1 and leave the 0 values as is. But others might scratch their head while reviewing the code.<br /><br />Another way to simplify this would be if I changed the control so that No came first, changing the control from Yes / No to No / Yes. That, however, goes against the way people think. I don't recall hearing anyone talk about a "No / Yes situation". I guess I could also reverse the assigned Values for the control so that No is 1 and Yes is 0 but that doesn't feel right either. <br /><br />Sigh. Leave it to Microsoft to complicate something as simple as Boolean logic.<div class="blogger-post-footer"><img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/30464770-3645237715520048826?l=gonzmax.blogspot.com'/></div>Gonzohttp://www.blogger.com/profile/11393813410159124889noreply@blogger.com0tag:blogger.com,1999:blog-30464770.post-38621141461828672162008-11-21T23:09:00.000-08:002008-11-21T23:33:39.217-08:00Been A WhileI've been coding my ass off. Plus, my wife accepted a new position about 5 weeks ago and she's now working 60 hours a week making my "free" time an exercise into being a more complete Mr. Mom along with my 40-50 hour a week work.<br /><br />Some of you all are going to hate me but I've backed off of the VFP to .Net bootcamp idea because, in all honesty, the more I delve into this the less I see for an open-minded, dedicated, and professional developer to overcome. I'm sorry but it's just not that freaking hard what with the extensive online support forums and a learned approach.<br /><br />I still hope to make the next MVP Global Summit as a guest of the lovely and brilliant Ms. Pountney...that's looking good! I can't wait to see old friends and co-workers. When I left MS 3 years ago I was suffering a lot of personal issues and I didn't believe I was being treated fairly by HR but I rarely held it against my team members (with one exception who is no longer with the company). For me it'll be emotional....it will be great to see them all.<div class="blogger-post-footer"><img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/30464770-3862114146182867216?l=gonzmax.blogspot.com'/></div>Gonzohttp://www.blogger.com/profile/11393813410159124889noreply@blogger.com0tag:blogger.com,1999:blog-30464770.post-66789741890167587962008-09-27T14:11:00.000-07:002008-09-27T14:16:28.267-07:00SporeThere's a new game out called "Spore" by Electronic Arts. It was designed by Wil Wright, the designer of SimCity. In Spore, the player evolved a species from a single-celled organism to a pan-galactic empire interacting on-line with other player empires.<br /><br />I don't own Spore. I'm afraid to buy Spore. Given my previous addictions to SimCity, Civilization, and Masters of Orion I am deathly afraid of the addictive nature of Spore.<br /><br />Spore: Be afraid. Be very afraid!<div class="blogger-post-footer"><img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/30464770-6678974189016758796?l=gonzmax.blogspot.com'/></div>Gonzohttp://www.blogger.com/profile/11393813410159124889noreply@blogger.com0tag:blogger.com,1999:blog-30464770.post-59739695591120118212008-09-22T18:42:00.001-07:002008-09-22T18:56:03.286-07:00VFP to .Net ArmageddonI cobbled up an article for <a href="http://www.vfug.net/">VFUG</a> about how Fox folks could apply legacy skills to web development in VS.Net I have to admit, though, that I could only get into the grossest points of the topic since it's a "mile-wide" topic and no single article does it justice.<br /><br />Frankly, I'm not qualified to write a series of articles on all the particulars because I'm still figuring out a lot of it for myself. I'm heartened by my findings that my legacy skills as a Fox coder since 1986 are translateable but it'll take me years to become an authoritative source on the subject matter in totality.<br /><br />Meanwhile, there seems to be a disconnect between early adopters of .Net from the VFP ranks and the rank and file. I'm not sure why. It may be that the general feeling is that the early adopters have it all figured out and are talking down to the VFP base. I know that's not the intent and I'm not trying to flame anyone.<br /><br />Do we need a VFP to .Net bootcamp? I think so. Not some marketing BS or a con that glosses over topics but an honest to goodness Marine Corps style bootcamp? Hands-on, bring your laptops, share, explore, learn???<br /><br />Some feedback, folks? I'd love to organize such an event but your valuable comments will help sway my decision.<div class="blogger-post-footer"><img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/30464770-5973969559112011821?l=gonzmax.blogspot.com'/></div>Gonzohttp://www.blogger.com/profile/11393813410159124889noreply@blogger.com5tag:blogger.com,1999:blog-30464770.post-90565308627088717942008-08-13T20:23:00.000-07:002008-08-13T20:26:41.249-07:00Freaking Checkboxes....<soapbox><br /><br />Why on earth do checkboxes not have both readonly and enabled properties and have the same behavior as other input controls with these properties? This is retarded and really hurts consistent UI design. <br /><br /></soapbox><div class="blogger-post-footer"><img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/30464770-9056530862708871794?l=gonzmax.blogspot.com'/></div>Gonzohttp://www.blogger.com/profile/11393813410159124889noreply@blogger.com0tag:blogger.com,1999:blog-30464770.post-78978407025292672112008-08-13T20:14:00.000-07:002008-08-13T20:23:12.669-07:00Useful .Net stuffWeb work in .Net .....<br /><br />I was deliberating between using a skin and a CSS for a control. The problem was that I needed to modify the behavior of a control and skins are only used, supposedly, for display properties. On a lark, I defined the behavior I wanted in my CSS file:<br /><br />input.calculatedfield<br />{<br /><br />text-align: right;<br /><br />}<br /><br />And then in the .skin file I added to the skin definition:<br /><br />CssClass="calculatedfield"<br /><br />To my surprise, this worked! The control, in this case a TextBox, inherited both the display attributes of the skin and the alignment behavior of the stylesheet.<br /><br />Another tip for web newbies: Avoid the MS Sans Serif and Arial fonts. They only display well at 10pt and above size. Try Tahoma font, which looks great at 9pt and will save you about 15% or so of screen space.<div class="blogger-post-footer"><img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/30464770-7897840702529267211?l=gonzmax.blogspot.com'/></div>Gonzohttp://www.blogger.com/profile/11393813410159124889noreply@blogger.com0tag:blogger.com,1999:blog-30464770.post-1666305586220108822008-08-12T19:27:00.000-07:002008-08-12T19:30:16.062-07:00Upcoming VFUG ArticleI agreed to write an article about .Net for VFP folks. Lately, I've been working with ASP.Net and web stuff exclusively but I see a lot of "hooks" that I think will register with the Fox faithful. There are a lot of parallels and I don't see where anyone has drawn those similarities together. I'll do my best!<div class="blogger-post-footer"><img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/30464770-166630558622010882?l=gonzmax.blogspot.com'/></div>Gonzohttp://www.blogger.com/profile/11393813410159124889noreply@blogger.com1tag:blogger.com,1999:blog-30464770.post-74067153741959019372008-07-27T10:37:00.000-07:002008-07-27T10:40:42.097-07:00Good BuddiesI had a chance to chat with Randy Brown, formerly of the Fox Team, the other night. We had a great conversation. I am sometimes terrible about keeping up with people and haven't spoken with Randy for a few months.<br /><br />He's getting married on the 9th of August and his fiance delivered a beautiful baby girl on June 6th. My family wishes his family all the best.<br /><br />Here's a link to some baby pics on Flickr.<br /><br /><a href="http://www.flickr.com/photos/randybr/sets/72157605562372633/">http://www.flickr.com/photos/randybr/sets/72157605562372633/</a><div class="blogger-post-footer"><img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/30464770-7406715374195901937?l=gonzmax.blogspot.com'/></div>Gonzohttp://www.blogger.com/profile/11393813410159124889noreply@blogger.com2tag:blogger.com,1999:blog-30464770.post-59870411191980902632008-06-26T17:35:00.000-07:002008-06-26T17:52:27.459-07:00Technical FixationEver noticed that when some coders learn a new technique they apply it like slathering butter on bread even where it makes no sense?<br /><br />I'm re-engineering a web page where there is a parent-child relationship between two entities akin to a user and what rights they might have. The original coder used two listboxes to show assigned and available rights (good!) but then used checkboxes in each listbox row with a check all box in the header (the newly learned technique). To move rights around you check your butt off and then hit Save changes.<br /><br />What the hell? I'm replacing it with the traditional mover lists construct while enabling multiple selections in each list. A lot fewer mouse clicks when moving shit around and conforms to a better understood standard, IMHO.<br /><br />To paraphrase an old saying, if builders built buildings the way some web designers code web pages the first woodpecker to come along would destroy civilization.<br /><br />I go back to what I keep preaching: Experienced Fox coders should run absolute rings around pure .Net weenies if they put up the intellectual investment to learn the syntax and idiosyncrasies of .Net. MS has had problems with migrating VB 6 coders to VB .Net and adoption of VB .Net has been slow. Wanna know why, IMHO? Because most VB coders couldn't architect their way out of a bird fountain. Experienced VFPers understand the interconnection between all aspects of the application and think long and hard about the architecture, meaning UI and classlibs, before writing a line of code.<br /><br />You all could be rockstars. My sole regret is that it took this long for me to get this deeply involved with .Net not to see it.<div class="blogger-post-footer"><img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/30464770-5987041119198090263?l=gonzmax.blogspot.com'/></div>Gonzohttp://www.blogger.com/profile/11393813410159124889noreply@blogger.com0tag:blogger.com,1999:blog-30464770.post-77422723297365185172008-06-22T20:59:00.000-07:002008-06-22T21:21:56.341-07:00A New Neurophysical TheoryOK, this is complicated, bear with me. <br /><br />I spent the day today watching the rebroadcast of Carl Sagan's <em>Cosmos</em> on the Science Channel. My wife, Teri, flitted in and out without a real interest in the show. After 18 years of marriage, I'm used to that - my sense of awe and wonder not being reflected back is common - she just doesn't care.<br /><br />It sometimes bothers me. I know my wife is intelligent and I always took her lack of interest in science or history as an affront; a personal insult since - to me - a lack of interest was a vague reproof since she <em>obviously </em>had the brains to comprehend the material.<br /><br />I know she loves me and wouldn't want to hurt my feelings, so there had to be another answer. Sagan inspired, I began to think about what was going on. I came to what I believe is an answer that has profound implications in a lot of areas.<br /><br />What if she doesn't care about these topics because she's not genetically or intellectually predisposed to do so although entirely capable? Is it possible that there is an evolutionary governor in our brains that sets limits to the amount of interest we should show in certain topics?<br /><br />I think it would be part of the survival mechanism. What good does it do for an individual to be too wrapped up in looking at the stars if a sabertoothed tiger is coming in for the kill?<br /><br />Is there a mechanism in our brains that limits our interests in areas that have no direct bearing in our personal survival in the here and now? Is this why so many kids have a hard time learning abstract math like Algebra? <br /><br />Are those of us who yearn for more information about the Universe and read history genetically inferior because we are diverting energies away from attention directly related to personal survival and the propogation of species?<br /><br />Does evolution put soft barriers in our minds - "No, no you don't have to think about that" on certain subjects? Is that barrier elastic insofar as it can be stretched when an area of thought is linked to another area the brain thinks is important? I think so.<br /><br />So many things make sense if my hypothesis is applied. I'm sure I'd word all of this better if I was a psychiatric clinician. <br /><br />I wish I could explain it better.<div class="blogger-post-footer"><img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/30464770-7742272329736518517?l=gonzmax.blogspot.com'/></div>Gonzohttp://www.blogger.com/profile/11393813410159124889noreply@blogger.com6tag:blogger.com,1999:blog-30464770.post-59216585800202943552008-06-18T16:08:00.000-07:002008-06-18T16:20:22.176-07:00What, This is Hard?More time diving into the peculiarities of the .Net Framework...<br /><br />I have to say that I am not finding this very hard at all. Granted, I can't do UI design using Divs and such in ADO to save my life (mental block - I expect things to be rendered where I goddamn put them) the coding is nothing that any other experienced VFP-er would take very much time to learn.<br /><br />In fact, I'm coming to actually love the way this all holds together. Mind you, this project is stuck with 2.0 Framework and I'm sure that a lot of what I'm grinding through is better handled in 3.0 and 3.5. <br /><br />Still, though, there are weirdnesses that I guess are better handled by experience. It's the same in VFP, I suppose, but I had years and years and professional incentive to master those oddities. I'm now exposed to the firehose. <br /><br />Example: If you include a column in a GridView but don't actually show it, the value is blank. WTF??? I can't count the number of times I had a primary key stashed in a ListBox or Grid in VFP and made it's length zero just so I could grab the value from the selected row when needed. Nope, not in .Net unless you use a Template field (I think that's what it is called - kinda away from .Net at the moment).<br /><br />I'm finding that I leave a lot of my control state code (what's visible, read only, etc.. based on selections and environment after a postback) in the Page_PreRender method. Is that good practice? Dunno...works for me.<br /><br />I'm heading in the direction of either being a damn good .Net coder or a damn bad one. Haven't figured that out yet; it may be years before I do. I wish I could get out to a con and bang heads and compare notes with McNeish or Markus to get a better feel. For now I have to operate under the guideline that if it works, it must be good code.<div class="blogger-post-footer"><img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/30464770-5921658580020294355?l=gonzmax.blogspot.com'/></div>Gonzohttp://www.blogger.com/profile/11393813410159124889noreply@blogger.com1