I have added refreshcontrol to my table view , while pulling down , it should call a local method with dictionary as parameter. But i searched a lot but couldnt send a dictionary as a parameter in addTarget of uirefreshcontrol. Please help me calling a local method with dictionary as a parameter.
What i have tried is using objc and also without selector but it didnt work.
let defaultParam = ["buyer_id":UserDefaults.standard.string(forKey: "UserName")!,"transaction_type":""]
refreshControl.addTarget(self, action: "loadStatement:", for: .valueChanged)
}
func loadStatement(parameter : Dictionary<String, Any>) {
}
It would be very helpful if i can call this local method with parameter i wish to send.