Can you save the component programmatically?

Using Dosave and Dosavenow functions.