My code is:
<html> <script Language="VBScript"> sCurPath = CreateObject("Scripting.FileSystemObject").GetAbsolutePathName(".") Sub Window_OnLoad ForReading = 1 Set objFSO = CreateObject("Scripting.FileSystemObject") Set objFile = objFSO.OpenTextFile _ (sCurPath+"\lol.txt", ForReading) Do Until objFile.AtEndOfStream strLine = objFile.ReadLine Set objOption = Document.createElement("OPTION") objOption.Text = strLine objOption.Value = strLine FileContent.Add(objOption) Loop objFile.Close End Sub </SCRIPT> <body> <select size="5" name="FileContent" style="width:250"></select> </body> </html>