need a script can solve a DHCP + HotSpot issue

hi all
good day

please i need a script can solve the issue in the post below

http://forum.mikrotik.com/t/static-dhcp-hotspot-problem-any-help/93845/1

any help please?