Problem is with danhsachbt array initialization. It's a Zero Index based array and you are initializing from 1.
danhsachbt(1) = Button1
danhsachbt(2) = Button2
danhsachbt(3) = Button3
danhsachbt(4) = Button4
danhsachbt(5) = Button5
danhsachbt(6) = Button6
Change above code to
danhsachbt(0) = Button6
danhsachbt(1) = Button1
danhsachbt(2) = Button2
danhsachbt(3) = Button3
danhsachbt(4) = Button4
danhsachbt(5) = Button5
you also need to make appropriate changes where required, I mean now you have to loop from 0 to 5 not 1 to 6.
Regards
Rushi