4 Topics

Member Avatar for
Member Avatar for GrantB

Im trying to create a random 6 digit numeric code that will not repeat. I have tried using guid but that was unsuccessful. random rnd = new random(); int num = rnd.next(000001,999999); I would prefer not to use Random , or to have to iterate through all the previous codes …

Member Avatar for Ketsuekiame
0
2K
Member Avatar for xanawa

Hi, I encrypted two strings and returns example "euHK5s9h30Q=" then I am trying to convert the string given to GUID Guid tokenGuid = new Guid(encryptionString); and i is giving me ***Guid should contain 32 digits with 4 dashes (xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx).*** error how can i resolve it please?

Member Avatar for Ketsuekiame
0
260
Member Avatar for ThomsonGB

Without the complete context to summarize: [CODE] #include "stdafx.h" #include <iostream> #include <fstream> #include <string> #include <stdio.h> #include <stdlib.h> #include <time.h> #include <objbase.h> using namespace std; BYTE* StringToGUID(LPOLESTR szBuf) { GUID *g = (GUID *) malloc( sizeof(GUID)); HRESULT h2 = CLSIDFromString(szBuf, g); return (BYTE*) g; } [/CODE] I Get: 1>Linking... …

Member Avatar for ThomsonGB
0
2K
Member Avatar for chrishtones

Since __uuidof is a C++ only operator, how would I retrieve the GUID of an object in C?

Member Avatar for gerard4143
0
619

The End.