After we learn make function excel with 1 and 2 data source, now we
learn how to make function with Data Range.
1. Open Excel
2. Click Develepor | Visual Basic \ ALT + F11






3. Click Insert | Module.





4. Now we must think want kind function we want, and how the process
calculate. for example i want to make function to calculate the
FinalResult, it need a 30% average result of assigment and add in 70%
value of tes.
5. Type Public Function Name(Data1, Data2),Public Function
NilaiAkhir(NilaiTugas, NilaiTes) lalu tekan enter. note NilaiAkhir =
Final Result, NilaiTugas = Value of assigment, value of tes





6. We use function worksheet to calculate average

NilaiTugas = Application.WorksheetFunction.Average(NilaiTugas) .







7. Now we multiple Nilai Tugas witth 0.3 because VB can't use 30%.
NilaiTugas = NilaiTugas*0.3
this function mean we can get a new value of nilai tugas after we
multiple with 0.3..



8. After that we multiple nilaiTes with 0.7





9. and we calculate the NilaiAkhir
NilaiAkhir = NilaiTugas + NilaiTes
and use Round display 2 decimal
NilaiAkhir = Round(NilaiAkhir, 2)







10.Go back to Excel and Save As Add –In(xlam) , close excel



11. Open again axcel and Click Office Button | Excel Option





12. Click Tab Add-Ins and Click Go





13. Click Function we make





14. And if you want to use just
type,=NilaiAkhir(Celldata1Awal:CellData1Akhir;CellNilaiData20). example
=NilaiAkhir(C5:E5;F5)




Download Tutorial

--
Posting oleh mister.ahmad ke Tips and Trick pada 1/18/2010 02:19:00 AM
--
You received this message because you are subscribed to the Google Groups "Gugukluhayat" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to [email protected].
For more options, visit this group at http://groups.google.com/group/gugukluhayat?hl=en.

Cevap