Direct Print
I ám looking for print function in ASP and/or Javascript which can print without pop up the page just as desktop application did. so when you click the print button it will directly print without open a page.
View RepliesI ám looking for print function in ASP and/or Javascript which can print without pop up the page just as desktop application did. so when you click the print button it will directly print without open a page.
View Repliesi make a data display page, its showing all records, now i want user just press print button, and that print all data on screen, secondly user input 2 dats From ..... To......, so data in between that day will print,
View Replies View RelatedNo error or any feedback that I can work with.
Code:
set objShell = Server.CreateObject("WScript.Shell")
objShell.Run "%comspec% /c NET PRINT GarchiveISLaser[color=blue]
>c:WUTempPrinter_Status1.txt", 0, True[/color]
objShell.Run "%comspec% /c PRINT /d:GarchiveISLaser c:WUTemp est.txt",
0, True
Set objShell = nothing
I can run these commands successfully from the command-prompt on the server
but from an ASP page, I get nothing not even an error. The Text output for
NET PRINT is a blank text file.
I feel something is different on the permissions side because this
code/approach use to work fine.
When I use self.print the browser launches the print prompt, then I have to manually press print... DOes anyone know how to get around this.
View Replies View RelatedI am using server side javascipt and want to do a redirect to another asp page passing parameter values using the POST method. This redirect needs to occur if an else statement in my code is reached. I need to have a function which does this redirect to the other asp page, passing the parameters via POST.
View Replies View Relatedcan i directly mail to hotmail or yahoo acount with any asp.net code.
i have an example like above but i need smtp adress for hotmail, i tried it for smtp.mail.yahoo.com but it didnt work and "authentication required" error accured
here is the code: ....
I have an asp page which basically takes some data from a previous
page form and inserts the data to my database and then does a
re-direct to:
Response.Redirect "JS_Create.asp"
On this page is just an animated logo saying something like 'Loading
Data ....'
On this asp page JS_Create.asp I have another re-direct handled by a
timer to go to JobSheet.asp.
The idea is that the user enters data into the form, if the form is
validated correctly, they are transferred to the next page which tells
them the data is loading. They are held there for say 3 to 5 seconds
and then transferred to the final page JobSheet.asp.
The code I have on JS_Create.asp for the timed re-direct is: Code:
I have a web site in asp where I do not want the users to
directly type in the URL
of some pages in the browser. For e.g. the main page
is 'index.asp' and depending on
the users resolution either 'mypage1024.asp' or
page 'my800.asp' would open up in the
browser.
What I want is that no user should be able to directly
access the page by typing in
the URL www.mysite.com/page1024.asp or
www.mysite.com/800.asp. If a user
tries to access these pages directly then they should be
forcefully redirected to the
home page www.mysite.com/index.asp and this page would
check the resolution
and load the 'mypage1024.asp' or 'mypage800.asp' depending
I have used ASP to force a user to log on to a page prior to allowing them to see a page including images. However, once a person knows the URL to the image on its own a person can type in that full URL and see the image, without being logged in.
For example, password login required to get to:
http://www.mydomain.com/showmypics.asp
But, you can navigate straight to:
http://www.mydomain.com/pictures/mypicture.jpg
how to prevent a user going to the picture directly?
I have a page with a div tag styled in this div is a list of projects pulled from a db.
text-align: middle;
clear: both;
overflow: auto;
width: 95%;
height: 175px;
This means that the content in the div tag when larger than the div height has a scroll bar at the side to view all the projects. Once the projects area displayed there is a image at the end of each row that when clicked goes to the db and pull back reports for that project. This is all done by passing vars in the querystring pulling info from the db and writing out the appropriate code. Code:
i have uploaded my files and now it comes up with a 500 error message. what i did was when i started bulding the site i used dreamveaver and its dsn connection and its features but now i need to change the dsn connection on the relevant pages to direct connection and i am very very confused how i will do this and as an amature i need help. to start of my default.asp uses dsn conection can you show me all the sections i need to change.i have attached a txt file that contains all the code in my default.asp page.
View Replies View Relatedi was hoping to include a 'page direct' function into this if-then statement below. I want the user who is logged into the session to be directed automatically to the purchase.asp page. I know the goto statement is wrong here. Any suggestions on what I should be using unstead?
<%
if session("name") <> "" then
goto "purchase.asp"
else
response.write "You must log in to buy views.<p>"
end if
%>
I have a page that logs the user in (the code will be below). When they log in correctly, or even incorrectly, they get directed to default.asp. The login is working correctly however because when I log in with a false name and password I cannot proceed to checkout. How can i direct the user (ONCE they are signed in correctly) to a customer page(custpage.asp) instead of my homepage(default.asp)? Code:
View Replies View RelatedBasically I have something that needs to be installed in the htdocs in order for me to use it - however i need to be able to access something thats in the private dir on the same dir.
Dirs go like
/whateverftp/
/whateverftp/private/
/whateverftp/htdocs/
obv Const DB_FOLDER_PATH = "/whateverftp/private/" wouldn't work, what would I put in there in order to gain access to the private dir?
I have a 'primary' intranet website and a 'secondary' backup of this site as
well. I would like to programmatically have the effect that if the
primary site is (page not found 404) not available, for it to access the
secondary site or at least be able to add a message with (or instead of) the
404 error dialog that the primary site is down and give the user a link to
the alternative (secondary) site.
i want to make a direct connection to my SQL server 2000 database without using Data Sources (ODBC) like on access. Code:
et db=server.createobject("ADODB.connection")
db.open("DRIVER={Microsoft Access Driver (*.mdb)}; DBQ="+server.mapPath ("db1.mdb"))
so anybody have an idea about the code>?
If you have a directory of pdf files, how can you prevent someone from typing in www.yoursite/pdf_folder/some_file.pdf and getting that file? You could write a login script but if they know the path to the pdf, they could get it. I want to prevent people from doing this.
View Replies View RelatedI have an email containing link say (somelink.asp) A user clicks on this link (say from outlook). because this user is not logged into the site, the request goes to somelink/login.asp.
The user then logs in. After successful login I would like to take this user to the link he clicked on originally. Is this possible without having to pass the lionk url as part of the query string?
Is there a way where I can prevent people from downloading a file using a direct link (or bookmarked) (i.e. http://www.myfile.com/file.csv)? I want my user to log in with their email address so I can keep track of who downloads my files and when.
I already wrote a filedownload.asp file already which tracks and logs users who downloads the file. But I made a mistake in giving out the direct links to people already. So now people are using that direct link which bypasses filedownload.asp file. If there are any techniques on doing this.
I changed domains on a site - I would like a re-direct errorpage script that re-directs from:
www.originaldomain.com/page.asp?a=26
To new:
www.newdomain.com/page.asp?a=26
Is this possible? (all page ids are the same in the old and new). As it is now, I just have a simple re-direct that goes to the mainpage no matter which page people are coming from.
I have ASP statements stored in SQL and want to run them on an ASP page. I am printing the data onto the page using ASP, but the ASP code that comes from SQL just appears as actual text. For example, it appears as:
<a href="<%request.redirect("http://www.yahoo.com")%>">Yahoo</a> Rocks
instead of just the link: Yahoo Rocks
Any idea of how to run the ASP scripts from SQL, yet still print out the text around it plainly?
I am developing an Intranet application for a business. I would like to be
able to print out certain bits of information just as regular applications
do. I realize that this is a little more difficult, and after doing
research it seems that the best way to print is to use JavaScript's
"window.print();" command.
The only problem I have with this is that
#1 - it prints the address and date at the bottom of the page
#2 - it prints the page numbers at the top of the page.
Is there any way around this (without having to alter IE's configuration)?
Or perhaps do I need to approach printing in another way? Perhaps VBScript?
Is there such a thing as putting some code on a page that makes it so noone could print out that page? Maybe something that disables the browsers print function or something?
View Replies View RelatedHow to print in asp or how to use Crystal report in visual Interdev or frontpage?
View Replies View RelatedI have a problem opening a file with ADODB.Stream when <HTML> exists on the same page
here is the code I use :....
i seem to have a problem printing my timesheet to make it fit into a a4 paper. is there a way to have it to print using ASP but force it to print in a4 landscape.I have tried using my printer settings and force it to landscape,but the whole table and font comes out really big and makes it continue to print to another page.
I have also tried to use the printer settings to print into A4 or even print to 60% of the size, but still cannot. Even though the data is not really long it goes to another page.
I've built a form/report for visualize the informations from database. I've used jscript code. How do for printing on the network or local printer ?
View Replies View RelatedI am trying to implement a printing to file solution of a html page on the server. What I have is a form with a IE control that loads the page I want to print to.
I am using execWB command for printing. Printer's port is set 'To file'. Everything works fine when I am running that component from a desktop apps. But when I call that component from an asp page nothing is happening. I dont see any dialogs popping up on the screen.
BTW, if I print to a printer works fine either.
can we print asp records which are retrieved from data base with a print button
View Replies View RelatedWe have LOADS of documents scanned to PDF format, stored
in SQL tables.Allowing a client to browse our ASP driven site to select
and view individual PDFs has been no problem. ("index"
table is queried to show list of available PDFs, user
clicks a link in the list, PDF reader shows the document
in a new window.)
Now, they would like a feature that would PRINT (at their
location) batches of documents via the website,
preferablely with a single click.
I would like to have a PRINT button on my page, that redirects to another page which is more printer friendly.
I am pulling the content of a database (msAccess) into the initial page, and want that content to carry accross..
Here is an example of the page http://www.australie-voyages.com/en...-tours.asp?id=8
how can i print the current page when i click the print button in this page??
View Replies View RelatedI'm having problems printing to the page. When the user click on the print button it is suppose to print the document to the page and it's not. What am I doing wrong? Code:
View Replies View Related