Want to protect your cyber security and still get fast solutions? Ask a secure question today.Go Premium


Reload of new page (RTF) gives old version

Posted on 2005-03-31
Medium Priority
Last Modified: 2012-06-27

I use windeows 2000 server with IIS and ASP. This works quite good.

However, some of the documents generated need to be printed in an exact way by the users. To have a full control over this proces, they are generated in RTF format.

We give them the extention .RTF or .DOC

We have set server extentions so that these formats are handled by the ASP interpreter.

Each time the document is called, it is (or should be) generated on the fly, including a time-stamp.

We set the appropriate settings so that if a user calls those documents, on his machine MS WORD opens and he can print from there.

We have one problem however. If we call the document with the same document name repeatedly, we have most of the time an old version.

We are sure there is no proxy between server and the client on which we test. On the client we make sure caching is off.

What can be done in order to make sure that every time the document is generated again and in the last version send to the clients.
Question by:infex

Assisted Solution

SMartinHamburg earned 800 total points
ID: 13693092
strange. no idea what the reason is. how about using filenames containing date and time and passing them to the client ?

Accepted Solution

madhubk earned 1200 total points
ID: 13714287
Two questions came to my mind when reading your problem. Please answer these.

See the process flow as an example.

a. RTF file is generated.
b. File is saved as a file on the server (probably with the same filename)
c. A redirect is issued to the page so that the file is opened in the browser window. (possibly redirect to the actual RTF file itself)
d. Displays the old file.

If you are setting the Expire Immediately option in IIS, IIS will not download the latest RTF and might lead to display the old filename as the cache is already present.
See what microsoft says in this regard: http://support.microsoft.com/?kbid=317208

I would suggest you to give a 3-5 minutes expiration time instead of forcing it to expire immediately
How to setup the Cache setting on IIS : http://support.microsoft.com/kb/313561/EN-US/

The questions are:

1. Are you able to download the latest file if copied to a folder which has directory browsing enabled?
2. Are you still able to see the old version of the file if the local cache is cleared?
3. I am sure you might have done this, but is it possible to have the timestamp used as the filename - say "myfilename-050406-1100.rtf" or something.

Please try the above solution and see if you can answer the questions, so that I can be off help for you further.




Author Comment

ID: 13716658
The way you describe is what we did before : generate an RTF file, always with a new name and then automatically redirect the browser to that page whereby the generated pages were removed in batch once a day.

This systems works.

However, we now want to work a different way : an ASP file is given the extention .DOC or .RTF

As we know only the RTF format, no matter which extention we give RTF is generated by the ASP upon calling.

We did set in IIS the necessary settings so that if through the web a file with extension .RTF is called, the concerning ASP page is handled by the ASP interpreter (even if it has the extention .RTF). So no file is made on the server.

The generated RTF is send to the browser, which sees it is to be handled by MS Word and displayed by word.

This goes the first time. However, we are not able to ensure that the users have always the last version.

Apparently we can not use a "response expires" in RTF. The problems seems to be located at the client side.

As the .RTF is in reality a .ASP file on the server side, we can not give it always an other name.

How make sure it is always correctly reloaded?

Featured Post

Get expert help—faster!

Need expert help—fast? Use the Help Bell for personalized assistance getting answers to your important questions.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

When it comes to showing a 404 error page to your visitors, you do not want that generic page to show, and you especially do not want your hosting provider’s ad error page to show either. In this article, I will show you how to enable the custom 40…
Preparing an email is something we should all take special care with – especially when the email is for somebody you may not know very well. The pressures of everyday working life stacked with a hectic office environment can make this a real challen…
When cloud platforms entered the scene, users and companies jumped on board to take advantage of the many benefits, like the ability to work and connect with company information from various locations. What many didn't foresee was the increased risk…
The Relationships Diagram is a good way to get an overall view of what a database is keeping track of. It is also where relationships are defined. A relationship specifies how two tables connect to each other. As you build tables in Microsoft Ac…
Suggested Courses

578 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question