Task is easy for first look.
I just need "Object" -> "Artboards" -> "Fit to Artwork Bounds" in script.
But can't find such function! Please, help me to find, if u know.
Assuming you have already made your selection, and assuming you're using CS6+, you can use:
this will fit the first artboard (zero index) to the selected art. You can replace 0 with whatever index you want, so long as an artboard with that index exists.
Retrieving data ...