Quantcast
Channel: SCN : All Content - All Communities
Viewing all articles
Browse latest Browse all 3184

Can't Open txt file on the web server -PB 11.2

$
0
0

Hi there,

 

I am using PB11.2 and deploy to .net web form. I have one button on the web form.What I want is press this button and open one txt file and replace some words into it which exist on my local drive c:\temp\abc.txt. Here is the code:

string ls_file

integer li_dest_filenum

 

ls_file = 'C:\temp\abc.txt'

li_dest_filenum = Fileopen(ls_file,StreamMode!,Write!,Shared!,Replace!);

 

FileWrite(li_dest_filenum,'@echo off');

FileWrite(li_dest_filenum,'C:');

FileClose(li_dest_filenum);

 

When deploy to the web and run this application.There is no respond when I press the button.

So I put the messagebox to see return code from li_dest_filenum. I got -1 which means open error.

I am not sure if this issue or something wrong with my code. I already give full control for everyone to C:\temp.

Any ideas? Thanks in Advance.


Viewing all articles
Browse latest Browse all 3184

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>