| Visioscan Set SDK Libraries 1.3.5 Visioscan Set SDK Help documentation file for C++ and C++/CLI |

Loading...
Searching...
No Matches
WUtilities.h
1#pragma once
2
3#include<string>
4#include <codecvt>
5#include<cstring>
6
7#include <msclr\marshal_cppstd.h>
8 using namespace std;
9 using namespace System;
10 using namespace System::Runtime::InteropServices;
11
12 namespace WUtils {
13 public ref class WConverter
14 {
15 public:
16 static char* ConvertToNativeString(String^ toConvert) {
17 msclr::interop::marshal_context context;
18 std::string atest = context.marshal_as<string, String>(toConvert);
19 IntPtr ptrToNativeString = Marshal::StringToHGlobalAnsi(toConvert);
20 char* nativeString = static_cast<char*>(ptrToNativeString.ToPointer());
21 return (char *)nativeString;
22 }
23 };
24
25 public enum class MeasurmentUnit
26 {
27 Millimeters = 0,
28 Inches = 1
29 };
30}
31
WUtils
Definition WAvailableResolution.h:7
WUtils::MeasurmentUnit
MeasurmentUnit
Definition WUtilities.h:26
WUtils::MeasurmentUnit::Millimeters
@ Millimeters
WUtils::MeasurmentUnit::Inches
@ Inches
WUtils::WConverter
Definition WUtilities.h:14
WUtils::WConverter::ConvertToNativeString
static char * ConvertToNativeString(String^ toConvert)
Definition WUtilities.h:16