Power Apps – Validate the URL only if the URL is entered in text box

Updated on 4 Sept 2023 A comment from the respected viewer indicates that the results from the original post arent correct. So i did my quick delegence. Following are the steps 1. Add one Text Input Control (Name: TextInput1) 2. Add one Text Label Control (Name: Label1) 3. Update the Text property of Label Control with PowerFx function as below If(!IsBlank(TextInput1.Text) && IsMatch(TextInput1.Text,”(https?:\/\/(?:www.|(?!www))[a-zA-Z0-9][a-zA-Z0-9-]+[a-zA-Z0-9].[^\s]{2,}|www.[a-zA-Z0-9][a-zA-Z0-9-]+[a-zA-Z0-9].[^\s]{2,}|https?:\/\/(?:www.|(?!www))[a-zA-Z0-9]+.[^\s]{2,}|www.[a-zA-Z0-9]+.[^\s]{2,})”,MatchOptions.Complete),””,”Please provide the … Continue reading Power Apps – Validate the URL only if the URL is entered in text box