New Project, New BlogProcessor?

This weekend I've begun a new project to both scratch an itch I have and to learn some of the new bits of the 3.5 .Net Framework. More on that in a bit.

As a side note, this is my first post from Microsoft's Windows Live Writer. W00t! First post!

I think Live Writer is a step in the write direction (ba-dump-bump). It is a very small program (less than 3 MB) and it doesn't do very much. But what it does do, it does very well. It is a word processor for blogs. It is also free. That is free-as-in-beer for the FOSS crowd, and free-as-in-you-don't-pay-money-for-it for everyone else.

I could use Word 2007 to write my blog entries. I could also buy an RV to cruise around town and pick up my dry cleaning. The point is that 99.93% of the features of Word 2007 are unnecessary for writing this blog post. I don't plan to mail-merge and print envelopes nor do I need fancy macros. Nope, I just want to write, insert links and the occasional picture and have spell check watch my back for crap like spelling occasional as "occassional " or "ocassional " (not that that would ever happen to me).

The web is all around us and that is a good thing, but for some things HTML makes for a poor interface even with AJAX, Achilles, Odysseus or any of the other warriors of the Trojan war. For some things you just need a good old fashioned application running on your computer. The trick is for that application to interact with the mighty Internet and its hordes of servers.

Live Writer is a very good example of doing this and doing it well (he said confidently having never actually tried that big, beautiful "Publish" button).

Enough of that for now, on to the Project. Hmm. I guess I need to give it a secret Code Name to use to speak about it until I decide to release it to the world with a boring name that doesn't mean much (Revolution becomes Wii?). How about this: Brains-On-A-Stick. Since it's a temporary working name, who cares, right? No chance that name could stick. With brains. Man, that was bad.

Here's the annoying-problem-I-want-to-solve: my son, daughter and I all have MP3 players (neither iPods nor Zunes) and we all like podcasts. Keeping up with syncing all those devices with podcasts is a pain in the 'cast. Oh, and I want to try out all the neat new stuff in the 3.5 Framework...

My first thought was to use one of the various podcast feed-readers to pull down the shows and write an app to sync them up. After reading about Microsoft's new MESH and its RSS/Atom use, I decided that it was time to bone up on using .Net to work with syndication feeds. I found several good blogs that talked about syndication and started hacking around with it.

I now have  a rudimentary feed reader that uses the following new bits:

1) WPF (Windows Presentation Foundation). Uses XAML (Extensible Application Markup Language) to describe the presentation. This XML file is parsed and the UI is built on the fly both at design time and runtime. We've all talked about separating presentation from behavior for a long time, and this is one swell way to do it. Why do I find it exciting? You can FINALLY rely on DirectX and your 3D processing video card to handle the graphics (good-bye, GDI, well, mostly). This means your windows (and elements inside the windows) can be 3D and not 2D, even though they look 2D most of the time. This means you can spin a window around and stack them up. More about WPF and XAML in future posts.

2) Expression Blend. If you have the ability to separate presentation from code, then why not make a tool for designers so they can make really cool looking graphics? I'm not a designer, so I'm not going for cool looks yet, but as I get things working, I'll spend more time tinkering with the looks.

3) JSON. JavaScript Object Notation. I'm using this to serialize objects to disk. XML would work just as well, but JSON is all hip and trendy. All the cool kids are using it.

4) LINQ. Language Integrated Query. I'm using this to query the objects in memory. Much more on this later.

5) Syndication. RSS and Atom feeds are how you get your podcasts. The System.ServiceModel.Syndication namespace objects help you work with them.

I'll write about all the little bits as I work through the project.

Posted on 4/27/2008 9:50:00 PM by jeffa

Permalink | Comments (0) | Post RSSRSS comment feed |

Categories: .Net

Tags: , , , ,

Be the first to rate this post

  • Currently 0/5 Stars.
  • 1
  • 2
  • 3
  • 4
  • 5

ASP.NET and Godaddy, part 3

Sweet! Got everything working.

As I mentioned in the last post, I dropped back to square one and rebuilt the app one piece at a time to see where the problem was.

I got the login and register pages working first, then went to the data entry page.

Once I built my Linq objects, but before I referenced them, I uploaded everything one more time. I did a diff on the old and new web.config files to see what had changed. There were only two changes: 1) added new connection string and 2) added assembly info for Linq.

A quick check that everything worked well, then I added the code-behind to use the Linq objects to write the data to the database. 

Once everything was deployed, I hit the page and... 500 Internal Server Error.

This time I thought about the new App_Code directory where the Linq objects live. Since I did a website instead of a webapp, everything has to compile on the fly when it runs the first time... hmm. Think maybe that directory needs write permissions?

Added write permissions and, hey presto! Now the Linq data entry page works!

It was literally five more minutes to get the data view page working using a Grid View that uses a Linq object as its source.

One thing I did differently this time was change the name of the Linq datasource to something other than the default.

Now I move on to making things pretty. I'll also write up a more detailed set of instructions and post them. 

 

Posted on 4/22/2008 10:48:00 AM by jeffa

Permalink | Comments (1) | Post RSSRSS comment feed |

Categories: .Net

Tags: , , ,

Be the first to rate this post

  • Currently 0/5 Stars.
  • 1
  • 2
  • 3
  • 4
  • 5

ASP.NET and Godaddy, part 2

Well that worked.

 I dropped back to a blank sheet and worked my way up one step at a time. Only way to eliminate variables that could be causing problems.

Here are the step by step directions to get to a bare page with functional login and registration pages:

1) Create local SQL Server database (Express will do)

2) Dig through C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727 and run aspnet_regsql.exe. This will create all the aspnet tables, views, and stored procedures.

3) Fire up Visual Studio 2008 and create a web site.

4) Go to menubar: Website: ASP.NET Configuration. This will start a local web server and spawn a web page in the browser.

5) Modify web.config and put the connection string for the database you created in the connectionStrings section for the name "LocalSqlServer".

6) Close the web project and then reopen it. I didn't verify that this is a required step, but I did it anyway...

7) Re-launch the ASP.Net Configuation like you did in step 4.

8) Enable Roles management.

9) Create a few roles. I made admin and user.

10) Create a user.

11) Go back to Visual Studio and add your database under the Server Explorer tab.

12) Check the aspnet_Users table to be sure your user showed up.

13) Right click on the database and pick Publish To Provider.

14) Only export the table data.

Now we get to the GoDaddy portion of the operation. These steps will require some patience since you have to wait for them complete each step.

15)  Log in to your account and create a SQL Server 2005 database.

16)  Make sure you select to Create ASP Schema for the database.

17) Log in to your new database.

18) Use Query Analyzer to run the file you created back in step 13: Publish To Provider. This will ERASE any existing table data, so use caution on your SECOND AND SUBSEQUENT webapp! For those you will want to only append data, not delete first. You have been warned!

19) Use Godaddy's File Manager to create a new directory and upload your app to it.

20) Using their File Manager's Edit utility, modify your web.config so that the connection string points to the database you created there, not your local database.

21) Use their IIS Settings tool to create a new virtual directory/app. Be sure to select Set Application Root.

22) You should now be able to hit your page.

That was the hard part. Now for the easier stuff.

I'm not going to include these in the step by step instructions, just summarize them.

23) Create a Register.aspx page. 

24) Add a CreateUserWizard from the Login section of the tool box.

25) In properties, set the ContinueDestinationPageURL to the "~/Default.aspx".

26) Add a LoginView control to the Default.aspx page. In the Logged In Template, write something like "You are logged in".

27) In the Anonymous Template add a Login control.

28) Set the Login control's DestinationURL to "~/Default.aspx" .

29) Set the Login control's CreateUserURL to "~/Register.aspx" or whatever you named that page.

30) Test things locally to make sure they work.

31) Upload to Godaddy everything.

32) Make sure you change the connection string in the web.config file like you did in step 20.

At this point it works for me. I can add users and log in.

The key here is to step back, simplify what you are trying to do and build up one step at a time.

In Agile programming you try to break things into chunks that can be delivered early. In this case I tried to do too much with my first attempt. It didn't seem like much until something broke. Now that I have gone back and started much smaller, I have a working system that can register and authenticate users instead of a bigger system that can't do anything...

More details later.

Posted on 4/18/2008 7:56:00 AM by jeffa

Permalink | Comments (1) | Post RSSRSS comment feed |

Categories: .Net

Tags:

Be the first to rate this post

  • Currently 0/5 Stars.
  • 1
  • 2
  • 3
  • 4
  • 5

GoDaddy and ASP.NET apps

OK, so I'm finally working on some asp.net projects.

For several years now I've been working primarily on backend systems that do important work with NO visible interface... When we talk about our apps and people ask which part I did, I have to grimace and say, "The parts you can't see..." Without my part nothing would work, but people are only impressed by what they can SEE.

Any way, I'm working my way through the ASP.NET user management controls and made a simple app for tracking your health stats. I used Linq for the database access, and it seems pretty cool. I'll write in another post about what I think so far about Linq.

Got everything working well locally and uploaded it to GoDaddy.com. No go. I got the database populated with the roles, etc. But so far all I get is a big ole 500 Internal Server  Error. Since I'm working in a hosted environment, I can't a huge amount of info about what's happening.

I'm going to blog my efforts here and when I'm finished I'll write up a detailed set of directions.

For now I'm going back to step one and create a page with nothing but a login.

Film at 11.

Posted on 4/17/2008 10:04:00 PM by jeffa

Permalink | Comments (1) | Post RSSRSS comment feed |

Categories: .Net

Tags: , , ,

Be the first to rate this post

  • Currently 0/5 Stars.
  • 1
  • 2
  • 3
  • 4
  • 5

Fiddler - The Web Developer's BFF

I just found a really cool tool called Fiddler.

When I say I found it, what I mean is I read about it in a post on Kirk Evan's blog. He was talking about Creating Restful Services Using WCF

If you aren't doing web development, then just move along, there's nothing to see here.

If you ARE doing web development then you really need to see this.

When you run Fiddler on your system it sits as a proxy between your web browser and whatever web server you are connecting to. In simplest terms it lets you dig into the request and response objects to see what makes them tick. The cool part is that it goes far beyond that. It lets you change those objects on the fly to see what happens. It also lets you set break points in the process. The Fiddler website has a video that demonstrates setting a breakpoint on any CSS files that are downloaded. You ask for the webpage and it freezes at the point of pulling down the CSS file. You can inspect or modify the CSS file and then let it go on to the browser for rendering complete with any changes you made!

That's pretty cool when you are stuck on a bug and need all the info you can get. "Fiddle" around with the values and see what breaks. Or starts working.

You can also extend Fiddler using .Net. I hope someone makes a cool framework that Fiddler can use and calls it "The Roof". Then like the Ruby language using the Rails Framework is called "Ruby On Rails", we could have "Fiddler On The Roof".

Posted on 4/15/2008 3:42:00 PM by jeffa

Permalink | Comments (0) | Post RSSRSS comment feed |

Categories: .Net

Tags: , , , ,

Be the first to rate this post

  • Currently 0/5 Stars.
  • 1
  • 2
  • 3
  • 4
  • 5

Second Life Confessions

At the recent Atlanta Code Camp (awesome, blog more about it later) I met David Silverlight who was talking about a Microsoft User Group that meets in Second Life, the massively multi-user thing-a-ma-bob.

That sounded pretty cool to me, but I had only tried Second Life (SL) once and it was NOT a positive experience.

For those who haven't ventured outside their first life, let me paint you a picture: you start on what amounts to Reject Island with all the other people who just signed up and have no idea what's going on. During my first foray (I'm guessing this was around 2006), the lag was so bad it was like The Island Of The Reject Narcoleptics. I tried for about thirty minutes before uninstalling the client in disgust.

Now, however, David had piqued my interest and I decided to give it another go.

That spawned the epic motion picture-like-experience I call: Return To Reject Island. Or maybe The Accidental Tramsssexual... (note I spelled that wrong to try to avoid Google Adsense hilarity).

Whilst trying the various tutorials I managed to dismiss my tutorial box and failed to find it again. That meant no more instructions. I had made it just to the point of figuring out how to change my little avatar's appearance. Well, HALF WAY through learning that.

You can spend your Linden Dollars (the local currency) on all manner of fancy schmancy clothing, jewelry, etc., but I WILL NOT PAY A LOT FOR A MUFFLER! Oh, no, not I! I decided to get creative with the default clothing options. I started with a fire-fighter. Woudln't it be funny if I mixed in some of the Little Red Riding Hood clothes? What a laugh riot! Right up until my big, strapping firefighter sprouted boobs and became a petite woman!

Evidently changing clothes in Second Life can be a life (and sex) altering experience!

So I tried to switch back, but Second Life was having none of my second guessing. It would, however, allow me to be a female firefighter with no hair and a stark, black beard. Not being committed to this game, I decided to give up the effort and wander around the island, talk to the other rejects and see if they would make me their king or queen based on the fact that I was in fact the biggest reject of them all.

I met a female avatar who said "Hi" in Spanish, and I thought that it would be cool to try to have a conversation in a language I studied briefly long, long ago.

We muddled along and I found that she was in Mexico and very interested in drinking. Everything was fine until a fellow from Venezuela happened along. He seemed to have a thing for bald headed, black bearded female firefighters.

Hmm. First year Spanish did NOT include the sentence, "Hey, I'm a guy who accidently changed himself into a girl by trying on some clothing to try and be funny." Go figure. Much more useful than nattering on about the color of my pencil, but NO, they just don't teach it.

As Don Juan got friendlier and friendlier, I decided to go for the approach of FIGURING OUT THE DAMNED SYSTEM and changing back into a guy.

Eventually I morphed back into a tall, masculine firefighter right before their astonished (and in his case horrified) eyes.

Fortunately between three people and two languages, we got across the fact that I was in fact King of the Rejects and not the Queen.

I'm still hoping to make it to one of the user group meetings. If you're there, look me up. I'll be the big firefighter who NEVER, EVER changes his clothes... 

 

Posted on 4/15/2008 12:25:00 PM by jeffa

Permalink | Comments (2) | Post RSSRSS comment feed |

Categories: Pure Rambling

Tags: ,

Be the first to rate this post

  • Currently 0/5 Stars.
  • 1
  • 2
  • 3
  • 4
  • 5

Gwinnett, Georgia, Microsoft User Group

Well, I AM having a second post! This is a personal best.

I wanted to talk a bit about something I'm working on at the moment. A couple of friends and I are starting a new user group for our area. We are developers who have worked with a variety of technologies over the years. I have spent years working with Java and Oracle PL/SQL, but since 2005 we have done much of our work with Microsoft technologies like C#, .Net, ASP.Net and the .Net Compact Framework.

We came to Microsoft via the Pocket PC. We all work for The Atlanta Journal-Constitution writing software primarily to support the delivery of the paper. We were originally using the Palm OS for handhelds, Java for the web app and Oracle for the database. It worked pretty well, but we bought a syncing package that to us was a black box. It broke down frequently and there was little we could do about it. The company that made it was bought by a consulting company who dropped the product leaving us high and dry.

After several missteps trying to replace it, we decided to write our own. I had just bought a Pocket PC myself and wanted to learn to code for it. It didn't take long before I realized that we could ease much of our suffering if we went with Pocket PC instead of Palm. We could use one language to write code on the handhled, web app, database, and server apps. That meant we could divide work more logically, rather than each being in totally unrelated technical silos.

Long story somewhat shortened: we've worked with Microsoft since '05 and they have been very helpful. Our sync software has worked great and given us very few problems. We want to get involved with the local user group community, but there is a problem. Geography.

The city of Atlanta is very small. The region known as Metro Atlanta is HUGE. We live in a part of the Metro area known as Gwinnett County. For us it would take at least an hour to get to the Atlanta meetings during rush hour traffic. Rush hour traffic here is pretty much defined as all hours other than 2-3 AM.

For that reason we decided to form our own user group: the Gwinnett, Georgia, Microsoft User Group (GGMUG). Our first meeting will be May 8 at the Gwinnett Justice and Administration Center Gwinnett Technical College in Lawrenceville. We have two great speakers lined up and so far about 25 people signed up to attend.

I'll post more info here as we go. I'm also posting to the GGMUG website. I'm trying to keep the posts there down to a minimum so I don't wind up obscuring information that people need about meetings.

I'm very excited about GGMUG and looking forward to our first meeting. We're planning to meet every second Thursday.

Posted on 4/15/2008 7:53:00 AM by jeffa

Permalink | Comments (0) | Post RSSRSS comment feed |

Categories: ggmug

Tags: , , ,

Be the first to rate this post

  • Currently 0/5 Stars.
  • 1
  • 2
  • 3
  • 4
  • 5

Welcome!

First let's get one thing straight: I am NOT a good blogger.

Good bloggers post on a regular basis. I may never post again...

Good bloggers have something pithy to say. Um, what now?

Good bloggers know more than I do about what makes a good blogger...

If you find yourself reading this blog and wondering if anyone else reads it, then let me answer your question: no. You are the one, Neo. The only one. You are so very alone. 

Posted on 4/11/2008 1:23:00 PM by jeffa

Permalink | Comments (0) | Post RSSRSS comment feed |

Categories:

Tags:

Currently rated 5.0 by 1 people

  • Currently 5/5 Stars.
  • 1
  • 2
  • 3
  • 4
  • 5