luisllamasbinaburo / EwelinkNET

eWeLink API for .NET Standard (Windows, Linux and Mac)
https://www.luisllamas.es
Apache License 2.0
35 stars 9 forks source link

Cant make it work #7

Closed Szanesz closed 3 years ago

Szanesz commented 3 years ago

Hello! Finally someone started to make an ewelink api!! we are very excited ! Unfortunately i cant make it work. I try to use int under WPF, without success... I createsd a test-app with winform (vb.net), but im still not sure what do i do wrong...

At start it drops: FileNotFoundException: A(z) „netstandard, Version=2.1.0.0, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51”

My code: Imports EwelinkNet Imports EwelinkNet.Classes

Public Class Form1 Private ewelink = New Ewelink("szaensz@szanesz.net", "mypassword****", "hu") Private Sub Form1_Load(sender As Object, e As EventArgs) Handles MyBase.Load End Sub

Private Sub Button1_Click(sender As Object, e As EventArgs) Handles Button1.Click
    Dim device = TryCast(ewelink.Devices.First(Function(x) x.deviceid = 0), SwitchDevice)
    device.TurnOn()
End Sub

End Class

Peter

luisllamasbinaburo commented 3 years ago

You're app is not compatible with .net standard 2.1. Use the correct framework version