public TopicConnectionHandler(TopicData data) { MessageReceived += DoNothing; // set topic data TopicData = data; // make sure handler is clear before setting a new one _TopicHandler = null; // convert subscription emum to string string subscriptionName = Enum.GetName(typeof(Subscriptions), TopicData.subscription); // assign handler _TopicHandler = new ServiceBusTopicHandler(TopicData.TopicConnectionString, TopicData.topic, subscriptionName, ProcessTopicMessagesAsync); }