Hi All,
I have recently updated my winform desktop application from framework 4.0 to 4.6.1.
I have been using microsoft.windowsapicodepack.taskdialog for most of my pop up messagebox.
It is no longer working in 4.6.1.
I have got the System.OverflowException: 'Arithmetic operation resulted in an overflow.' error, during td.show.
This is what I know, the error is only happening if I build the project in 64 bit, no problem found in 32 bit.
Also the error only happens when I add my own custom controls.
td.controls.add(commandlink1).
If I don't add any controls, it is still working, even in 64 bit.
Is there any workaround or solution for this?
Thank you so much
What I have tried:
td = New TaskDialog()
td.InstructionText = "my question"
td.Caption = "my tile"
td.StandardButtons = TaskDialogStandardButtons.Yes Or TaskDialogStandardButtons.No
td.Text = "question caption"
td.Icon = TaskDialogStandardIcon.None
td.StartupLocation = TaskDialogStartupLocation.CenterScreen
cl1 = New TaskDialogCommandLink("cl1", "Option 1", "Caption 1")
cl2 = New TaskDialogCommandLink("cl2", "Option 2", "Caption 2")
td.Controls.Add(cl1)
td.Controls.Add(cl2)
td.OwnerWindowHandle = currentform.Handle
td.show()