VitoCorleone
Programmer
I have created a dynamic site map in asp using FSO which displays all the files in a particular folder and exclude file extensions such as .xls, .ppt etc so only my asp and html pages are listed.
Now.... when the files are displayed, the FSO diplays the file name. example - 'gs_finance_team.asp'.
for the users i want the name 'Finance Team' to show and not 'gs_finance_team.asp'. So the user knows what it is and i haave a dynamically driven page. Here is a sample of the code I have been using -
----------------------------------------------------------
Dim myteam
Dim people
Dim finance
Dim comm
Dim polices
Dim data
Set myteam = fso.GetFolder(Server.MapPath("/cfo/organisation/"))
Set people = fso.GetFolder(Server.MapPath("/cfo/people/"))
Set finance = fso.GetFolder(Server.MapPath("/cfo/financial_results/"))
Set comm = fso.GetFolder(Server.MapPath("/cfo/communications/"))
Set polices = fso.GetFolder(Server.MapPath("/cfo/processes/"))
Set data = fso.GetFolder(Server.MapPath("/cfo/data_systems/"))
'create a string of dissallowed extensions (lowercase)
DissallowList = "|xls|doc|bak|msg|pdf|ppt|log|aspx|"
for each x in myteam.files
FileExt = Mid(x.Name, InStrRev(x.Name, ".")+1, Len(x.Name) - InStrRev(x.Name, ".") + 1)
If Instr(DissallowList,"|" & lcase(FileExt) & "|") = 0 Then
'Print the name of all files in the test folder
Response.write "<tr><td><a href='/cfo/organisation/" & x.Name & "'>" & x.Name & "</a></td>"
End If
next
%>
-----------------------------------------------------
Can You Help
Now.... when the files are displayed, the FSO diplays the file name. example - 'gs_finance_team.asp'.
for the users i want the name 'Finance Team' to show and not 'gs_finance_team.asp'. So the user knows what it is and i haave a dynamically driven page. Here is a sample of the code I have been using -
----------------------------------------------------------
Dim myteam
Dim people
Dim finance
Dim comm
Dim polices
Dim data
Set myteam = fso.GetFolder(Server.MapPath("/cfo/organisation/"))
Set people = fso.GetFolder(Server.MapPath("/cfo/people/"))
Set finance = fso.GetFolder(Server.MapPath("/cfo/financial_results/"))
Set comm = fso.GetFolder(Server.MapPath("/cfo/communications/"))
Set polices = fso.GetFolder(Server.MapPath("/cfo/processes/"))
Set data = fso.GetFolder(Server.MapPath("/cfo/data_systems/"))
'create a string of dissallowed extensions (lowercase)
DissallowList = "|xls|doc|bak|msg|pdf|ppt|log|aspx|"
for each x in myteam.files
FileExt = Mid(x.Name, InStrRev(x.Name, ".")+1, Len(x.Name) - InStrRev(x.Name, ".") + 1)
If Instr(DissallowList,"|" & lcase(FileExt) & "|") = 0 Then
'Print the name of all files in the test folder
Response.write "<tr><td><a href='/cfo/organisation/" & x.Name & "'>" & x.Name & "</a></td>"
End If
next
%>
-----------------------------------------------------
Can You Help