# Saturday, February 28, 2004

Returning typed data sets from a web service

For my DataStream column in asp.netNOW, I happened to pick the subject topic for the installment I turned in Monday and that should go out any day. Then I see this post from Kirk. Damn, I hate when people come up with better solutions that me, especially when I just published mine in a widespread form.

The solution I wrote about is to simply merge the data into an instance of the common typed data set type from the web service proxy created typed data set. Works fine, but has the overhead of copying over all the data.

With Kirk's solution, no copying. Cool.



.NET

Saturday, February 28, 2004 1:36:48 AM (GMT Standard Time, UTC+00:00)
Comments [0]  | 


 # Thursday, February 26, 2004

Does blogging on your own site hurt?

I am starting to wonder if I would get a lot more traffic by blogging on one of the mass aggregation sites like weblogs.asp.net or the new MSDN weblogs, rather than hanging off my own obscure site.

Any thoughts, those few of you who have stumbled onto my blog and actually read it?



Blogging

Thursday, February 26, 2004 2:46:43 PM (GMT Standard Time, UTC+00:00)
Comments [0]  | 

Back from Chicago for a few days

I have been in Chicago for the past few days teaching a tailored version of our .NET Master Class to an investment company who is heavily vested in FoxPro development but are making the leap to C# and .NET for the future. Good for them!! They have seen the light and are now well educated to follow it. I'm going back for two more groups of devs for the same company in the next few weeks.

I love teaching .NET to groups like this because it really teaches me a lot seeing how devs with completely different backgrounds adapt to and adopt .NET, and I love seeing their excitement at getting to take on such a cool new development experience.



.NET

Thursday, February 26, 2004 2:44:02 PM (GMT Standard Time, UTC+00:00)
Comments [0]  | 


 # Friday, February 20, 2004

Finding File info with WMI in managed code

When WinFS comes around life will be much improved with respect to obtaining information about files stored on your system. For now, there is a mishmash of things you have to do depending on what information you are going after. If you need basic file attributes, you use the FileInfo object. If you need information about the content, you will usually have to open the file and do some form of parsing. If you want security related information, you will have to go through either a Win32 API or WMI in many cases.

I had someone at the Richmond.NET group I spoke at last night come to me with what seemed like a simple question: How do I get the owner of a file? My first reaction was that it should be part of the file attributes accessible through the FileInfo object, but that was not the case. A little digging revealed that particular piece of information is treated as part of the security information associated with a file in NTFS, and would not be available in Win98/Me.

Next look was at the Win32 APIs, and sure enough there is a fairly straightforward way through the GetSecurityInfo API, but that meant doing a lot of PInvoke interop, which I like to avoid if at all possible. It occurred to me that WMI probably had a way in, and that led me to a easy solution posted on the Experts Exchange site by “The Learned One”.

Here is a distilled version of what he presented, in C# instead of his VB.NET:

private string GetFileOwner(string path)

{

ManagementObject mgmt = new ManagementObject("Win32_LogicalFileSecuritySetting.path='" + path + "'");

ManagementBaseObject secDesc = mgmt.InvokeMethod("GetSecurityDescriptor",null,null);

ManagementBaseObject descriptor = secDesc.Properties["Descriptor"].Value as ManagementBaseObject;

ManagementBaseObject owner = descriptor.Properties["Owner"].Value as ManagementBaseObject;

return owner.Properties["Domain"].Value.ToString() + "\\" + owner.Properties["Name"].Value.ToString();

}

The key to working with WMI is figuring out the right objects, methods, and properties to access. Once you get used to the hierarchical approach of the object model, it is fairly easy to thread your way through and find what you need in the WMI documentation, and then translate that into System.Management class calls you need to make.

Keep in mind that many of the things you can do with WMI require administrative privilege. If you are expecting people to be able to use your app as non-admins, make sure you test it out to make sure the things you are doing are not privileged operations. In the case of the queries above, you can just be a standard user account in windows running this code and it works fine.



.NET

Friday, February 20, 2004 9:26:04 PM (GMT Standard Time, UTC+00:00)
Comments [0]  | 

Do my project for me

OK, so I just don't get this, but it happens all the time...

In other countries, is it acceptable to walk up to a total stranger and demand that they devote significant amounts of their time to perform some task to make your life easier?

Maybe it is just a language barrier thing, but because of my email being all over the place in my article bios, I frequently get emails like the one I got yesterday. This one basically read something like this (shortened considerably):

Hi, i need to do a project for a class. Here is the project assignment:
...
I need your help to proceed. Please tell me how you would do this project.

Now I do my best to help out any readers or people who attend my talks who write me with questions, whether they are specific to the topic or not. But these kinds of emails just drive me nuts. I want to respond and politely explain that I do not have the time to help them, but the sarcastic person in me just wants to write something like:

Can I drop everything I am doing in my life and do your work for you? Absolutely!! Why not?? It is what I live for!!



Community

Friday, February 20, 2004 1:55:41 PM (GMT Standard Time, UTC+00:00)
Comments [0]  | 

A night at Richmond.NET

I gave a talk on the User Interface Process block last night at the Richmond (VA) .NET User Group last night. What a great group!! Thanks much to Mike Richardson and Greg Robinson and the rest of the folks down there for having me down! Had a standing room only crowd in a big room (maybe 80+ people?). Very good crowd, considering Richmond is not that big of a town. Heck we only get about half that many on a regular basis at CapArea.net, the DC area group that I help run with Scott Lock, Alec Minor, and Hal Hayes. Maybe we need to get some advice from Mike on how he is marketing his meetings.

I think it went pretty well, although I was shaking off the adrenaline at the beginning of the talk of thinking I was not going to make it in time. Thought I was being pretty conservative allowing 4 hours for the 100 miles from DC to Richmond, but not so. Only made it with 10 minutes to spare, 3 hours of the trip being spent on the first 50 miles. DC traffic is just... well, you do the math.



Community

Friday, February 20, 2004 1:46:06 PM (GMT Standard Time, UTC+00:00)
Comments [0]  | 


 # Saturday, February 14, 2004

A Day in the land of Oracle

I'm working on a project for a customer that I have mentioned before that is a Java web app using Oracle products. I know, what is a .NET guy doing this for? Trust me, I have tried hard to persuade the customer's customer that they would be better off with a .NET solution to no avail. They dictated an Oracle/Solaris architecture before the project even started to maintain platform homogeneity within their network, so we are stuck with that.

We are just getting started into the design phase (yes, a waterfall process also dictated by the customer... do these people never learn??), and trying to nail down the technologies and software architecture we will use given the constrained enviroment. It is like trying to learn a foriegn language in some ways. The basic architectural concepts are the same, but the terminology, libraries, technologies you use to achieve it are all very different.

The other thing that is weird is the low community support structure in the Oracle world. After much searching of the Oracle Tech Net and the web in general, it was just really hard to find good articles and how-to type information on web app architecture and design with Oracle. Basically, I just needed to talk to someone who does what I do with .NET but does it with Oracle products so that I could get them to help me draw the parallels. We were sent one after another consultant by Oracle, telling them we needed a web application architect each time, and ending up with DBA after DBA after DBA, each basically saying “I think you can write all your HTML in PL/SQL”. Yeah, a 1 tier app, that's just what I had in mind. Either that or we ended up with the Technical Manager type who could rattle off a laundry list of options (most involving obscene licensing costs), but couldn't really guide us on the right selection of technologies given our requirements and expertise.

Finallly yesterday we went to the Reston Oracle headquarters and met with some folks and got the guy we needed. I could immediately tell that he spoke the lingo, even though he was talking different tools and terms, we were both describing the same app architecture and he was able in about an hour's time to get us right on track.

Some of the stuff in the Oracle suite (JDeveloper in particular) are pretty nice. Microsoft should take a look. Even though their Business Components for Java (BC4J) framework and Struts (an MVC open source framework) are heavily driven by XML, you almost never have to touch the raw XML yourself. They have wizards and dialogs that encapsulate ever setting you might possibly need to make in the XML configuration files of many flavors. We need more of that in .NET, and I think some is coming in Whidbey from what I have seen and heard.

It is definitely a more DB centric world that we are used to in the .NET realm, but I could see where that pendulum might swing closer to the Oracle approach with some of the features coming in Yukon.



Architecture

Saturday, February 14, 2004 3:20:51 PM (GMT Standard Time, UTC+00:00)
Comments [1]  | 

Week in Redmond

I got to attend a design review of some stuff I can't talk about in Redmond this week. Suffice it to say there is a lot of really cool stuff coming down the pike in the Whidbey time frame, a lot of which people have not even heard about yet.

I am always impressed by the size of the campus, the energy and activity when I am there. The project managers and program managers we deal with are all very enthusiastic and motivated about their jobs and really just busting their butts to pump out good tools to make our lives as developers better, easier, faster.

People can bash Microsoft all they want, but my respect for them as a company and as a group of individuals just grows the more direct contact I have with them.



.NET | Community

Saturday, February 14, 2004 3:03:28 PM (GMT Standard Time, UTC+00:00)
Comments [0]  | 

Selected as MVP

Just found out I got selected as a Microsoft “Most Valuable Professional” (MVP), Visual Developer - ASP/ASP.NET. Very cool. I've always felt like that was a nice little recognition program they had going on, but never looked into how it worked until I found out I was nominated. I guess it had to do with all the writing, speaking, training, and early adoption programs I take part in.

Besides some nice freebies and early access to new technologies, makes a nice little moniker to hang behind the name to say “I'm somebody, I swear! Just ask me!” OK, well, maybe not quite so desparate as that...

Thanks to anyone who helped get me on the slate!



Community

Saturday, February 14, 2004 2:58:00 PM (GMT Standard Time, UTC+00:00)
Comments [1]  | 


 # Wednesday, February 4, 2004

My Brain is Mush

So you may have noticed I haven't blogged much lately. Oh yeah, no one reads this because there is no content... Let me rephrase: I may have noticed I haven't blogged much lately.

I don't know how many bloggers keep up with it. I know you all are probably as busy as me. But there has just been no way to find time for blogging lately.

Excuses in the last few weeks:

  • Delivered an Article on ClickOnce that will be in the May issue of MSDN magazine.
  • Did my .NET Rocks! interview.
  • Did a short notice UG talk.
  • Just delivered the first chapter (really Chapter 2) of my book, which will be one of the longer chapters in the book (data access). Major milestone for me in getting the juices flowing on this project.
  • Delivered the materials for the two conference talks I am giving at Visual Studio Connections (ClickOnce and UIP).
  • Prepared and gave a day long seminar on Essential .NET in DC yesterday.

All this while consulting about 3/4 time.

I do lots of interesting stuff I'd like to blog about. Some I can't for customer reasons, some I can't because it is being published elsewhere, what's left I can't find the time for. I guess my fame and fortune will have to come from somewhere other than the blogsphere for now...



Blogging

Wednesday, February 4, 2004 1:23:38 PM (GMT Standard Time, UTC+00:00)
Comments [0]  | 


















May, 2013 (2)
April, 2013 (2)
March, 2013 (2)
February, 2013 (2)
January, 2013 (2)
December, 2012 (3)
November, 2012 (1)
October, 2012 (1)
August, 2012 (2)
June, 2012 (2)
May, 2012 (3)
April, 2012 (1)
March, 2012 (2)
February, 2012 (2)
January, 2012 (1)
November, 2011 (4)
October, 2011 (1)
September, 2011 (2)
August, 2011 (1)
July, 2011 (1)
May, 2011 (5)
March, 2011 (4)
February, 2011 (2)
January, 2011 (3)
November, 2010 (4)
October, 2010 (1)
September, 2010 (5)
August, 2010 (5)
July, 2010 (6)
June, 2010 (8)
May, 2010 (2)
April, 2010 (2)
January, 2010 (1)
December, 2009 (3)
November, 2009 (2)
October, 2009 (3)
September, 2009 (3)
August, 2009 (2)
July, 2009 (3)
May, 2009 (3)
April, 2009 (2)
March, 2009 (1)
February, 2009 (2)
January, 2009 (2)
December, 2008 (1)
November, 2008 (2)
October, 2008 (5)
September, 2008 (4)
August, 2008 (2)
July, 2008 (1)
June, 2008 (2)
May, 2008 (2)
April, 2008 (3)
February, 2008 (6)
January, 2008 (3)
December, 2007 (1)
November, 2007 (1)
October, 2007 (5)
September, 2007 (1)
July, 2007 (3)
June, 2007 (8)
April, 2007 (2)
March, 2007 (4)
February, 2007 (1)
December, 2006 (2)
November, 2006 (9)
October, 2006 (5)
September, 2006 (3)
August, 2006 (2)
July, 2006 (4)
June, 2006 (5)
May, 2006 (10)
April, 2006 (4)
March, 2006 (2)
February, 2006 (12)
January, 2006 (7)
December, 2005 (2)
November, 2005 (15)
October, 2005 (6)
September, 2005 (7)
August, 2005 (3)
July, 2005 (10)
June, 2005 (11)
May, 2005 (7)
April, 2005 (8)
March, 2005 (6)
February, 2005 (2)
January, 2005 (6)
December, 2004 (3)
November, 2004 (5)
October, 2004 (2)
September, 2004 (5)
August, 2004 (13)
July, 2004 (6)
June, 2004 (14)
May, 2004 (17)
April, 2004 (12)
March, 2004 (8)
February, 2004 (10)
January, 2004 (14)
December, 2003 (9)
November, 2003 (13)
October, 2003 (3)

Sign In
Copyright © 2006-2012 Brian Noyes. All rights reserved.

designed by NUKEATION STUDIOS