award.pngSLB Development designs web applications, provides managed hosting and offers IT services.  We are located in Upstate South Carolina.  We work closely with you to deliver a complete solution for your business needs. Please browse the website and look over our portfolio of satisfied clients. If you would like to contact us please call us at (864) 946-9107 or e-mail us at info@slbdevelopment.com.






Share |


Rss

Upcoming SC Best Law Firm Website Contest

I am preparing one of my client's websites for the SC Lawyers Weekly annual Best Law Firm website.  We won last year with ERISA Experience.  In previous years, they have won an award with their main website.  I have consulted with them and we have some pretty good ideas so that we hopefully win again this year.

Downloads

Throughout the years I have written a lot of software with various tools that doesn't have any commercial value but could have value to others.  I have decided to start making it available for other people to use on a new download page.



Over the next couple of weeks, I will be adding source code for many different environments. 

Excel Forecast and Moving Average for Microsoft Access

The forecast function from Excel as well as moving average are two important functions that are missing from Microsoft Access.  Recently I developed a small stock market application in Microsoft Access and needed both of these functions.  I am making them available here in case anyone else can benefit from these two functions.



Function xl_forecast(num As Integer, x_values() As Double, y_values() As Double) As Double

             Dim x_Avg As Double

            Dim y_Avg As Double

            Dim b As Double

            Dim a As Double

            Dim i As Integer

            Dim tempTop As Double

            Dim tempBottom As Double

           

            For i = 1 To UBound(x_values)

         

                x_Avg = x_Avg + x_values(i)

            Next

            x_Avg = x_Avg / UBound(x_values)

 

          

            For i = 1 To UBound(y_values)

                y_Avg = y_Avg + y_values(i)

            Next

            y_Avg = y_Avg / UBound(y_values)

 

            For i = 1 To UBound(y_values)

 

                tempTop = tempTop + (x_values(i) - x_Avg) * (y_values(i) - y_Avg)

                tempBottom = tempBottom + ((x_values(i) - x_Avg) * (x_values(i) - x_Avg))

            Next

 

 

            b = tempTop / tempBottom

            a = y_Avg - b * x_Avg

 

            xl_forecast = a + b * num

 

End Function

 

Function moving_average(x_values() As Double) As Double

      Dim x_Avg As Double

      Dim i As Integer

             For i = 1 To UBound(x_values)

                x_Avg = x_Avg + x_values(i)

            Next

     moving_average = x_Avg / UBound(x_values)

End Function