|
Excel spreadsheets:
Great for budgets, financial projections, costing, cash flow, in fact any
project where many or complex calculations are required. What makes an
Excel project really sing is the application of carefully built formulae and
visual basic procedures. Take a look at the following formulae
and code to see examples of what can be written...
Concatenation: ="£"&FIXED(E2,2)&" is equivalent to "&F2&" Euros"
Array formulae: {=SUM(yr2003*increase)}
Auto data sort: =ROUND(IF($E5=3,$F5/IF($D5=1,1.175,1),0),2)
Vba code to automate production of invoice:
Sub Log_inv()
' Log_inv Macro
' Code recorded 18-08-03 by Nigel Hildred
Msg = "ENSURE YOU HAVE PRINTED OFF A COPY OF THIS INVOICE. The Invoice will now be logged and the Invoice template re-set. Are you sure you want to proceed?"
Style = 4 + 32
Title = "INVOICE LOG"
response = MsgBox(Msg, Style, Title, Help, ctxt)
If response = vbYes Then
Sheets("Log").Select
Range("A1").Select
Selection.End(xlDown).Select
ActiveCell.Offset(1, 0).Range("A1").Select
Sheets("Invoice").Select
Range("H5,H6,H8,H28,H29,H30").Select
Selection.Copy
Sheets("Log").Select
Selection.PasteSpecial Paste:=xlValues, Operation:=xlNone, SkipBlanks:= _
False, Transpose:=True
Range("A1").Select
Sheets("Invoice").Select
Range("A4").Select
Range("A4:B9,E5:E9,H6:H8,A12:G24,A37:A42,B36:H42").Select
Selection.ClearContents
Range("A4").Select
ActiveWorkbook.Save
ElseIf response = vbNo Then
Exit Sub
End If
End Sub
Contact us to discuss your needs and receive a quotation.
Return
to top of page
|
|