We continue by setting the roughness. Starting with the main roughness section. The following code sets the default roughness of the main roughness section to StricklerKs with a default value of 30.
Now we create a new roughness section and "FloodPlain" and make cross-sections "prof_SW2815-SW2870_Bo" and "prof_D20060515-DP-295" use it. To declare roughness sections on cross-sections, you need to declare the start and end distancealong the cross-section. Because we want these cross-sections to only use our new "FloodPlain" section we use the min and max of the cross-section profile using the "GetMinYMaxYofCrossSectionProfile" function.