View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
TBD TBD is offline
external usenet poster
 
Posts: 41
Default Awesome, Offace!

Hi Offace,
This is great, definately food for thought - started experimenting and
anticipate it may take a while. Wanted to say THANKS! Assuming VBA doesn't
have a simple casting syntax, you're suggestions seem the best - perhaps only
- alternative.
For the record, this is what I'm trying to accomplish (without CType.)
There would be a symmetric Write function as well.

Thanks/Cheers!
P.S. This reply dialog "differs" from what I'm used to(?)
Code:
Public Type DayKey
  dDate As Date
  iRow As Integer
  iCol As Integer
End Type

Public Sub QD_Read(ByVal AbsRow As Integer, _
                   ByVal AbsCol As Integer, _
                   ByRef dDate As Date, _
                   ByRef datRow As Integer, _
                   ByRef datCol As Integer)
  Dim tKey As DayKey
  
  tKey = CType(WS.Cells(AbsRow, AbsCol).Text, DayKey)
  
  dDate = tKey.dDate
  datRow = tKey.iRow
  datCol = tKey.iCol
End Sub