- Als neu kennzeichnen
- Lesezeichen
- Abonnieren
- Stummschalten
- RSS-Feed abonnieren
- Kennzeichnen
- Anstößigen Inhalt melden
Hello:
I have created the following simple test program:
program
Test open(10, name='temp1', status='old', err=1) stop1 open(10, name='temp1', status='replace')end
It works fine (i.e. it doesn't crash) when I run it from my local machine. But when I copy the solution and project to a server directory (to which I havefull write permission), and run it from the server, it crashes at line 1 saying that it can't open the file. I noticed, though, that if I change the file names to "D: emp1" (so that it's trying to open the file on my local machine), then it runs, even from the server.
This seems strange to me. What am I missing? Is it perhaps a compiler bug?
Thanks.
Michael
Link kopiert
- Als neu kennzeichnen
- Lesezeichen
- Abonnieren
- Stummschalten
- RSS-Feed abonnieren
- Kennzeichnen
- Anstößigen Inhalt melden
- Als neu kennzeichnen
- Lesezeichen
- Abonnieren
- Stummschalten
- RSS-Feed abonnieren
- Kennzeichnen
- Anstößigen Inhalt melden
I have attached a screen shot of the error message showing that it crashed when trying to open the file.
By running from the server I mean that I copied the entire solution folder (and contents) to a server on our network and rebuilt the solution. (The rebuilding was probably unnecessary.) I then ran it from that solution on the server using "Start without debugging". Practically, I think the only difference between running it on the server and runnning it on my machine is the working directory of the program when it executes.
I can attach a zip file of my solution if that would help.
Thanks.
Michael
- Als neu kennzeichnen
- Lesezeichen
- Abonnieren
- Stummschalten
- RSS-Feed abonnieren
- Kennzeichnen
- Anstößigen Inhalt melden
'servernameF$SharedConsole55'
CMD.EXE was started with the above path as the current directory.
UNC paths are not supported. Defaulting to Windows directory.
I expect you're seeing much the same. When you run a program from within Visual Studio, it sets the default directory to the project directory. Windows does not support UNC paths for this. Instead, mount the share as a device letter and use it that way.
- Als neu kennzeichnen
- Lesezeichen
- Abonnieren
- Stummschalten
- RSS-Feed abonnieren
- Kennzeichnen
- Anstößigen Inhalt melden
No, I do not see that message. The screenshot that I posted is exactly what I get.
I tried mapping a drive and running it from the command line using the mapped drive, but got the exact same results. I've attached another screen shot of the error usingthe mapped drive.
Thanks
Michael
- Als neu kennzeichnen
- Lesezeichen
- Abonnieren
- Stummschalten
- RSS-Feed abonnieren
- Kennzeichnen
- Anstößigen Inhalt melden
- Als neu kennzeichnen
- Lesezeichen
- Abonnieren
- Stummschalten
- RSS-Feed abonnieren
- Kennzeichnen
- Anstößigen Inhalt melden
Sorry about picking the same name for the file as for the executable. That was just due to my lack of imagination. But I just tried changing the name of the file and it made no difference: it still runs fine on my local D: drive, but crashes when I run it on a server across the network.
I'm running IVF 10.1.021. Is that the version you tried it with? (If not, can you try it with that version?)
Note that if you ran it on a local drive and it worked (as it should have), and then copied the entire solution folder to a server, it still would likely work. This is because it you copied the entire folder, you probably also copied the file "temp" that was created when you ran it on your local drive. So when you ran it on the server, it saw that "temp" existed and completed running sucessfully. Perhaps you could try deleting "temp" from you the server folder and thenrunning it again.
Thanks.
Michael
- Als neu kennzeichnen
- Lesezeichen
- Abonnieren
- Stummschalten
- RSS-Feed abonnieren
- Kennzeichnen
- Anstößigen Inhalt melden
- Als neu kennzeichnen
- Lesezeichen
- Abonnieren
- Stummschalten
- RSS-Feed abonnieren
- Kennzeichnen
- Anstößigen Inhalt melden
- Als neu kennzeichnen
- Lesezeichen
- Abonnieren
- Stummschalten
- RSS-Feed abonnieren
- Kennzeichnen
- Anstößigen Inhalt melden
- Als neu kennzeichnen
- Lesezeichen
- Abonnieren
- Stummschalten
- RSS-Feed abonnieren
- Kennzeichnen
- Anstößigen Inhalt melden
Thanks for tryng this.
I just upgraded to 10.1.024. As you guessed, it made no difference: the program still crashed when I ran it over the network.
I dofind it curious though, that when I run it over the network, it makes no difference for me if I use a mapped drive or not. I don't get that message you refferred to earlier about Windows not being able to start with a UNC path. (I've seenthat messagea bunch of times relating to other things whenI've tried to start a command prompt over the network, but not with this little test program.)
If you have any other suggestions about what could be causing this -- I'd love to hear them!
As always, thanks.
Michael
- Als neu kennzeichnen
- Lesezeichen
- Abonnieren
- Stummschalten
- RSS-Feed abonnieren
- Kennzeichnen
- Anstößigen Inhalt melden
- Als neu kennzeichnen
- Lesezeichen
- Abonnieren
- Stummschalten
- RSS-Feed abonnieren
- Kennzeichnen
- Anstößigen Inhalt melden
- Als neu kennzeichnen
- Lesezeichen
- Abonnieren
- Stummschalten
- RSS-Feed abonnieren
- Kennzeichnen
- Anstößigen Inhalt melden
- Als neu kennzeichnen
- Lesezeichen
- Abonnieren
- Stummschalten
- RSS-Feed abonnieren
- Kennzeichnen
- Anstößigen Inhalt melden
Everything seems to work "normally" when I do the steps independently.
Leaving off the "err =" in the first open statement causes the program to crash immediately (as would be expected) since the file "temp" does not exist. Just using the second open statement by itself works fine (i.e., no crash), also as would be expected. My permission on that drive of the directory on the server is set to "Full Control".
When I mapped a drive to the "adminstrative share" version of that directory on the server, I got the same crashwhen the program reachedthe second open statement.
Thanks.
Michael
- Als neu kennzeichnen
- Lesezeichen
- Abonnieren
- Stummschalten
- RSS-Feed abonnieren
- Kennzeichnen
- Anstößigen Inhalt melden
program Test
use ifport
open(10, name='temp1', status='old', err=1)
stop
1 call sleepqq(1000)
open(10, name='temp1', status='replace')
end
- Als neu kennzeichnen
- Lesezeichen
- Abonnieren
- Stummschalten
- RSS-Feed abonnieren
- Kennzeichnen
- Anstößigen Inhalt melden
Same result (i.e., it crashed), but after a delay of 1 second. I tried bumping it up to 5000 to have it delay for 5 seconds, but this did not help either.
Thanks.
Michael
- Als neu kennzeichnen
- Lesezeichen
- Abonnieren
- Stummschalten
- RSS-Feed abonnieren
- Kennzeichnen
- Anstößigen Inhalt melden
It would be interesting to see if other readers can replicate this.
- Als neu kennzeichnen
- Lesezeichen
- Abonnieren
- Stummschalten
- RSS-Feed abonnieren
- Kennzeichnen
- Anstößigen Inhalt melden
Well, thanks for taking your time to share your ideas up till now. I've also run out of ideas, so I was hoping to get some brainstorming ideas from here!
Yes, the second open statement by itself works fine. It's only when the first one fails that the second one also fails. A co-worker in my office reproduces the exact same results as me when using the zip file attached to my earlier post. It runs on his local machine but not on the server.
If any other forum users could give this a try and report their results, that would be great...
Thanks.
Michael
- Als neu kennzeichnen
- Lesezeichen
- Abonnieren
- Stummschalten
- RSS-Feed abonnieren
- Kennzeichnen
- Anstößigen Inhalt melden
Still grasping at straws here...
Steve, your earlier post mentoined that you had done your tests on an XP server. Even though our regular servers here run Windows Server 2003, I tried a test where I shared out a drive on my XP machine and had a co-worker use run the program over that shared drive. Sure enough, it worked for him, even though it didn't work when he ran it on a Windows 2003 server.
So it looks like the server type may make a difference. Is there any way you could try and run the program over the network on a Windows 2003 Server machine to see if you can get it to crash?
Thanks.
Michael
- Als neu kennzeichnen
- Lesezeichen
- Abonnieren
- Stummschalten
- RSS-Feed abonnieren
- Kennzeichnen
- Anstößigen Inhalt melden
What happens if you open a command prompt window, set default to the mapped drive and run the program?
You may have a permissions problem on the share.

- RSS-Feed abonnieren
- Thema als neu kennzeichnen
- Thema als gelesen kennzeichnen
- Diesen Thema für aktuellen Benutzer floaten
- Lesezeichen
- Abonnieren
- Drucker-Anzeigeseite