Hi,
Follow the FF documentation, you can try to use this code
add_action('fluentform_before_submission_confirmation', 'your_custom_confirmation_function', 20, 3);
function your_custom_confirmation_function( $entryId, $formData, $form )
{
// Do your stuff here
MB_Relationships_API::add( get_queried_object_id(), $entryId, 'your-relationship-ID', $order_from = 1, $order_to = 1 );
}
to add the relationship between the post submitted via the form and the current page that shows the form.