CZKEM does not contain definition (zkemkeeper-related) - visual-studio

I am using the Standalone SDK from ZKTEco for a fingerprint scanner. I need to add some custom functionality.
I've downloaded the SDK along with the Demo project. Now when I try to build the Demo project, I get the following error
"Severity Code Description Project File Line Suppression State
Error CS1061 'CZKEM' does not contain a definition for 'SetUserValidDate'
and no accessible extension method 'SetUserValidDate' accepting a first
argument of type 'CZKEM' could be found (are you missing a using directive
or an assembly reference?)"
I have referenced the zkemkeeper.dll file in my project. I'm using VB 2017 on Windows 10. I've tried to look for Embed Interop Types property but I cannot find it in the properties ofzkemkeeper
How can I solve this issue? Any help would be appreciated.
Thanks

I order to make any project referencing the zkemkeeper compile, you need to register it in the windows system.
You should have received a bat file among the dll files called "Register_SDK" as shown in . This is used to register the zkemkeeper in windows. If not, then you must register it manually.
Please, read these posts:
Post 1
Post 2
There is also a starting guide for newbies already written by another member of this community, it´s written in c#.
Best regards.

Related

How do I add an Apple class to a project in Visual Studio for Mac

I have a really tough question. How would I add a class in Visual Studio for Mac?
More specifically, how do I reference any class?
I'm going through the instructions here. It says there is an Audio Player example that uses the AVAudioPlayer class.
It doesn't specifically say how to add that class but going to the Projects > Add Reference menu and typing Audio in the search box shows nothing:
This is the instruction page I've referenced:
https://learn.microsoft.com/en-us/xamarin/mac/app-fundamentals/sounds
The page also says it's an example but I don't see any code only an API reference.
Apple APIs
https://developer.apple.com/documentation/avfaudio/avaudioplayer#see-also
https://developer.apple.com/documentation/avfaudio/avaudioengine
UPDATE:
I think I might have figured it out.
The class looks like it was in AVFoundation package not AVFAudio:
To use it you have to put:
using AVFoundation;
at the top of your class
Then in your code you can use:
var player = new AVAudioPlayer();
Or it looks like you can use the full namespace to create an instance:
var player = new AVFoundation.AVAudioPlayer();
I'm still getting errors so I don't know if that's it or not.
I also added some Nugen libraries like Xamarin.CommunityToolkit but I don't see them referenced in so I don't know if that's necessary.
Update 2:
It looks like the instructions for that are here:
https://learn.microsoft.com/en-us/visualstudio/mac/nuget-walkthrough?view=vsmac-2019
Here are the errors I'm getting:
/Applications/Visual
Studio.app/Contents/Resources/lib/monodevelop/bin/MSBuild/Current/bin/Microsoft.Common.CurrentVersion.targets(5,5):
Warning MSB3276: Found conflicts between different versions of the
same dependent assembly. Please set the "AutoGenerateBindingRedirects"
property to true in the project file. For more information, see
http://go.microsoft.com/fwlink/?LinkId=294190. (MSB3276) (project)
/Users/me/project/packages/Xamarin.CommunityToolkit.1.1.0/build/PreserveXamarinCommunityToolkit.cs(12,12):
Error CS0246: The type or namespace name 'PreserveToolkitAttribute'
could not be found (are you missing a using directive or an assembly
reference?) (CS0246) (project)
Side note:
There doesn't seem to be much activity here on SO, so I attempted to visit the Visual Studio forums and to post you have to join the Microsoft docs network. Here's some of the details when attempting to sign up. They didn't mention this before signing up.

Adding VBA reference in VB6.0

I have a old VB 6.0 application written by someone else. When i compile the application, it throws error on every line of code where VBA reference is required so fro e.g. it throws an error in the following lines:
Left$, Chr, Trim$
As soon as I prefix it with VBA.Left$, the error goes away. I was looking at the list of project References and saw only one missing reference called "Microsoft DTS run time 1.0". Where can I get this reference from and how can I add this in VB application. Also, is there any way, I can add VBA reference to VB application. I am running this VB application on XP machine.
any help will be appreciated.
Then you should install Microsoft DTS runtime:
How to: Install Support for Data Transformation Services Packages:
https://technet.microsoft.com/en-us/library/ms143755(v=sql.105).aspx
After, add the VBA reference (if is missing)
If you look at your list of Available References, you should see one for Visual Basic For Applications. Make sure this is checked and you will be good to go.
If there is more than one reference for VBA, select the one for msvbvm60.dll.

how to create QR code in windows phone 7.1

Please tell how to generate QR code in Windows Phone 7.1. I have tried this urlThomasVestergaard
I'm using Silverlight_ZXing_Core version v2.0.50727 library.
But When I used code from above link I have following issue
1.System.Windows.Media.Imaging.WriteableBitmap' does not contain a definition for 'SetPixel' and no extension method 'SetPixel' accepting a first argument of type 'System.Windows.Media.Imaging.WriteableBitmap' could be found (are you missing a using directive or an assembly reference?)
Please tell me how to resolve this as soon as possible.
Thanks
You should check WriteableBitmapEx library. It has extension methods for GetPixel() and SetPixel() in addition to other useful stuff.

Error building DataAnnotationsModelBinder project to get the Microsoft.Web.Mvc.DataAnnotations.dll

I am refering to the "Validation with Data Annotations tutorial" here http://www.asp.net/mvc/tutorials/older-versions/models-(data)/validation-with-the-data-annotation-validators-cs for my database first MVC3 project. I downloaded the DataAnnotationsModelBinder project but having difficulty building it. It throws following errors:
Error 1 'System.Web.Mvc.IValueProvider' does not contain a definition for 'DoesAnyKeyHavePrefix' and no extension method 'DoesAnyKeyHavePrefix' accepting a first argument of type 'System.Web.Mvc.IValueProvider' could be found (are you missing a using directive or an assembly reference?) C:\XYZ\DataAnnotationsModelBinder\src\DataAnnotationsModelBinder.cs 47 17 Microsoft.Web.Mvc.DataAnnotations
Error 2 Metadata file 'C:\XYZ\DataAnnotationsModelBinder\src\bin\Debug\Microsoft.Web.Mvc.DataAnnotations.dll' could not be found Microsoft.Web.Mvc.DataAnnotations.Tests
Am I missing anything? I tried using VS2008 as well as VS 2010.
Please help.
I'm assuming that you have some missing references, so you need to include the missing references in the project.
You can do this by right clicking the references folder and add them manually. (see image)
Refrences - image
You should not use the DataAnnotationsModelBinder with MVC3. The DefaultModelBinder class already contains all of the logic that was present in the DataAnnotationsModelBinder sample you have linked to.
You probably need to add a reference to System.Web.Mvc 1.0 instead of what you're got at the moment.

Custom building SGEN assemblies and including in installer

I've been rather confused by some SGEN stuff. I've enable the generation of serialization assemblies for one of my projects. Originally I got the follow error which I believe I've solved by doing some caspol stuff on a remote assembly.
Unable to load one or more of the request types. Retrieve the
LoaderExceptions propery for more information
Now however, I don't get an assembly generated. Adding some debugging/verbose output provides the message "SS.dll does not contain any types that can be serialized using XmlSerializer". I've read that this is because of a proxy switch applied by VS. The odd thing is it doesn't seem to be a problem with any other project.
So if I disable the proxy switch (example here) it seems to work. The linked build events however seem to do all projects. I don't know enough about MSBuild to tweak to just a single project, does anyone know what I need to change?
Additionally, if this change is made, is there a way I can automatically include this in a installer (VDProj)? I can't statically link to the SS.XmlSerializers.dll because the each dev uses a custom path.
Discovered the following post which talks about adding the <SGenUseProxyTypes>Off</SGenUseProxyTypes> to the csproj file which seems to work :)

Resources