Tom [..] > > If GetSection(strSection) Then Response.Write strSection > > *Exactly* what I wanted! I'm so crusty at ASP I would have never written that. One issue - when I > comment out the line above of course my variable doesn't get set. I tried just putting: > > GetSection(strSection) > > As the last line, but that doesn't seem to call the function or something. I'm using this code in > my LIs: > > <% If (strSection = "Deployment") Then %> id="current"<% End If%> > > I need it to work *without* writing out the strSection of course :) Can ya help a brother?! I > swear I forgot more about ASP than I ever knew :/ I've used ByRef for the argument in order that the return value of the function can be used to gauge the success of the operation. Thus, one could do something like this: <% Dim strSection If Not GetSection(strSection) Then 'Log the fact that there was some kind of a problem with the operation End If %> <% If (strSection = "Deployment") Then %> id="current"<% End If%> Or, you could simply do this: <% Dim strSection Call GetSection(strSection) %> <% If (strSection = "Deployment") Then %> id="current"<% End If%> Or, modify GetSection thus: <% Function GetSection() Dim iPos Dim strScriptName strScriptName = Request.ServerVariables("SCRIPT_NAME") iPos = InStrRev(strScriptName, "/") If iPos = 0 Then Exit Function strScriptName = Left(strScriptName, iPos - 1) iPos = InStrRev(strScriptName, "/") If iPos = 0 Then Exit Function strScriptName = Right(strScriptName, Len(strScriptName) - iPos) GetSection = strScriptName End Function %> <% If (GetSection() = "Deployment") Then %> id="current"<% End If%> I prefer the first method personally because IMHO it gives more flexibility in deployment in the future. The second method is fine, but in the event of any problems it lends itself less to handling the issue gracefully. HTH Regards Chris Marsh "Cthulhu for President. Why vote for a lesser evil?" --Cthulhu.org