You would be better off with this pattern which is asynchronous and needs no WhenAll, Call it without creating a new instance of the class then the result can be deconstructed from the named value tuple for success/failure and if the exception is not null
show exception.Message.
using System;
using System.Data;
using System.Data.SqlClient;
using System.Threading.Tasks;
namespace Project1.Classes
{
public class DataOperations
{
private static string ConnectionString = "TODO";
public static async Task<(bool success, Exception exception)> SaveData(string xml)
{
try
{
await using var con = new SqlConnection(ConnectionString);
await using var cmd = new SqlCommand("USP_CSMAddTabTickerAndClientWise", con);
using var da = new SqlDataAdapter(cmd);
await con.OpenAsync();
cmd.CommandType = CommandType.StoredProcedure;
cmd.Parameters.Add("@Xml", SqlDbType.Xml).Value = xml;
return ((await cmd.ExecuteNonQueryAsync() > 0), null);
}
catch (Exception ex)
{
return (false, ex);
}
}
}
}