Sunday, 15 February 2015

How can I generate UUID in c++, without using boost library? -



How can I generate UUID in c++, without using boost library? -

friends, want generate uuid application distinguish each installation of application. want generate uuid using c++ without boost library support. pls help me generate uuid using other opensource library.

note: platform windows

as mentioned in comments, can utilize uuidcreate

#pragma comment(lib, "rpcrt4.lib") // uuidcreate - minimum supported os win 2000 #include <windows.h> #include <iostream> using namespace std; int main() { uuid uuid; uuidcreate(&uuid); char *str; uuidtostringa(&uuid, (rpc_cstr*)&str); cout<<str<<endl; rpcstringfreea((rpc_cstr*)&str); homecoming 0; }

c++ uuid

No comments:

Post a Comment