Yes, u are doing right.
Use the generated code and Unlock Region in Mapsource