Q
queeneileen
I want to write a routine that allows someone to use the template for
a certain time period. After that time period, I want them to stop
using the program without renewing so the information stays current.
The following routine will work, except I want the value to be stored
in a Hidden Workbook or in the Registry. Then I only need to pass one
file (the Hidden Workbook or bat file to update the registry). The
template will be used to create files that will store data, so I don't
want to touch EVERY file if they choose to keep using. The date needs
to be stored externally......
'Private Sub Workbook_Open()
'With Worksheets("Sheet1").Range("A1")
'If .Value = "" Then
' .Value = Now
'Else
'If .Value + 365 <= Now Then
' MsgBox "Expired"
' ThisWorkbook.Close
'End If
'End If
'End With
'End Sub
Can someone assist me with the code?
a certain time period. After that time period, I want them to stop
using the program without renewing so the information stays current.
The following routine will work, except I want the value to be stored
in a Hidden Workbook or in the Registry. Then I only need to pass one
file (the Hidden Workbook or bat file to update the registry). The
template will be used to create files that will store data, so I don't
want to touch EVERY file if they choose to keep using. The date needs
to be stored externally......
'Private Sub Workbook_Open()
'With Worksheets("Sheet1").Range("A1")
'If .Value = "" Then
' .Value = Now
'Else
'If .Value + 365 <= Now Then
' MsgBox "Expired"
' ThisWorkbook.Close
'End If
'End If
'End With
'End Sub
Can someone assist me with the code?