473,325 Members | 2,872 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,325 software developers and data experts.

How to write something to txt on server

Hi.

I want to write some text ("bla bla") to a file something.txt. That file is
accessible on http://192.168.0.1/dir/something.txt (I'm on LAN side).
I can read from that file. Web server is on IIS, I set to allow everyone
NTFS full control premission, and on IIS server I set allow read and write.

I found some ideas in library
http://msdn.microsoft.com/library/en...nginternet.asp
an
http://msdn.microsoft.com/library/en...ClassTopic.asp
an
http://msdn.microsoft.com/library/en...ClassTopic.asp

But I still cant write some sample code to write data in that file. Can
someone help me with some simple sample?
Tnx
by Miha
Nov 16 '05 #1
1 1293
From what I understand you want to write to a network server from an
application running under IIS. Correct?

The user that ASP.NET normally runs under, only exists locally, the remote
server has no knowledge of it, hence NTFS will deny it. The way I have used
to accomplish the same task is to select "Basic Authentication" on IIS, in
addition to impersonation.This will prompt for a username and password, be
aware that the password will be sent in clear text over the network, it
might not be a problem if it will only be used over LAN. This method is the
only way I could find to make IIS act on the behalf of the user, it wont be
IIS, but the user that actually writes the file.
"Windows Authentication" will not allow IIS to act on the behalf of the
user.

Hope this helped.

Chris
"Miha" <Mi**@discussions.microsoft.com> wrote in message
news:BA**********************************@microsof t.com...
Hi.

I want to write some text ("bla bla") to a file something.txt. That file
is
accessible on http://192.168.0.1/dir/something.txt (I'm on LAN side).
I can read from that file. Web server is on IIS, I set to allow everyone
NTFS full control premission, and on IIS server I set allow read and
write.

I found some ideas in library:
http://msdn.microsoft.com/library/en...nginternet.asp
and
http://msdn.microsoft.com/library/en...ClassTopic.asp
and
http://msdn.microsoft.com/library/en...ClassTopic.asp

But I still cant write some sample code to write data in that file. Can
someone help me with some simple sample?
Tnx
by Miha

Nov 16 '05 #2

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

Similar topics

2
by: Jon Maz | last post by:
Hi, I have written a page to test a function of mine that strips non-English accents and various other characters out of a given string. The function itself (called 'StripAll' in the code below)...
2
by: TJ | last post by:
Dear Sir/Madam I have made one user control to embed in Internet Explorer I just wrote one method to keep track log something like. public static void WriteLog(..) StreamWriter stWriter =...
11
by: Russ | last post by:
My web app writes some binary data to a file at the client site via Response.Write and Response.BinaryWrite. This action is accomplished in response to a button click, with C# code behind as...
11
by: Michael Powe | last post by:
How can I make an XHTML-compliant form of an expression in this format: document.write("<scr"+"ipt type='text/javascript' src='path/to/file.js'>"+"</scr"+"ipt>"); this turns out to be a...
4
by: cbtechlists | last post by:
I have an ASP app that we've moved from a Windows 2000 to a Windows 2003 server (sql server 2000 to sql server 2005). The job runs fine on the old servers. Part of the app takes a recordset and...
20
by: _mario.lat | last post by:
hallo, I use PHP and I'd like to not write in hardcoded way password and login to access to mysql. how to not write password in code for access to mysql? How can I do? I'd like that who see my...
10
by: cjard | last post by:
I have a client and server that enjoy the following simple dialogue: Client connects Client sends request Server sends response Client disconnects This is the way it must be. The response...
3
by: madsornomads | last post by:
Hi all, I have a problem with reading from a Java server after I have written to it - it just hangs. It works fine if I just write to the server and not try to write. I have read the HOWTO on...
1
by: pauld | last post by:
Hello - I have created a simple web application in VS 2005/ASP.net 2.0 for a university department to track problems with a new website that I have built for them. The app consists of an Access...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
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...
1
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...

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.