sub s()
dim wb as workbook
dim ws as worksheet
set wb = activeworkbook
dim mydate
dim i, j as integer
for i = 4 to 31
set ws = wb.worksheets(trim(str(i)))
mydate = dateserial(2010, 1, i)
if weekday(mydate) = vbmonday or weekday(mydate) = vbwednesday or weekday(mydate) = vbfriday then
ws.cells(29, 7).value = 8
end if
for j = 47 to 53
ws.cells(j, 1).value = ""
ws.cells(j, 3).value = ""
ws.cells(j, 6).value = ""
ws.cells(j, 8).value = ""
next
next
end sub
利用Excel VBA處理文件
遇到如下格式的一篇word文件,格式混亂,不適合列印 由於沒有接觸過word vba,因此決定用excel vba來處理這篇文件。首先全選該文件的內容,貼上到excel文件中。然後建立乙個新的macro,修改該macro為以下 sub formatsheet formatsheet macro ma...
mysql 日期處理 mysql日期處理函式
mysql自己有格式化日期格式的函式 date format date,format 根據format字串格式化date值。下列修飾符可以被用在format字串中 m 月名字 january december w 星期名字 sunday saturday d 有英語字首的月份的日期 1st,2nd,...
mysql日期處理 mysql日期處理函式例項解析
這篇文章主要介紹了mysql日期處理函式例項解析,文中通過示例 介紹的非常詳細,對大家的學習或者工作具有一定的參考學習價值,需要的朋友可以參考下 首先建立一張實驗用的一張表 drop table if exists t student create table t student id int pr...