I do know that there are no switch statements in RF. I do have 50 if-keywords (that I use because no switch exists). My log file is very long because literally every 50 if statements are logged (even those who are not true). I would like to know if there is a way to log only the statements that are true?
here is how my code is written (there are 50 keywords like these) :
# Access Apply ImportExportParams
\ Run Keyword If '${Type}' == 'ImportExportParams' and '${DealId}' != 'None' and '${ScenarioId}' != 'None' Call_API_ImportExportParams ${DealId} ${ScenarioId} ${ProductId}
# Access bulk apply cheapest quote
\ Run Keyword If '${Type}' == 'BulkApplyCheapest' and '${DealId}' != 'None' and '${ScenarioId}' != 'None' Call_API_BulkApplyCheapest ${DealId} ${ScenarioId} ${ProductId}
# SiteSelection
\ Run Keyword If '${Type}' == 'SiteSelection' and '${DealId}' != 'None' and '${ScenarioId}' != 'None' Call_API_SiteSelection ${ProductId} ${DealId} ${ScenarioId} ${Name}
# SiteSelectionFile
\ Run Keyword If '${Type}' == 'SiteSelectionFile' and '${DealId}' != 'None' and '${ScenarioId}' != 'None' Call_API_SiteSelectionFile ${ProductId} ${DealId} ${ScenarioId}
\ Run Keyword If '${Type}' == 'SiteSelectionFile2' and '${DealId}' != 'None' and '${ScenarioId}' != 'None' Call_API_SiteSelectionFile2 ${ProductId} ${DealId} ${ScenarioId}
# SiteSelectionMultiple
\ Run Keyword If '${Type}' == 'SiteSelectionMultiple' and '${DealId}' != 'None' and '${ScenarioId}' != 'None' Call_API_SiteSelectionMultiple ${ProductId} ${DealId} ${ScenarioId}
thanks for your help :)




