Yes, you can use a vacuum cleaner to clean your hardwood floor, as long as it has a specific wooden floor cleaning attachment. The ordinary attachments and bristles could scratch, mark or dent your hardwood floor.
If you do not have a vacuum with a wooden floor cleaning attachment, then you can sweep your hardwood floor with a soft bristle brush instead. For more information on cleaning your hardwood floor, see ‘How to clean my wooden floor’.