yyyy-mm-dd

  1. K

    Help with Select Case

    Hi All, I need help with a Select Case in my code. I'm new to VBA and have never used the Select Case function. With my online research, I found some examples, but none is really giving me the information that I need. When the user call a UserForm (frmResource) from any one of the sheets Monday...
  2. M

    Problems converting date to text

    I have a date stored in a variable: invDate (mm/dd/yyyy). As part of my sub I need to convert it to text in the format "yyyy-mm-dd". I've seen several solutions on this board, but for some reason they aren't working for me: expItemDate = VBA.Format(CStr(invDate), "yyyy-mm-dd") - doesn't work...
  3. M

    Formatting Date in VBA?

    Hi Folks, I haven't had any luck in getting my code to reformat Date from 5/14/2018 to something without the forward slash. The code I found when I searched for a solution simply doesn't work for some reason. Here's my code showing all the iterations I've tried to reformat the Date...
  4. H

    Module Crashing Excel but Don't know why

    Hi guys so I have a module that is crashing excel every time and I don't know why. I will paste it below. This path does not have two string variables declared; destinationpath and sourcepath When I try to add the declarations (as seen below), then press f8 to step through the module, the...
  5. P

    auto close

    Hello. I am trying to create a macro that every time I close the file the macro makes a copy of that file. So far I have this but it still does not work well. Someone can help me? Thank you, Isabel Sub auto_close() If ThisWorkbook.Path = "\\Servidor\servidor\ORÇAMENTOS\orç - A Fazer"...
  6. D

    Excel VBA Using Text

    I looked, but don't see this posted, yet. This is a newbie question for someone learning VBA. I'm looking to format a date as text using a VBA formula. Why? Well, the reason is because the spreadsheet is exported and downstream is wanting a yyyy-mm-dd format. I'm looking to create a version of...
  7. R

    reformatting dates and finding latest (VBA)

    Hi there, I have a worksheet with 5 dates in cells (A1, A101, A201, A301 & A401) - they are all formatted dd/mm/yyyy I need to copy the date from these cells to other cells on another sheet but change the formats to yyyy-mm-dd - I thought I could use: Date1 = Sheets("Sheet1").Range("A1").Value...

Some videos you may like

This Week's Hot Topics

Top