Rabu, 17 Mei 2017

TUTORIAL JAVA


GRAFIK SEDERHANA DI JAVA NETBEAN

1.       Buka netbean
2.       Buat Project baru(nama terserah)
3.       Buat Package baru(nama terserah) >Buat Jframe(beri nama chartgaris)
4.       Masukkan Lybrary Jfreechart > Klik kanan Lybrary > AddJar> Arahkan ke Lybrary JFreeChart
5.       Masukkan kode berikut yang berwarna hijau
6.       Selesai > coba di Run

package BAKERY_FOOD;
import org.jfree.chart.ChartFactory;
import org.jfree.chart.ChartPanel;
import org.jfree.chart.JFreeChart;
import org.jfree.chart.plot.PlotOrientation;
import org.jfree.data.category.DefaultCategoryDataset;
import org.jfree.ui.RefineryUtilities;
public class chartgaris extends javax.swing.JFrame {
  
    public chartgaris(String applicationTitle , String chartTitle) {
                
      JFreeChart lineChart = ChartFactory.createLineChart(
         chartTitle,
         "Tahun"," Angka Perkembangan",
         createDataset(),
         PlotOrientation.VERTICAL,
         true,true,false);
        
      ChartPanel chartPanel = new ChartPanel( lineChart );
      chartPanel.setPreferredSize( new java.awt.Dimension( 560 , 367 ) );
      setContentPane( chartPanel );
    }

 private DefaultCategoryDataset createDataset( ) {
      DefaultCategoryDataset dataset = new DefaultCategoryDataset( );
      dataset.addValue( 15 , "Recipe" , "2010" );
      dataset.addValue( 300 , "Recipe" , "2011" );
      dataset.addValue( 60 , "Recipe" ,  "2012" );
      dataset.addValue( 70 , "Recipe" , "2013" );
      dataset.addValue( 115 , "Recipe" , "2014" );
      dataset.addValue( 400 , "Recipe" , "2015" );
      dataset.addValue( 300 , "Recipe" , "2016" );
      dataset.addValue( 250 , "Recipe" , "2017" );           
      return dataset;
   }
public static void main(String args[]) {
        chartgaris chart = new chartgaris(
         "" ,
         "GRAFIK PENJUALAN TH 2010-2017");
java.awt.EventQueue.invokeLater(new Runnable() {
            public void run() {
               
            }
       
        });
    }
Ini Hasilnya


Rabu, 29 Maret 2017

Membuat soal Ujian Sekolah Berbasis Komputer Menggunakan Power Point

Pada kali ini saya ingin berbagi tentang Cara Membuat soal untuk ujian sekolah atau untuk Ulangan Harian Berbasis Komputer menggunakan Power Point 2007.
Sudah banyak sekali postingan yang mengangkat judul cara pembuatannya, namun kali ini saya ingin berbagi dengan metode yang mungkin agak berbeda karena menggunakan banyak script VB macro Power point, yang diantaranya menggunakan 2 UserForm. Masing masing berfungsi untuk Form pendaftaran dan Form Login, yang diperuntukkan sebagai security hak akses dimana hanya Guru saja yang dapat melakukan proses atau pengolahan nilai hasil Tes siswa.


sebelum ke langkah yang lebih jauh, sebaiknya kita perhatikan dulu slide awal yang ditampilkan adalah adanya kolom isian data untuk siswa, dimana Tombol Registrasi berfungsi sebagai pembatasan hak akses, dengan kata lain siswa tidak boleh ke hal isian soal sebelum mengisi Registrasi. Inputan ini nantinya akan ditampilkan pada hal awal dan halaman akhir sebagai Proses Nilai, data siswa, jumlah soal, jml soal benar, jml soal salah dan konversi nilai akhir     Bersambung .......





Selasa, 01 Maret 2016

Program honor guru menggunakan visual foxpro90

1.       Instal visual foxpro90 di computer

2.       Buka programnya,jangan lupa lokasikan dulu directory penyimpanan projecknya di menu tool >option>filelocation>default directory. Seperti pd gb berikut, lalu modfy>set default>ok


3.       Selanjutnya Buat nama project dan database. Namanya terserah anda
4.       Buat tabel dengan nama tbhonor spt gb berikut

5.       Buat form baru dan desain seperti yg terlihat di gb berikut

Untuk combo 3 dan 4 berfungsi untuk membuat nomor kode guru
Untuk combo1 berfungsi untuk menentukan jml jam mengajar
Untuk combo2 berfungsi untuk menentukan status jabatan diluar kbm
Cara setting combo dengan cara klikkanan lalu builder dan isian data di colom1sesuai dengan data yang dibutuhkan lihat gb





Dan ini hasil laporannya




Ini kode listingnya,silahkan dicopas
Code hitung
a = thisform.text3.Value
b = thisform.text5.Value
c = thisform.text6.Value
d = thisform.text7.Value
e = thisform.text8.Value
e = (a+b+c)-d
thisform.text8.Value=e

code batal

thisform.combo3.Value=" "
thisform.combo4.Value=" "
thisform.text2.Value=" "
thisform.text3.Value=0
thisform.text4.Value=" "
thisform.text5.Value=0
thisform.text6.Value=0
thisform.text7.Value=0
thisform.text8.Value=0
thisform.combo1.Value=" "
thisform.combo2.Value=" "
thisform.combo3.Enabled= .T.
thisform.combo4.Enabled= .T.

 code close
thisform.Release

code simpan

SELECT tbhonor

APPEND BLANK

replace kdguru WITH thisform.combo3.Value
 IF thisform.combo3.Value="01-20"
    thisform.combo4.Value="21-40"
    endif 
replace nama_guru WITH thisform.text2.Value
replace jml_jam WITH thisform.combo1.Value
replace jml_honor WITH thisform.text3.Value
replace tgl WITH thisform.text4.Value
replace koreksian WITH thisform.text5.Value
replace jabtan WITH thisform.combo2.Value
replace honor_jabatan WITH thisform.text6.Value
replace potongan WITH thisform.text7.Value
replace gaji_bersih WITH thisform.text8.Value

code hapus
delete
thisform.combo3.Value=""
thisform.combo4.Value=""
thisform.text2.Value=""
thisform.combo1.Value=""
thisform.text3.Value=""
thisform.text4.Value=""
thisform.text5.Value=""
thisform.combo2.Value=""
thisform.text6.Value=""
thisform.text7.Value=""
thisform.text8.Value=""
thisform.grid1.Refresh

code preview
REPORT FORM laporanguru.frx TO PRINTER preview

Code form1(activate)

SET DELETED ON
thisform.combo3.Value=" "
thisform.combo4.Value=" "
thisform.text2.Value=" "
thisform.combo1.Value=" "
thisform.text3.Value=0
thisform.text4.Value=" "
thisform.text5.Value=0
thisform.combo2.Value=" "
thisform.text6.Value=0
thisform.text6.Value=0
thisform.text7.Value=0
thisform.text8.Value=0
thisform.combo3.SetFocus()

code grid1(afterrowcolchange)

LPARAMETERS nColIndex
SELECT tbhonor
thisform.combo3.Value=kdguru
thisform.combo4.Value=kdguru
thisform.text2.Value=nama_guru
thisform.combo1.Value=jml_jam
thisform.text3.Value=jml_honor
thisform.text4.Value=tgl
thisform.text5.Value=koreksian
thisform.combo2.Value=jabtan
thisform.text6.Value=honor_jabatan
thisform.text7.Value=potongan
thisform.text8.Value=gaji_bersih
thisform.grid1.Refresh

mogs msnfaat
Mohon maaf bila ada kekurangan