AdvancedHMI Software

General Category => Support Questions => Topic started by: Nelson on April 25, 2016, 11:59:27 PM

Title: About FormChangeButton in C#
Post by: Nelson on April 25, 2016, 11:59:27 PM
Hi everyone,

I am new. And I read Tips as much as possible.
I try using C# by  http://advancedhmi.com/forum/index.php?topic=774.msg3726#msg3726 (http://advancedhmi.com/forum/index.php?topic=774.msg3726#msg3726)
but it not have the FormChangeButton in C#, what should i do?

Thank you a lot!

Nelson
Title: Re: About FormChangeButton in C#
Post by: Archie on April 26, 2016, 03:14:50 AM
You will not have a form change button in any other project except the default Vb project. You will need to change forms via code:

Form2.Show
Me.Hide
Title: Re: About FormChangeButton in C#
Post by: Nelson on April 26, 2016, 04:38:00 AM
Thanks Archie,

I don't know why i can use other controls,but not form change button.
Because it is not inherit from "MfgControl.AdvancedHMI.Controls.dll" ??
I am curious.

Best Regards
Title: Re: About FormChangeButton in C#
Post by: Archie on April 26, 2016, 07:07:58 AM
The FormChangeButton is part of the AdvancedHMI project and not the AdvancedHMIControls project. It has to be in that project because it uses reflection to get a list of forms within the project which it exists. You could convert the FormChangeButton.vb to C# and put it in your C# project.
Title: Re: About FormChangeButton in C#
Post by: Nelson on April 26, 2016, 10:48:13 PM
Thank you for your explanation !!