473,378 Members | 1,134 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,378 software developers and data experts.

FSO problem

I asked this a few weeks ago, but still haven't gotten an answer. Really
stumped.

Intranet app, for tech support, and this app tracks the progress of tickets.
Sometimes, the customer will send us some trace files or logs, so we have a
folder called Tickets on a server on our network. If a ticket number is
1000, then the folder will be called T1000. So I have a link to that
directory that looks like this:

<% SET fso = CreateObject("Scripting.FileSystemObject")
strTraceDir = "\\servername\Tickets\T"&strTicketID
If fso.FolderExists(strTraceDir) then

Else
strTraceDir = "\\servername\Tickets\"
End if
set fso= nothing
%>

<a href="<%=strTraceDir%>" target="_blank">Files:</a>

As you can see, I cannot just assume that there is a folder with a specific
number. Perhaps Ticket 1000 doesn't have a folder yet. If not, then I want
to allow the link to take you to just the root of that drive.

Here's the problem: On my dev machine, this code works fine. When I upload
it to production, the FolderExists part never, ever comes into play. In
other words, it always falls into the Else condition, every time. It's as if
you can't see the folder from the server. But I have checked into that and
you can see it just fine. I also tried to see if the fact that it wasn't
mapped as a drive might be the problem, but I don't think that's it. I also
checked to see that the IUSR account info is the same on both. IIS settings
seem to be the same.

If my code just didn't work, I could deal with that. But the fact that it
doesn't work on production, but does work from my dev machine, both of which
are on the same domain, and both of which have the same permissions, is what
I am not getting.


Jul 19 '05 #1
16 1719
Oh, and make sure that both know the \\servername\ translation (try IP in
other words)

--
Curt Christianson
Owner/Lead Developer, DF-Software
www.Darkfalz.com
"middletree" <mi********@htomail.com> wrote in message
news:Ov**************@TK2MSFTNGP09.phx.gbl...
I asked this a few weeks ago, but still haven't gotten an answer. Really
stumped.

Intranet app, for tech support, and this app tracks the progress of tickets. Sometimes, the customer will send us some trace files or logs, so we have a folder called Tickets on a server on our network. If a ticket number is
1000, then the folder will be called T1000. So I have a link to that
directory that looks like this:

<% SET fso = CreateObject("Scripting.FileSystemObject")
strTraceDir = "\\servername\Tickets\T"&strTicketID
If fso.FolderExists(strTraceDir) then

Else
strTraceDir = "\\servername\Tickets\"
End if
set fso= nothing
%>

<a href="<%=strTraceDir%>" target="_blank">Files:</a>

As you can see, I cannot just assume that there is a folder with a specific number. Perhaps Ticket 1000 doesn't have a folder yet. If not, then I want
to allow the link to take you to just the root of that drive.

Here's the problem: On my dev machine, this code works fine. When I upload
it to production, the FolderExists part never, ever comes into play. In
other words, it always falls into the Else condition, every time. It's as if you can't see the folder from the server. But I have checked into that and
you can see it just fine. I also tried to see if the fact that it wasn't
mapped as a drive might be the problem, but I don't think that's it. I also checked to see that the IUSR account info is the same on both. IIS settings seem to be the same.

If my code just didn't work, I could deal with that. But the fact that it
doesn't work on production, but does work from my dev machine, both of which are on the same domain, and both of which have the same permissions, is what I am not getting.

Jul 19 '05 #2
You say they BOTH run under the same account? is it an IUSR account or a
standard account. As a test try setting both to run under an admin account,
this will eliminate the permissions as an issue.

--
Curt Christianson
Owner/Lead Developer, DF-Software
www.Darkfalz.com
"middletree" <mi********@htomail.com> wrote in message
news:Ov**************@TK2MSFTNGP09.phx.gbl...
I asked this a few weeks ago, but still haven't gotten an answer. Really
stumped.

Intranet app, for tech support, and this app tracks the progress of tickets. Sometimes, the customer will send us some trace files or logs, so we have a folder called Tickets on a server on our network. If a ticket number is
1000, then the folder will be called T1000. So I have a link to that
directory that looks like this:

<% SET fso = CreateObject("Scripting.FileSystemObject")
strTraceDir = "\\servername\Tickets\T"&strTicketID
If fso.FolderExists(strTraceDir) then

Else
strTraceDir = "\\servername\Tickets\"
End if
set fso= nothing
%>

<a href="<%=strTraceDir%>" target="_blank">Files:</a>

As you can see, I cannot just assume that there is a folder with a specific number. Perhaps Ticket 1000 doesn't have a folder yet. If not, then I want
to allow the link to take you to just the root of that drive.

Here's the problem: On my dev machine, this code works fine. When I upload
it to production, the FolderExists part never, ever comes into play. In
other words, it always falls into the Else condition, every time. It's as if you can't see the folder from the server. But I have checked into that and
you can see it just fine. I also tried to see if the fact that it wasn't
mapped as a drive might be the problem, but I don't think that's it. I also checked to see that the IUSR account info is the same on both. IIS settings seem to be the same.

If my code just didn't work, I could deal with that. But the fact that it
doesn't work on production, but does work from my dev machine, both of which are on the same domain, and both of which have the same permissions, is what I am not getting.

Jul 19 '05 #3
I should have mentioned that in my testing (I've been wrestling with this
for weeks now), I tried the IP address. I'll check the admin account, but
don't think I will be allowed to keep it there.

Keep in mind that although I said it seems like a permissions problem, it's
not necessarily. All I can say for sure is that it acts as if the folder
does not exist.

"Curt_C [MVP]" <software_AT_darkfalz.com> wrote in message
news:e#**************@TK2MSFTNGP12.phx.gbl...
Oh, and make sure that both know the \\servername\ translation (try IP in
other words)

--
Curt Christianson
Owner/Lead Developer, DF-Software
www.Darkfalz.com
"middletree" <mi********@htomail.com> wrote in message
news:Ov**************@TK2MSFTNGP09.phx.gbl...
I asked this a few weeks ago, but still haven't gotten an answer. Really
stumped.

Intranet app, for tech support, and this app tracks the progress of tickets.
Sometimes, the customer will send us some trace files or logs, so we have a
folder called Tickets on a server on our network. If a ticket number is
1000, then the folder will be called T1000. So I have a link to that
directory that looks like this:

<% SET fso = CreateObject("Scripting.FileSystemObject")
strTraceDir = "\\servername\Tickets\T"&strTicketID
If fso.FolderExists(strTraceDir) then

Else
strTraceDir = "\\servername\Tickets\"
End if
set fso= nothing
%>

<a href="<%=strTraceDir%>" target="_blank">Files:</a>

As you can see, I cannot just assume that there is a folder with a specific
number. Perhaps Ticket 1000 doesn't have a folder yet. If not, then I

want to allow the link to take you to just the root of that drive.

Here's the problem: On my dev machine, this code works fine. When I upload it to production, the FolderExists part never, ever comes into play. In
other words, it always falls into the Else condition, every time. It's as if
you can't see the folder from the server. But I have checked into that

and you can see it just fine. I also tried to see if the fact that it wasn't
mapped as a drive might be the problem, but I don't think that's it. I

also
checked to see that the IUSR account info is the same on both. IIS

settings
seem to be the same.

If my code just didn't work, I could deal with that. But the fact that it doesn't work on production, but does work from my dev machine, both of

which
are on the same domain, and both of which have the same permissions, is

what
I am not getting.


Jul 19 '05 #4
I should also add that I had someone else create a folder on the drive,
thinking perhaps it was giving me permissions to see only those folders I
created myself. But that theory was wrong, as well.
"Curt_C [MVP]" <software_AT_darkfalz.com> wrote in message
news:e#**************@TK2MSFTNGP12.phx.gbl...
Oh, and make sure that both know the \\servername\ translation (try IP in
other words)

--
Curt Christianson
Owner/Lead Developer, DF-Software
www.Darkfalz.com
"middletree" <mi********@htomail.com> wrote in message
news:Ov**************@TK2MSFTNGP09.phx.gbl...
I asked this a few weeks ago, but still haven't gotten an answer. Really
stumped.

Intranet app, for tech support, and this app tracks the progress of tickets.
Sometimes, the customer will send us some trace files or logs, so we have a
folder called Tickets on a server on our network. If a ticket number is
1000, then the folder will be called T1000. So I have a link to that
directory that looks like this:

<% SET fso = CreateObject("Scripting.FileSystemObject")
strTraceDir = "\\servername\Tickets\T"&strTicketID
If fso.FolderExists(strTraceDir) then

Else
strTraceDir = "\\servername\Tickets\"
End if
set fso= nothing
%>

<a href="<%=strTraceDir%>" target="_blank">Files:</a>

As you can see, I cannot just assume that there is a folder with a specific
number. Perhaps Ticket 1000 doesn't have a folder yet. If not, then I

want to allow the link to take you to just the root of that drive.

Here's the problem: On my dev machine, this code works fine. When I upload it to production, the FolderExists part never, ever comes into play. In
other words, it always falls into the Else condition, every time. It's as if
you can't see the folder from the server. But I have checked into that

and you can see it just fine. I also tried to see if the fact that it wasn't
mapped as a drive might be the problem, but I don't think that's it. I

also
checked to see that the IUSR account info is the same on both. IIS

settings
seem to be the same.

If my code just didn't work, I could deal with that. But the fact that it doesn't work on production, but does work from my dev machine, both of

which
are on the same domain, and both of which have the same permissions, is

what
I am not getting.


Jul 19 '05 #5
JJ
What happens if you do something like:

set wshell = CreateObject("WScript.Shell")
wshell.run "%COMSPEC% /C dir \\servername\Tickets >c:\dir.txt 2>&1", 0,
TRUE
set wshell = nothing

The file c:\dir.txt will either have the directory listing in it or an error
message that might help.

"middletree" <mi********@htomail.com> wrote in message
news:Ov**************@TK2MSFTNGP09.phx.gbl...
I asked this a few weeks ago, but still haven't gotten an answer. Really
stumped.

Intranet app, for tech support, and this app tracks the progress of tickets. Sometimes, the customer will send us some trace files or logs, so we have a folder called Tickets on a server on our network. If a ticket number is
1000, then the folder will be called T1000. So I have a link to that
directory that looks like this:

<% SET fso = CreateObject("Scripting.FileSystemObject")
strTraceDir = "\\servername\Tickets\T"&strTicketID
If fso.FolderExists(strTraceDir) then

Else
strTraceDir = "\\servername\Tickets\"
End if
set fso= nothing
%>

<a href="<%=strTraceDir%>" target="_blank">Files:</a>

As you can see, I cannot just assume that there is a folder with a specific number. Perhaps Ticket 1000 doesn't have a folder yet. If not, then I want
to allow the link to take you to just the root of that drive.

Here's the problem: On my dev machine, this code works fine. When I upload
it to production, the FolderExists part never, ever comes into play. In
other words, it always falls into the Else condition, every time. It's as if you can't see the folder from the server. But I have checked into that and
you can see it just fine. I also tried to see if the fact that it wasn't
mapped as a drive might be the problem, but I don't think that's it. I also checked to see that the IUSR account info is the same on both. IIS settings seem to be the same.

If my code just didn't work, I could deal with that. But the fact that it
doesn't work on production, but does work from my dev machine, both of which are on the same domain, and both of which have the same permissions, is what I am not getting.

Jul 19 '05 #6
Well, I could try this for debugging, but I don't think I could normally get
into the root of the C drive on that server. We're mapped to the shared
folder itself.
"JJ" <jj**@nospam.com> wrote in message
news:er**************@TK2MSFTNGP11.phx.gbl...
What happens if you do something like:

set wshell = CreateObject("WScript.Shell")
wshell.run "%COMSPEC% /C dir \\servername\Tickets >c:\dir.txt 2>&1", 0, TRUE
set wshell = nothing

The file c:\dir.txt will either have the directory listing in it or an error message that might help.

"middletree" <mi********@htomail.com> wrote in message
news:Ov**************@TK2MSFTNGP09.phx.gbl...
I asked this a few weeks ago, but still haven't gotten an answer. Really
stumped.

Intranet app, for tech support, and this app tracks the progress of tickets.
Sometimes, the customer will send us some trace files or logs, so we have a
folder called Tickets on a server on our network. If a ticket number is
1000, then the folder will be called T1000. So I have a link to that
directory that looks like this:

<% SET fso = CreateObject("Scripting.FileSystemObject")
strTraceDir = "\\servername\Tickets\T"&strTicketID
If fso.FolderExists(strTraceDir) then

Else
strTraceDir = "\\servername\Tickets\"
End if
set fso= nothing
%>

<a href="<%=strTraceDir%>" target="_blank">Files:</a>

As you can see, I cannot just assume that there is a folder with a specific
number. Perhaps Ticket 1000 doesn't have a folder yet. If not, then I

want to allow the link to take you to just the root of that drive.

Here's the problem: On my dev machine, this code works fine. When I upload it to production, the FolderExists part never, ever comes into play. In
other words, it always falls into the Else condition, every time. It's as if
you can't see the folder from the server. But I have checked into that

and you can see it just fine. I also tried to see if the fact that it wasn't
mapped as a drive might be the problem, but I don't think that's it. I

also
checked to see that the IUSR account info is the same on both. IIS

settings
seem to be the same.

If my code just didn't work, I could deal with that. But the fact that it doesn't work on production, but does work from my dev machine, both of

which
are on the same domain, and both of which have the same permissions, is

what
I am not getting.


Jul 19 '05 #7
What exactly do you get when you Response.Write strTraceDir ?

Might you need a space somewhere in "\\servername\Tickets\T"&strTicketID ?

"middletree" <mi********@htomail.com> wrote in message
news:Ov**************@TK2MSFTNGP09.phx.gbl...
I asked this a few weeks ago, but still haven't gotten an answer. Really
stumped.

Intranet app, for tech support, and this app tracks the progress of tickets. Sometimes, the customer will send us some trace files or logs, so we have a folder called Tickets on a server on our network. If a ticket number is
1000, then the folder will be called T1000. So I have a link to that
directory that looks like this:

<% SET fso = CreateObject("Scripting.FileSystemObject")
strTraceDir = "\\servername\Tickets\T"&strTicketID
If fso.FolderExists(strTraceDir) then

Else
strTraceDir = "\\servername\Tickets\"
End if
set fso= nothing
%>

<a href="<%=strTraceDir%>" target="_blank">Files:</a>

As you can see, I cannot just assume that there is a folder with a specific number. Perhaps Ticket 1000 doesn't have a folder yet. If not, then I want
to allow the link to take you to just the root of that drive.

Here's the problem: On my dev machine, this code works fine. When I upload
it to production, the FolderExists part never, ever comes into play. In
other words, it always falls into the Else condition, every time. It's as if you can't see the folder from the server. But I have checked into that and
you can see it just fine. I also tried to see if the fact that it wasn't
mapped as a drive might be the problem, but I don't think that's it. I also checked to see that the IUSR account info is the same on both. IIS settings seem to be the same.

If my code just didn't work, I could deal with that. But the fact that it
doesn't work on production, but does work from my dev machine, both of which are on the same domain, and both of which have the same permissions, is what I am not getting.

Jul 19 '05 #8
Definitly DONT keep it there...just put it there for one quick test.
It will tell you if it's permissions or not then and where to look for the
fix

--
Curt Christianson
Owner/Lead Developer, DF-Software
www.Darkfalz.com
"middletree" <mi********@htomail.com> wrote in message
news:%2****************@TK2MSFTNGP11.phx.gbl...
I should have mentioned that in my testing (I've been wrestling with this
for weeks now), I tried the IP address. I'll check the admin account, but
don't think I will be allowed to keep it there.

Keep in mind that although I said it seems like a permissions problem, it's not necessarily. All I can say for sure is that it acts as if the folder
does not exist.

"Curt_C [MVP]" <software_AT_darkfalz.com> wrote in message
news:e#**************@TK2MSFTNGP12.phx.gbl...
Oh, and make sure that both know the \\servername\ translation (try IP in
other words)

--
Curt Christianson
Owner/Lead Developer, DF-Software
www.Darkfalz.com
"middletree" <mi********@htomail.com> wrote in message
news:Ov**************@TK2MSFTNGP09.phx.gbl...
I asked this a few weeks ago, but still haven't gotten an answer. Really stumped.

Intranet app, for tech support, and this app tracks the progress of

tickets.
Sometimes, the customer will send us some trace files or logs, so we have
a
folder called Tickets on a server on our network. If a ticket number is 1000, then the folder will be called T1000. So I have a link to that
directory that looks like this:

<% SET fso = CreateObject("Scripting.FileSystemObject")
strTraceDir = "\\servername\Tickets\T"&strTicketID
If fso.FolderExists(strTraceDir) then

Else
strTraceDir = "\\servername\Tickets\"
End if
set fso= nothing
%>

<a href="<%=strTraceDir%>" target="_blank">Files:</a>

As you can see, I cannot just assume that there is a folder with a

specific
number. Perhaps Ticket 1000 doesn't have a folder yet. If not, then I

want to allow the link to take you to just the root of that drive.

Here's the problem: On my dev machine, this code works fine. When I upload it to production, the FolderExists part never, ever comes into play. In other words, it always falls into the Else condition, every time. It's as
if
you can't see the folder from the server. But I have checked into that

and you can see it just fine. I also tried to see if the fact that it wasn't mapped as a drive might be the problem, but I don't think that's it. I

also
checked to see that the IUSR account info is the same on both. IIS

settings
seem to be the same.

If my code just didn't work, I could deal with that. But the fact that it doesn't work on production, but does work from my dev machine, both of

which
are on the same domain, and both of which have the same permissions,

is what
I am not getting.



Jul 19 '05 #9

"JJ" <jj**@nospam.com> wrote in message
news:er**************@TK2MSFTNGP11.phx.gbl...
What happens if you do something like:

set wshell = CreateObject("WScript.Shell")
wshell.run "%COMSPEC% /C dir \\servername\Tickets >c:\dir.txt 2>&1", 0, TRUE
set wshell = nothing

The file c:\dir.txt will either have the directory listing in it or an error message that might help.

I just went to our systems admin, got special permission to look at the C
drive of that server, and there was no such file as dir.txt
Jul 19 '05 #10

"Mike Florio" <mi**@micro-point.com> wrote in message
news:10*************@corp.supernews.com...
What exactly do you get when you Response.Write strTraceDir ?
\\servername\Tickets\T11026, on my dev machine99which is not giving me
problems; And yes, in this case, 11026 is the correct number

I did not do the response.write for production, which is where I am getting
problems. I could not do that while people are using it, maybe after hours.
But I don't think I'll see anything new, because the word "Files" has a
hyperlink to that path, and I can see when I mouseover "Files", in the
status bar, and I can see when I click "Files", it brings up an Explorer
window. So I am quite sure that it is giving me \\servername\Tickets\, when
I would rather have \\servername\Tickets\T11026


Might you need a space somewhere in "\\servername\Tickets\T"&strTicketID ?


No, can't see where that would be appropriate.
Jul 19 '05 #11
I assume this is on an intranet (not the S.H.A.P.E. thing) as it would be
pointless on the internet.
I further assume that the intranet server is a member of the domain.

If this assumptions are correct, than you would be just as well off to run
the application under Windows Authentication instead of Anonymous.

Then, each request to check for the existence of \\servername\Tickets\TXXXXX
would run under the end user's context.
This is similar to the "Can I connect to an Access database on a different
server" problem.

http://www.aspfaq.com/show.asp?id=2168
under If the file is within your LAN
"middletree" <mi********@htomail.com> wrote in message
news:Ov**************@TK2MSFTNGP09.phx.gbl...
I asked this a few weeks ago, but still haven't gotten an answer. Really
stumped.

Intranet app, for tech support, and this app tracks the progress of tickets. Sometimes, the customer will send us some trace files or logs, so we have a folder called Tickets on a server on our network. If a ticket number is
1000, then the folder will be called T1000. So I have a link to that
directory that looks like this:

<% SET fso = CreateObject("Scripting.FileSystemObject")
strTraceDir = "\\servername\Tickets\T"&strTicketID
If fso.FolderExists(strTraceDir) then

Else
strTraceDir = "\\servername\Tickets\"
End if
set fso= nothing
%>

<a href="<%=strTraceDir%>" target="_blank">Files:</a>

As you can see, I cannot just assume that there is a folder with a specific number. Perhaps Ticket 1000 doesn't have a folder yet. If not, then I want
to allow the link to take you to just the root of that drive.

Here's the problem: On my dev machine, this code works fine. When I upload
it to production, the FolderExists part never, ever comes into play. In
other words, it always falls into the Else condition, every time. It's as if you can't see the folder from the server. But I have checked into that and
you can see it just fine. I also tried to see if the fact that it wasn't
mapped as a drive might be the problem, but I don't think that's it. I also checked to see that the IUSR account info is the same on both. IIS settings seem to be the same.

If my code just didn't work, I could deal with that. But the fact that it
doesn't work on production, but does work from my dev machine, both of which are on the same domain, and both of which have the same permissions, is what I am not getting.

Jul 19 '05 #12
Your first assumptions are correct. This project is part of my job. SHAPE is
something I am doing at home for church.
The Intranet server is on the same domain as all users who would use this
app.

You lost me when you said to run it under Window Authentication. Is this a
setting on IIS? I know of a setting with a similar name, for SQL Server, but
that wouldn't apply to this problem.

Oh, wait, I read the article. Are you talking about going into IIS and
checking the Windows authentication checkbox? I checked that a few weeks
ago, when this problem first started. It's already checked.


"TomB" <sh*****@hotmailXXX.com> wrote in message
news:eC**************@tk2msftngp13.phx.gbl...
I assume this is on an intranet (not the S.H.A.P.E. thing) as it would be
pointless on the internet.
I further assume that the intranet server is a member of the domain.

If this assumptions are correct, than you would be just as well off to run
the application under Windows Authentication instead of Anonymous.

Then, each request to check for the existence of \\servername\Tickets\TXXXXX would run under the end user's context.
This is similar to the "Can I connect to an Access database on a different
server" problem.

http://www.aspfaq.com/show.asp?id=2168
under If the file is within your LAN
"middletree" <mi********@htomail.com> wrote in message
news:Ov**************@TK2MSFTNGP09.phx.gbl...
I asked this a few weeks ago, but still haven't gotten an answer. Really
stumped.

Intranet app, for tech support, and this app tracks the progress of tickets.
Sometimes, the customer will send us some trace files or logs, so we have a
folder called Tickets on a server on our network. If a ticket number is
1000, then the folder will be called T1000. So I have a link to that
directory that looks like this:

<% SET fso = CreateObject("Scripting.FileSystemObject")
strTraceDir = "\\servername\Tickets\T"&strTicketID
If fso.FolderExists(strTraceDir) then

Else
strTraceDir = "\\servername\Tickets\"
End if
set fso= nothing
%>

<a href="<%=strTraceDir%>" target="_blank">Files:</a>

As you can see, I cannot just assume that there is a folder with a specific
number. Perhaps Ticket 1000 doesn't have a folder yet. If not, then I

want to allow the link to take you to just the root of that drive.

Here's the problem: On my dev machine, this code works fine. When I upload it to production, the FolderExists part never, ever comes into play. In
other words, it always falls into the Else condition, every time. It's as if
you can't see the folder from the server. But I have checked into that

and you can see it just fine. I also tried to see if the fact that it wasn't
mapped as a drive might be the problem, but I don't think that's it. I

also
checked to see that the IUSR account info is the same on both. IIS

settings
seem to be the same.

If my code just didn't work, I could deal with that. But the fact that it doesn't work on production, but does work from my dev machine, both of

which
are on the same domain, and both of which have the same permissions, is

what
I am not getting.


Jul 19 '05 #13
middletree wrote:
Your first assumptions are correct. This project is part of my job.
SHAPE is something I am doing at home for church.
The Intranet server is on the same domain as all users who would use
this app.

You lost me when you said to run it under Window Authentication. Is
this a setting on IIS? I know of a setting with a similar name, for
SQL Server, but that wouldn't apply to this problem.

Oh, wait, I read the article. Are you talking about going into IIS and
checking the Windows authentication checkbox?
Right
I checked that a few
weeks ago, when this problem first started. It's already checked.


And Anonymous is unchecked?

Bob Barrows

--
Microsoft MVP -- ASP/ASP.NET
Please reply to the newsgroup. The email account listed in my From
header is my spam trap, so I don't check it very often. You will get a
quicker response by posting to the newsgroup.
Jul 19 '05 #14
JJ
You don't have to put it in c:\ - you can put the file anywhere. I just
used c:\dir.txt as an example. But I would use the local hard drive of the
web server, not a network share.

When I do those commands from an ASP script (assuming WSH is installed), I
get either a directory listing in the file or I get the error message from
dir, which sometimes helps determine the problem.

"middletree" <mi********@htomail.com> wrote in message
news:u6**************@TK2MSFTNGP11.phx.gbl...
Well, I could try this for debugging, but I don't think I could normally get into the root of the C drive on that server. We're mapped to the shared
folder itself.
"JJ" <jj**@nospam.com> wrote in message
news:er**************@TK2MSFTNGP11.phx.gbl...
What happens if you do something like:

set wshell = CreateObject("WScript.Shell")
wshell.run "%COMSPEC% /C dir \\servername\Tickets >c:\dir.txt 2>&1",

0,
TRUE
set wshell = nothing

The file c:\dir.txt will either have the directory listing in it or an

error
message that might help.

"middletree" <mi********@htomail.com> wrote in message
news:Ov**************@TK2MSFTNGP09.phx.gbl...
I asked this a few weeks ago, but still haven't gotten an answer. Really stumped.

Intranet app, for tech support, and this app tracks the progress of

tickets.
Sometimes, the customer will send us some trace files or logs, so we have
a
folder called Tickets on a server on our network. If a ticket number is 1000, then the folder will be called T1000. So I have a link to that
directory that looks like this:

<% SET fso = CreateObject("Scripting.FileSystemObject")
strTraceDir = "\\servername\Tickets\T"&strTicketID
If fso.FolderExists(strTraceDir) then

Else
strTraceDir = "\\servername\Tickets\"
End if
set fso= nothing
%>

<a href="<%=strTraceDir%>" target="_blank">Files:</a>

As you can see, I cannot just assume that there is a folder with a

specific
number. Perhaps Ticket 1000 doesn't have a folder yet. If not, then I want to allow the link to take you to just the root of that drive.

Here's the problem: On my dev machine, this code works fine. When I upload it to production, the FolderExists part never, ever comes into play. In other words, it always falls into the Else condition, every time. It's as
if
you can't see the folder from the server. But I have checked into that

and you can see it just fine. I also tried to see if the fact that it wasn't mapped as a drive might be the problem, but I don't think that's it. I

also
checked to see that the IUSR account info is the same on both. IIS

settings
seem to be the same.

If my code just didn't work, I could deal with that. But the fact that it doesn't work on production, but does work from my dev machine, both of

which
are on the same domain, and both of which have the same permissions,

is what
I am not getting.



Jul 19 '05 #15
Ok, I totally misunderstood what you are saying, then. I guess I can try and
run it, and see what happens. I'll do it on my dev server first, though.
"JJ" <jj**@nospam.com> wrote in message
news:eJ**************@TK2MSFTNGP10.phx.gbl...
You don't have to put it in c:\ - you can put the file anywhere. I just
used c:\dir.txt as an example. But I would use the local hard drive of the web server, not a network share.

When I do those commands from an ASP script (assuming WSH is installed), I
get either a directory listing in the file or I get the error message from
dir, which sometimes helps determine the problem.

"middletree" <mi********@htomail.com> wrote in message
news:u6**************@TK2MSFTNGP11.phx.gbl...
Well, I could try this for debugging, but I don't think I could normally

get
into the root of the C drive on that server. We're mapped to the shared
folder itself.
"JJ" <jj**@nospam.com> wrote in message
news:er**************@TK2MSFTNGP11.phx.gbl...
What happens if you do something like:

set wshell = CreateObject("WScript.Shell")
wshell.run "%COMSPEC% /C dir \\servername\Tickets >c:\dir.txt 2>&1",
0,
TRUE
set wshell = nothing

The file c:\dir.txt will either have the directory listing in it or an

error
message that might help.

"middletree" <mi********@htomail.com> wrote in message
news:Ov**************@TK2MSFTNGP09.phx.gbl...
> I asked this a few weeks ago, but still haven't gotten an answer. Really > stumped.
>
> Intranet app, for tech support, and this app tracks the progress of
tickets.
> Sometimes, the customer will send us some trace files or logs, so we

have
a
> folder called Tickets on a server on our network. If a ticket number is > 1000, then the folder will be called T1000. So I have a link to that
> directory that looks like this:
>
> <% SET fso = CreateObject("Scripting.FileSystemObject")
> strTraceDir = "\\servername\Tickets\T"&strTicketID
> If fso.FolderExists(strTraceDir) then
>
> Else
> strTraceDir = "\\servername\Tickets\"
> End if
> set fso= nothing
> %>
>
> <a href="<%=strTraceDir%>" target="_blank">Files:</a>
>
> As you can see, I cannot just assume that there is a folder with a
specific
> number. Perhaps Ticket 1000 doesn't have a folder yet. If not, then
I
want
> to allow the link to take you to just the root of that drive.
>
> Here's the problem: On my dev machine, this code works fine. When I

upload
> it to production, the FolderExists part never, ever comes into play. In > other words, it always falls into the Else condition, every time.
It's as
if
> you can't see the folder from the server. But I have checked into
that and
> you can see it just fine. I also tried to see if the fact that it wasn't > mapped as a drive might be the problem, but I don't think that's it.
I also
> checked to see that the IUSR account info is the same on both. IIS
settings
> seem to be the same.
>
> If my code just didn't work, I could deal with that. But the fact that it
> doesn't work on production, but does work from my dev machine, both

of which
> are on the same domain, and both of which have the same permissions,

is what
> I am not getting.
>
>
>
>



Jul 19 '05 #16
Oh, I forgot if you use Windows Authentication it can't pass the credentials
there are only two ways of making this work

1) Use Basic Authentication. You probably don't want to as your users will
have to login.
2) Run under Anonymous but under a domain account, rather than IUSR_

"middletree" <mi********@htomail.com> wrote in message
news:O0**************@TK2MSFTNGP11.phx.gbl...
Your first assumptions are correct. This project is part of my job. SHAPE is something I am doing at home for church.
The Intranet server is on the same domain as all users who would use this
app.

You lost me when you said to run it under Window Authentication. Is this a
setting on IIS? I know of a setting with a similar name, for SQL Server, but that wouldn't apply to this problem.

Oh, wait, I read the article. Are you talking about going into IIS and
checking the Windows authentication checkbox? I checked that a few weeks
ago, when this problem first started. It's already checked.


"TomB" <sh*****@hotmailXXX.com> wrote in message
news:eC**************@tk2msftngp13.phx.gbl...
I assume this is on an intranet (not the S.H.A.P.E. thing) as it would be
pointless on the internet.
I further assume that the intranet server is a member of the domain.

If this assumptions are correct, than you would be just as well off to run the application under Windows Authentication instead of Anonymous.

Then, each request to check for the existence of

\\servername\Tickets\TXXXXX
would run under the end user's context.
This is similar to the "Can I connect to an Access database on a different server" problem.

http://www.aspfaq.com/show.asp?id=2168
under If the file is within your LAN
"middletree" <mi********@htomail.com> wrote in message
news:Ov**************@TK2MSFTNGP09.phx.gbl...
I asked this a few weeks ago, but still haven't gotten an answer. Really stumped.

Intranet app, for tech support, and this app tracks the progress of

tickets.
Sometimes, the customer will send us some trace files or logs, so we have
a
folder called Tickets on a server on our network. If a ticket number is 1000, then the folder will be called T1000. So I have a link to that
directory that looks like this:

<% SET fso = CreateObject("Scripting.FileSystemObject")
strTraceDir = "\\servername\Tickets\T"&strTicketID
If fso.FolderExists(strTraceDir) then

Else
strTraceDir = "\\servername\Tickets\"
End if
set fso= nothing
%>

<a href="<%=strTraceDir%>" target="_blank">Files:</a>

As you can see, I cannot just assume that there is a folder with a

specific
number. Perhaps Ticket 1000 doesn't have a folder yet. If not, then I

want to allow the link to take you to just the root of that drive.

Here's the problem: On my dev machine, this code works fine. When I upload it to production, the FolderExists part never, ever comes into play. In other words, it always falls into the Else condition, every time. It's as
if
you can't see the folder from the server. But I have checked into that

and you can see it just fine. I also tried to see if the fact that it wasn't mapped as a drive might be the problem, but I don't think that's it. I

also
checked to see that the IUSR account info is the same on both. IIS

settings
seem to be the same.

If my code just didn't work, I could deal with that. But the fact that it doesn't work on production, but does work from my dev machine, both of

which
are on the same domain, and both of which have the same permissions,

is what
I am not getting.



Jul 19 '05 #17

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

11
by: Kostatus | last post by:
I have a virtual function in a base class, which is then overwritten by a function of the same name in a publically derived class. When I call the function using a pointer to the derived class...
117
by: Peter Olcott | last post by:
www.halting-problem.com
18
by: Ian Stanley | last post by:
Hi, Continuing my strcat segmentation fault posting- I have a problem which occurs when appending two sting literals using strcat. I have tried to fix it by writing my own function that does the...
28
by: Jon Davis | last post by:
If I have a class with a virtual method, and a child class that overrides the virtual method, and then I create an instance of the child class AS A base class... BaseClass bc = new ChildClass();...
6
by: Ammar | last post by:
Dear All, I'm facing a small problem. I have a portal web site, that contains articles, for each article, the end user can send a comment about the article. The problem is: I the comment length...
16
by: Dany | last post by:
Our web service was working fine until we installed .net Framework 1.1 service pack 1. Uninstalling SP1 is not an option because our largest customer says service packs marked as "critical" by...
2
by: Mike Collins | last post by:
I cannot get the correct drop down list value from a drop down I have on my web form. I get the initial value that was loaded in the list. It was asked by someone else what the autopostback was...
0
by: =?Utf-8?B?am8uZWw=?= | last post by:
Hello All, I am developing an Input Methop (IM) for PocketPC / Windows Mobile (PPC/WM). On some devices the IM will not start. The IM appears in the IM-List but when it is selected from the...
1
by: sherifbk | last post by:
Problem description ============== - I have 4 clients and 1 server (SQL server) - 3 clients are Monitoring console 1 client is operation console - Monitoring console collects some data from...
9
by: AceKnocks | last post by:
I am working on a framework design problem in which I have to design a C++ based framework capable of solving three puzzles for now but actually it should work with a general puzzle of any kind and I...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.