ASP ShortName ਪ੍ਰਤੀਯੋਗਿਤਾ

ਵਿਆਖਿਆ ਅਤੇ ਵਰਤੋਂ

ShortName ਪ੍ਰਤੀਯੋਗਿਤਾ ਦੀ ਵਰਤੋਂ ਵਾਲੀ ਪ੍ਰਤੀਯੋਗਿਤਾ ਦੀ ਨਾਮ (8.3 ਨਾਮਕਰਨ ਸ਼ਾਸਤਰ) ਨੂੰ ਵਾਪਸ ਦਿੰਦੀ ਹੈ。

ਸਫ਼ਟਿਕਰਨਾਂ:

FileObject.ShortName
FolderObject.ShortName

ਉਦਾਹਰਣ

ਫਾਈਲ ਆਬਜੈਕਟ ਦੇ ਉਦਾਹਰਣ ਲਈ

<%
dim fs,f
set fs=Server.CreateObject("Scripting.FileSystemObject")
set f=fs.GetFile("c:\hitcounterfile.txt"))
Response.Write("Name: " & f.Name)
Response.Write("<br />ShortName: " & f.ShortName)
set f=nothing
set fs=nothing
%>

خروجی:

Name: hitcounterfile.txt
ShortName: HITCOU~1.TXT

ਫੋਲਡਰ ਆਬਜੈਕਟ ਦੇ ਉਦਾਹਰਣ ਲਈ

<%
dim fs,fo
set fs=Server.CreateObject("Scripting.FileSystemObject")
set fo=fs.GetFolder("c:\asp_test_web")
Response.Write("Name: " & fo.Name)
Response.Write("<br />ShortName: " & fo.ShortName)
set fo=nothing
set fs=nothing
%>

خروجی:

Name: asp_test_web
ShortName: ASP_TE~1