VBA question

Discussion in 'Trading Software' started by vladiator, Mar 6, 2003.

  1. Hey guys, I'm either getting dumb or just too sleep deprived.
    Isn't every Excel function available in VBA via Application.WorksheetFunction. ?
    I thought so. I'm trying to use the Date(Year,Month,Day) function and it's not recognized.:confused:
  2. I figured out a "round and about" way to get what I need, but still, curios if I was wrong in assuming all excel function could be used in VBA. I've used a whole bunch before and this is the first time I that I came across smth that's not working.
  3. stu


    I think objects that refer to a range work in Application.WorksheetFunction , date doesn't use a range reference.
    Even so I would use the Date command assigned to a variable then drop that to the worksheet... as it can be formatted in the module too :)
  4. CalTrader

    CalTrader Guest

    Not all worksheet functions are available to VB .....Date is not included
  5. Thanks guys!