Author Topic: AquaGage Scale Factor  (Read 1016 times)

m.hesler

  • Newbie
  • *
  • Posts: 13
    • View Profile
AquaGage Scale Factor
« on: May 15, 2018, 04:02:55 PM »
Hi All

I'm after a bit of assistance. I have created the AquaGage, as posted in a previous topic, and made it available for use in my project.
I would like to insert a Scale factor property into the code, but everything I try keeps throwing back errors.
Any help would be greatly appreciated.
Thanks

Archie

  • Administrator
  • Hero Member
  • *****
  • Posts: 5262
    • View Profile
    • AdvancedHMI
Re: AquaGage Scale Factor
« Reply #1 on: May 15, 2018, 05:02:05 PM »
The Gauge in the base package has a ValueScaleFactor. You can either copy the corresponding code from it, or copy it to a new class and inherit your base AquaGage

Godra

  • Hero Member
  • *****
  • Posts: 1438
    • View Profile
Re: AquaGage Scale Factor
« Reply #2 on: May 15, 2018, 06:31:47 PM »
You could also try using the attached AquaGauge controls.

Download all the files, besides for the picture which just shows how it works.

In your solution, inside the AdvancedHMIControls project, right-click the PurchasedControls folder, point to "Add" and select "Existing Item".
Browse to the folder where you downloaded all the files and select AquaGauge.vb (this is WinForms control).
Repeat all the steps and this time select AquaGaugeHMI.vb (this is AHMI control for use with a PLC).

Close all the forms and rebuild the solution. Both controls should show in the Toolbox when you open a form.

m.hesler

  • Newbie
  • *
  • Posts: 13
    • View Profile
Re: AquaGage Scale Factor
« Reply #3 on: May 16, 2018, 03:08:16 AM »
Thanks Archie

I did try that, but couldnt quite get it right. It kept bringing up errors. I'm fairly new to all this. I'll give it another try.
And thanks for those uploads Godra I will try those as well.
By the way you guys do a great job with the AHMI, I'm really impressed with it all

m.hesler

  • Newbie
  • *
  • Posts: 13
    • View Profile
Re: AquaGage Scale Factor
« Reply #4 on: May 16, 2018, 03:18:02 AM »
Hi Godra

I just tried them. They are great. I cant thank you enough.

m.hesler

  • Newbie
  • *
  • Posts: 13
    • View Profile
Re: AquaGage Scale Factor
« Reply #5 on: May 21, 2018, 06:35:37 PM »
Hi Guys

I need a little further assistance with the AquaGauge.
The downloads that Godra sent have values for Threshold Percentage and Recommended Value.
I would like to read a floating point from the PLC for both these values to control the position of the Threshold.
Can this be done in the setter method, in the PLC address Value property of the AquaGauge Control.
I have tried the convert.tosingle method, but it keeps throwing back errors.
Thanks

Phrog30

  • Guest
Re: AquaGage Scale Factor
« Reply #6 on: May 21, 2018, 07:53:56 PM »
I haven't looked at the control, but you should be able to change the current data type from integer (I'm assuming that's what it is) to decimal. I wouldn't have used integer to start with because it limits you.