Expert VBA Programmers

If you answered yes to any of the above we can help you - and we would be very happy to do so! You can call us on 01747 822616 or fill in an enquiry form and we will happily talk to you about what you are looking for. If we can help you we will give you an idea of cost, and if we can't we will tell you and try to point you in the right direction.

Typical VBA programming cost*:

FREE Consultation - what you get:

Fill in an enquiry form here and we'll call you back or call 01747 822616 to speak to someone right away.

What now? - To find out more about our VBA and how we can help you, click here to fill in an enquiry form

Why Use Us?

Software-Matters have been programming Microsoft products since 1994 so have a wealth of knowledge and experience. We write code in VBA on a daily basis and the team regularly answer questions in forums on this subject.

Our main bulk of work is in Microsoft Access and Excel but we have also done a lot of VBA programming in Microsoft Word and Outlook. More recently we have been programming online web solutions that use VBScript and link to an Access database.

What is VBA?

VBA, which stands for Visual Basic for Applications, is a programming language developed by Microsoft. Access and Excel, along with the other members of the Microsoft Office suite include the VBA language. VBA is the tool that people use to develop programs that control MS Access and Excel. Don’t confuse VBA with VB (which stands for Visual Basic). VB is a programming language that lets you create standalone executable programs (those EXE files). Although VBA and VB have a lot in common, they are actually quite different.

Examples

A common use of VBA is to add functionality that may be missing from the standard user interface.

MS Access

This function in MS Access calculates the number of working days (Monday-Friday) from start to end.

Public Function WDays(ByVal ST As Variant, en As Variant) As Integer
Dim counter As Byte, Temp As Date, Weeks As Integer, moving As Date
If DateDiff("d", ST, en) <= 0 Then
WDays = 0 'end is before start
ElseIf IsNull(en) Or IsNull(ST) Then
WDays = 0
Else
Weeks = Int(DateDiff("d", ST, en) / 7) 'whole weeks
Temp = DateAdd("d", Weeks * -7, en) 'bring end closer to start by weeks
moving = ST 'start at st
Do Until moving = Temp 'loop through days counting weekdays
If WeekDay(moving) <> 1 And WeekDay(moving) <> 7 Then counter = counter + 1
moving = DateAdd("d", 1, moving)
Loop
WDays = Weeks * 5 + counter
End If
End Function

MS Word

This macro provides a shortcut for entering the current date in Word:

Sub EnterCurrentDate()
' EnterCurrentDate Macro
' Macro recorded 15/03/2005 by UserName
'
Selection.InsertDateTime DateTimeFormat:="dd-MM-yy", InsertAsField:=False, _
DateLanguage:=wdEnglishAUS, CalendarType:=wdCalendarWestern, _
InsertAsFullWidth:=False
End Sub
VBA is useful for automating database tasks such as traversing a table:

Sub LoopTableExample

Dim db As DAO.Database
Dim rs As DAO.Recordset

Set db = CurrentDb
Set rs = db.OpenRecordset("SELECT * FROM tblMain")

Do Until rs.EOF
MsgBox rs!FieldName
rs.MoveNext
Loop

rs.Close
Set db = Nothing
End Sub

*Prices are excluding VAT

Don't just take our word for it...

"I would like to say thanks to yourself and your team for all your hard work.
We are very happy with the quoting system; for the first time ever we are looking at a system in which we have confidence."

Steve Ringsell, CFN Packaging

scroll to top - icon