Excel VBA - getting a Highpart from a DOUBLE value

C

ConfNoob

i have a ADSI lastLogon stored inside a Excel 2000 cell.

to calculate a date/time .... i have to get .highpart / .lowpart from
this cell.

tried to create a LARGE_INTEGER type in the declarations , but am
geting a
"ONLY USER DEFINED TYPES defined in public object modules..." Compile
time error

i know its possible in VB ....

not in VBA with Excel 2000

please help ... how can i get the highpart/lowpart from this cell's
..Value ?
 
M

Michael Bednarek

i have a ADSI lastLogon stored inside a Excel 2000 cell.

to calculate a date/time .... i have to get .highpart / .lowpart from
this cell.

tried to create a LARGE_INTEGER type in the declarations , but am
geting a
"ONLY USER DEFINED TYPES defined in public object modules..." Compile
time error

i know its possible in VB ....

not in VBA with Excel 2000

please help ... how can i get the highpart/lowpart from this cell's
.Value ?

The LastLogon value in AD, like many other date values, is stored as a
Large Integer, or Integer8, a 64-bit quantity. I doubt that Excel can
deal with those, so the data in your workbook is not exactly what AD
stored.

I suggest you do whatever it is you want to do without Excel, or prepare
the LastLogon as a date string before you go to Excel.

See also: <http://www.rlmueller.net/Last Logon.htm>,
<http://groups.google.com.au/group/m..._frm/thread/caa0f51d42ac70e2/23373dbe054dfa73>.
 
Top