< %
const lie = 3 'изменить количество столбцов
const tablewidth = 33% 'определить ширину формы
Const tableHeight = 18% 'определить высоту таблицы
Const imgwidth = 15% 'определить ширину таблицы
const imgheight = 27,5% 'Определите высоту таблицы
const fontsize = 12px;
const txtwidth = 120 'изображение правая текстовая таблица ширина
const txtheeth = 18% 'изображение правой текстовой таблицы высокая
const txtalign = левое «изображение правого текста Метод выравнивания текста: слева, в центре, справа
'Top подчеркивает, что файл является файлом слов
Функция doctop ()
Doctop = <html xmlns: v = urn: schemas-microsoft-com: vml xmlns: o = urn: schemas-microsoft-com: Office: w = urn: schmas- Microsoft-Com: Office: Word xmlns = http: // www.w. > </meta> </meta> </meta> <meta name = progid content = word.document> </meta> <meta name = genator content = microsoft word 10> </meta> <meta name = content = Originator = Microsoft Word 10> <style type = text/css>@ page section1 {margin: 30pt 8.5pt 5.65pt 12pt;} div.section1 {page: section1;} table {font-size: & fontsize &} </meta> < /head>+chr (13)+chr (10)
конечная функция
Функция Imgtotable (FTO, FPAR, DEXT)
Imgtotable = <table width = & tablewidth & height = & tableheight & border = 0>
Imgtotable = imgtotable+<tr valign = top> <td> <img src = & reply (demo, fpar,) и width = & imgwidth & height = & imageighry &/> </td>
Imgtotable = imgtotable+<td colspan = 2 align = center>
Imgtotable = imgtotable+<table width = & txtwidtht & height = & txtheight &> <td align = & txtalign &> & reply (fto.name),. Td align = & txtalign &> actor </td> </tr> <lign = & txtalign &> language </td> </tr> <td align = & txtalign &> емкость </td> </tr> < ter> <td align = & txtalign &> type </td> </tr> </table>
imgtotable = imgtotable+</td> </tr> </table>+chr (13)+chr (10)
конечная функция
Функциональный ImageTodoc (FPATH, FPAR)
Установить fto = fso.createTextFile (fpath &/run refuls.doc, true)
fto.writeline doctop ()
fto.writeline <body topmargin = 0 Leftmargin = 0> <Table Width = 64 высота = 100% граница = 1> <div class = section1>
Для каждой демонстрации в fpath.files
dext = lcase (fso.getextensionname (demo))
Если dext = jpg или deb = gif или dext = png, тогда
if (i mod lie) = 0, затем fto.writeline <tr>+chr (13)+chr (10)
I = i+1
fto.writeline <td>
'Используется для ошибок
'fto.writeline 123
Fto.writeline imgtotable (демонстрация, fpar, dext)
fto.writeline </td>+chr (13)+chr (10)
if (i mod Lie) = 0, тогда i = 0: fto.writeline </tr>+chr (13)+chr (10)
конец, если
следующий
fto.close
response.write </div> </table> </body>
Response.Write & FAO & FPATH &/RUN -результаты. <br />
установить fto = ничего
конечная функция
Установить fso = server.createObject (scripting.filesystemobject)
Установить fo = fso.getFolder (server.mappath (./))
Для каждой демонстрации в FPO.Subfolders
вызовать ImageTodoc (демо,)
следующий
установить fo = ничего
Установить FSO = ничего
%>