Tuesday, August 26, 2008

Buying a Server

I have been having problems with my website hosting company. I host 11 websites with hostonce.com and twice now all of these sites have been down for a couple days at a time, and the site for the company was down at the same time as well, so there was no way to submit a support ticket. After this happened the second time I decided I had to find a new hosting company. I wanted to be able to host all of my websites on one account with room to grow. I have 3 different accounts with hostonce since they offer a deal where you can upgrade to a 5 site host for 45 dollars above the 80 something price of one site. This was a good enough deal at first since I had locked in a yearly rate of 60 odd dollars plus the 45 for my first set of 5 sites, but over time it has proven to be a bit of a pain.

I looked into getting a dedicated server hosted for me, or ever a Virtual Private Server. The dedicated server setup would have cost over $4000 dollars a year, more than I can afford, and the VPS solution I found would have limited me to 30 websites and cost over $800 dollars a year.

Looking at those prices I began to wonder what it would cost to host my own webserver.
AT&T recently raised the price I was paying for internet from around $35 dollars a month to around $55 becuase we lost a discount we were getting.
Cox business internet service offers a plan with a dedicated IP and an OPEN port 80 for website hosting for $69 dollars a month. Not that much more than AT&T.
Dell offers a varity of servers for different price ranges. I found and ordered a very basic one on sale with a dual core 2.0ghz processor, two 80 gig hard drives, and 2gig of ram for $423.08 with taxes and Shipping. It should arrive next week.

Now I need to save up for the software to put on my server. Windows Web Server 2008 $469 Web Server-only product, no CALs required. Available in 32-bit and 64-bit versions. Fortunatly there is a 60 day downloadable trial version of this software (which I am downloading right now) so I can install and setup my software now and pay for it next month.

Fun, Fun, Fun, I have a new toy on the way.

Monday, August 4, 2008

Importing Data From Shelby Systems

Today I did most of the Spark, caught up on email, and did the following work on the new CHMS:

Worked on Creating the Ability to Import People and Families from Shelby, this included creating Data Access and BLL layers for the needed Shelby tables, and new methods in several of the BLL Classes along with some Data Access methods to go with them.

Fortunately, Shelby stored its data in a SQL Server database as well, so I was able to shutdown SQL server on our Server computer, make copies of the database files, re-start SQL server, bring the copied files to my computer, and attach them to my local SQL Server Express edition. Thus I can work with the Shelby database without having to connect to the actuall database on the server, and thus risk data, or kick other people out.

I may eventually work on a way to move updated data back and forth, but for now, getting data out of Shelby and into the new system is enough of a challenge.

Tuesday, July 29, 2008

AJAX

Today I finished up the bulletin for next Sunday and worked on the BLL and started the presentation layer for the Open Source Church Management System named Hill CHMS I am working on building for Chapel Hill.

I need to AJAX enable the site before I can go much further. I want admins to be able to start typing in a last name and have a list of choices appear below, with the list getting smaller as more letters are typed. I know this is possible with AJAX, I just don't know how hard it would be to actually do. If I can't do this right away I will settle for a list that populates when a button is hit.

I need to think of this in terms of versions, with version one just working and later versions having more features.

Monday, July 28, 2008

Today's Update

I know no one reads this, or really cares about the Church Management System I am working on at the moment. I suppose it is just my geekishness that makes me want to post all this here.

Today after getting all my other Church work done I worked on the CHMS and did the following"

Created tblContactMethods to hold of all things contact methods.
Created tblMembershipStatuses to hold membership statuses.
Created table adapters for these two tables.

I had forgotten to add these to the original database map, they connect the the people table

Changed tblPeople and re-created its table adapter.

I need to talk to George Retter, who is doing our Jump In - get people involved ministry here at Chapel Hill before I go any further.

Friday, July 25, 2008

More table images

Here are the images from some more tables for the CHMS





Business Logic Layer

Free Open Source Church Management System Business Logic Layer

Much of the basic logic for my BLL's comes from the following tutorials. ASP.NET Data Access Tutorials

Here is the updated code for the Families BLL

Imports Microsoft.VisualBasic
Imports FamiliesTableAdapters

_
Public Class FamiliesBLL

Private _theAdapter As tblFamiliesTableAdapter = Nothing

Protected ReadOnly Property Adapter() As tblFamiliesTableAdapter
Get
If _theAdapter Is Nothing Then
_theAdapter = New tblFamiliesTableAdapter()
End If

Return _theAdapter
End Get
End Property

(System.ComponentModel.DataObjectMethodType.Select, True)> _
Public Function GetFamilies() As Families.tblFamiliesDataTable
Return Adapter.GetFamilies
End Function

(System.ComponentModel.DataObjectMethodType.Select, False)> _
Public Function GetFamilyByID(ByVal FamilyID As Integer) _
As Families.tblFamiliesDataTable
Return Adapter.GetFamilyByID(FamilyID)
End Function

(System.ComponentModel.DataObjectMethodType.Insert, True)> _
Public Function NewFamily( _
ByVal FamilyName As String, ByVal FamilyDescription As String, _
ByVal SalutationID As Integer, ByVal Salutation As String, _
ByVal Address As String, ByVal City As String, ByVal StateID As Integer, ByVal StateName As String, ByVal ZIP As String, _
ByVal HomePhone As String, ByVal FamilyCellPhone As String, ByVal FamilyEmail As String, ByVal ShelbyFamilyID As Integer, _
ByVal ImageID As Integer _
) As Boolean

Dim SiteID As Integer = 1


Dim TBL As New Families.tblFamiliesDataTable
Dim ARow As Families.tblFamiliesRow = TBL.NewtblFamiliesRow()

ARow.FamilyName = FamilyName
ARow.FamilyDescription = FamilyDescription

ARow.SalutationID = SalutationID
ARow.Salutation = Salutation

ARow.Address = Address
ARow.City = City
ARow.StateID = StateID
ARow.StateName = StateName
ARow.ZIP = ZIP

ARow.HomePhone = HomePhone
ARow.FamilyCellPhone = FamilyCellPhone
ARow.FamilyEmail = FamilyEmail

ARow.ShelbyFamilyID = ShelbyFamilyID

ARow.SiteID = SiteID

ARow.Created = Now()
ARow.CreatedBy = HttpContext.Current.User.Identity.Name
ARow.LastEdited = Now()
ARow.EditedBy = HttpContext.Current.User.Identity.Name

TBL.AddtblFamiliesRow(ARow)
Dim rowsAffected As Integer = Adapter.Update(TBL)

Return rowsAffected = 1
End Function

(System.ComponentModel.DataObjectMethodType.Update, True)> _
Public Function UpdateFamily(ByVal FamilyID As Integer, _
ByVal FamilyName As String, ByVal FamilyDescription As String, _
ByVal SalutationID As Integer, ByVal Salutation As String, _
ByVal Address As String, ByVal City As String, ByVal StateID As Integer, ByVal StateName As String, ByVal ZIP As String, _
ByVal HomePhone As String, ByVal FamilyCellPhone As String, ByVal FamilyEmail As String, _
ByVal ImageID As Integer _
) As Boolean

Dim TBL As Families.tblFamiliesDataTable = _
Adapter.GetFamilyByID(FamilyID)

If TBL.Count = 0 Then
Return False
End If

Dim ARow As Families.tblFamiliesRow = TBL(0)

ARow.FamilyName = FamilyName
ARow.FamilyDescription = FamilyDescription

ARow.SalutationID = SalutationID
ARow.Salutation = Salutation

ARow.Address = Address
ARow.City = City
ARow.StateID = StateID
ARow.StateName = StateName
ARow.ZIP = ZIP

ARow.HomePhone = HomePhone
ARow.FamilyCellPhone = FamilyCellPhone
ARow.FamilyEmail = FamilyEmail

ARow.LastEdited = Now()
ARow.EditedBy = HttpContext.Current.User.Identity.Name

Dim rowsAffected As Integer = Adapter.Update(ARow)

Return rowsAffected = 1
End Function

(System.ComponentModel.DataObjectMethodType.Delete, True)> _
Public Function DeleteFamily(ByVal FamilyID As Integer) As Boolean

Dim TBL As Families.tblFamiliesDataTable = _
Adapter.GetFamilyByID(FamilyID)

If TBL.Count = 0 Then
Return False
End If

Dim ARow As Families.tblFamiliesRow = TBL(0)

ARow.LastEdited = Now()
ARow.EditedBy = HttpContext.Current.User.Identity.Name

ARow.Deleted = True
ARow.DateDeleted = Now()
ARow.DeletedBy = HttpContext.Current.User.Identity.Name

Dim rowsAffected As Integer = Adapter.Update(ARow)

Return rowsAffected = 1
End Function

(System.ComponentModel.DataObjectMethodType.Delete, False)> _
Public Function DeleteCompletly(ByVal FamilyID As Integer) As Boolean
Dim rowsAffected As Integer = Adapter.Delete(FamilyID)

Return rowsAffected = 1
End Function

End Class

Wednesday, July 23, 2008

Today's Update for the Church Management System

Today's Update for the Church Management System

Today I created table adapters for most of the tables in the church management system, and also made images of the tables for documentation.


Here are some of the images of tables in the system.