473,387 Members | 1,757 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,387 software developers and data experts.

Executing a asp.net page repeatedly????New page???

Dan
Hi,

I have an asp.net page i have made that creates an invoice based on the
invoice id given.

It works fine but the problem i have is i now want to loop through my
database and grab all the invoice numbers.

As it grabs each invoice number i want to pass it into my asp.net page,
execute it and display it so that each invoice falls on its own page leaving
me with an end result of pages of invoices all after one another so i just
click print.

The problem is as i have absolutely positioned everything with the
gridlayout so it doesn't move any of my items along so they all go on top of
each other in a mess.

SO ideally i want to execute the asp.net page for an invoice number, pass
the result not to the screen to be displayed but directly to the printer,
then move to the next invoice number and repeat.

Can anyone tell me how i can do this? Also it is important to mention i work
remotely from my server, so i am guessing any printing being fired off on
the server will attempt to print from my servers printer and not mine.

If that is the case i do have an internet printer so i would still be
interested in those answers however the option of getting the invoices to be
displayed neatly within my browser one after the other would suffice.

Options i have thought of is to put it all in a panel that is exactly one
page in size and then loop making new panels with the contents inside,
however if i had any invoices over a page long they would get truncated i
imagine?

I have also thought of making the first invoice then the second one to
always be x many pixels below it relative to the first etc, again very messy
way of doing it.

Surely there is a simple 'new page' ability?
Thank you in advance
Dec 29 '05 #1
4 1515
Im not 100% sure what you are trying to do but it sounds like you are trying
to build one huge page composed of loads of invoice pages. If this is
correct, you are not really going about this in the best way I would think.

On your page, have a btnRetreive which populates the fields for the number
supplied, for each subsequent request like btnRetreieveNext_Click

Create an SQL statement which gets the next number and populate again.

--
Best Regards

The Inimitable Mr Newbie º¿º
"Dan" <dv*******@aol.com> wrote in message
news:eX*************@TK2MSFTNGP10.phx.gbl...
Hi,

I have an asp.net page i have made that creates an invoice based on the
invoice id given.

It works fine but the problem i have is i now want to loop through my
database and grab all the invoice numbers.

As it grabs each invoice number i want to pass it into my asp.net page,
execute it and display it so that each invoice falls on its own page
leaving me with an end result of pages of invoices all after one another
so i just click print.

The problem is as i have absolutely positioned everything with the
gridlayout so it doesn't move any of my items along so they all go on top
of each other in a mess.

SO ideally i want to execute the asp.net page for an invoice number, pass
the result not to the screen to be displayed but directly to the printer,
then move to the next invoice number and repeat.

Can anyone tell me how i can do this? Also it is important to mention i
work remotely from my server, so i am guessing any printing being fired
off on the server will attempt to print from my servers printer and not
mine.

If that is the case i do have an internet printer so i would still be
interested in those answers however the option of getting the invoices to
be displayed neatly within my browser one after the other would suffice.

Options i have thought of is to put it all in a panel that is exactly one
page in size and then loop making new panels with the contents inside,
however if i had any invoices over a page long they would get truncated i
imagine?

I have also thought of making the first invoice then the second one to
always be x many pixels below it relative to the first etc, again very
messy way of doing it.

Surely there is a simple 'new page' ability?
Thank you in advance

Dec 29 '05 #2
First off, if it is the absolute positioning causing the problem, then the
obvious solution is to get rid of it, and redo your page with relative
positioning. Absolute positioning should almost never be used, in my
opinion.

Secondly, you should build a datalist or a repeater, with the right template
for displaying one invoice. Then just bind the list of invoices to the
datalist/repeater, and it will all look correct right away. The only part I
am not sure about is if you can force page breaks so that you print them all
on a separate page.

"Dan" <dv*******@aol.com> wrote in message
news:eX*************@TK2MSFTNGP10.phx.gbl...
Hi,

I have an asp.net page i have made that creates an invoice based on the
invoice id given.

It works fine but the problem i have is i now want to loop through my
database and grab all the invoice numbers.

As it grabs each invoice number i want to pass it into my asp.net page,
execute it and display it so that each invoice falls on its own page
leaving me with an end result of pages of invoices all after one another
so i just click print.

The problem is as i have absolutely positioned everything with the
gridlayout so it doesn't move any of my items along so they all go on top
of each other in a mess.

SO ideally i want to execute the asp.net page for an invoice number, pass
the result not to the screen to be displayed but directly to the printer,
then move to the next invoice number and repeat.

Can anyone tell me how i can do this? Also it is important to mention i
work remotely from my server, so i am guessing any printing being fired
off on the server will attempt to print from my servers printer and not
mine.

If that is the case i do have an internet printer so i would still be
interested in those answers however the option of getting the invoices to
be displayed neatly within my browser one after the other would suffice.

Options i have thought of is to put it all in a panel that is exactly one
page in size and then loop making new panels with the contents inside,
however if i had any invoices over a page long they would get truncated i
imagine?

I have also thought of making the first invoice then the second one to
always be x many pixels below it relative to the first etc, again very
messy way of doing it.

Surely there is a simple 'new page' ability?
Thank you in advance

Dec 29 '05 #3
Thanks for the comments so far.

Mr newbie - i had thought of the same method the problem is that when i have
20-30 invoices to print a day and going up all the time it gets very tedious
to do them one by one even with a click next and print method. Which is why
i want them all available to be printed straight off with one print.

Marina - not sure why you hate absolute positioning so much, each to their
own i guess. I find it much easier to position items exactly where i want
them that way, maybe it was the way i was doing it before.
I did consider the datarepeater route but I am quite the amateur with it so
i am not sure if you can help but i will explain why.

First of all is it not possible to use a data repeater with absolutely
positioned elements?
Secondly my invoice is laid out with an image of the company logo in the top
left, a logo and delivery address to the right of this that, when printed,
lines up perfectly with the paper we use so that part is peeled off and
stuck on a parcel, then under this a list of the items for the invoice but
laid out to look more pretty than just a grid but this is built in a table.

Can a layout like that be done using repeater?

Thanks in advance
"Marina" <so*****@nospam.com> wrote in message
news:uK**************@TK2MSFTNGP14.phx.gbl...
First off, if it is the absolute positioning causing the problem, then the
obvious solution is to get rid of it, and redo your page with relative
positioning. Absolute positioning should almost never be used, in my
opinion.

Secondly, you should build a datalist or a repeater, with the right
template for displaying one invoice. Then just bind the list of invoices
to the datalist/repeater, and it will all look correct right away. The
only part I am not sure about is if you can force page breaks so that you
print them all on a separate page.

"Dan" <dv*******@aol.com> wrote in message
news:eX*************@TK2MSFTNGP10.phx.gbl...
Hi,

I have an asp.net page i have made that creates an invoice based on the
invoice id given.

It works fine but the problem i have is i now want to loop through my
database and grab all the invoice numbers.

As it grabs each invoice number i want to pass it into my asp.net page,
execute it and display it so that each invoice falls on its own page
leaving me with an end result of pages of invoices all after one another
so i just click print.

The problem is as i have absolutely positioned everything with the
gridlayout so it doesn't move any of my items along so they all go on top
of each other in a mess.

SO ideally i want to execute the asp.net page for an invoice number, pass
the result not to the screen to be displayed but directly to the printer,
then move to the next invoice number and repeat.

Can anyone tell me how i can do this? Also it is important to mention i
work remotely from my server, so i am guessing any printing being fired
off on the server will attempt to print from my servers printer and not
mine.

If that is the case i do have an internet printer so i would still be
interested in those answers however the option of getting the invoices to
be displayed neatly within my browser one after the other would suffice.

Options i have thought of is to put it all in a panel that is exactly one
page in size and then loop making new panels with the contents inside,
however if i had any invoices over a page long they would get truncated i
imagine?

I have also thought of making the first invoice then the second one to
always be x many pixels below it relative to the first etc, again very
messy way of doing it.

Surely there is a simple 'new page' ability?
Thank you in advance


Dec 30 '05 #4
There is no 'Easy' answer to your question, its just really about choosing a
method which will work. To break down the problem into smaller steps if I am
correct ?

1.) Choose a range of invoices and then hit the print button right ?
2.) Watch them reel off the printer and have them peeled of and stuck on the
box ?

Why not skip the web forms entirely and use something like crystal reports
you can orgainise it so the reports go directly to the printer without
having to have each invoice form brought up.

--
Best Regards

The Inimitable Mr Newbie º¿º
"Daniel" <Da*****@vestryonline.com> wrote in message
news:OV**************@TK2MSFTNGP15.phx.gbl...
Thanks for the comments so far.

Mr newbie - i had thought of the same method the problem is that when i
have 20-30 invoices to print a day and going up all the time it gets very
tedious to do them one by one even with a click next and print method.
Which is why i want them all available to be printed straight off with one
print.

Marina - not sure why you hate absolute positioning so much, each to their
own i guess. I find it much easier to position items exactly where i want
them that way, maybe it was the way i was doing it before.
I did consider the datarepeater route but I am quite the amateur with it
so i am not sure if you can help but i will explain why.

First of all is it not possible to use a data repeater with absolutely
positioned elements?
Secondly my invoice is laid out with an image of the company logo in the
top left, a logo and delivery address to the right of this that, when
printed, lines up perfectly with the paper we use so that part is peeled
off and stuck on a parcel, then under this a list of the items for the
invoice but laid out to look more pretty than just a grid but this is
built in a table.

Can a layout like that be done using repeater?

Thanks in advance
"Marina" <so*****@nospam.com> wrote in message
news:uK**************@TK2MSFTNGP14.phx.gbl...
First off, if it is the absolute positioning causing the problem, then
the obvious solution is to get rid of it, and redo your page with
relative positioning. Absolute positioning should almost never be used,
in my opinion.

Secondly, you should build a datalist or a repeater, with the right
template for displaying one invoice. Then just bind the list of invoices
to the datalist/repeater, and it will all look correct right away. The
only part I am not sure about is if you can force page breaks so that you
print them all on a separate page.

"Dan" <dv*******@aol.com> wrote in message
news:eX*************@TK2MSFTNGP10.phx.gbl...
Hi,

I have an asp.net page i have made that creates an invoice based on the
invoice id given.

It works fine but the problem i have is i now want to loop through my
database and grab all the invoice numbers.

As it grabs each invoice number i want to pass it into my asp.net page,
execute it and display it so that each invoice falls on its own page
leaving me with an end result of pages of invoices all after one another
so i just click print.

The problem is as i have absolutely positioned everything with the
gridlayout so it doesn't move any of my items along so they all go on
top of each other in a mess.

SO ideally i want to execute the asp.net page for an invoice number,
pass the result not to the screen to be displayed but directly to the
printer, then move to the next invoice number and repeat.

Can anyone tell me how i can do this? Also it is important to mention i
work remotely from my server, so i am guessing any printing being fired
off on the server will attempt to print from my servers printer and not
mine.

If that is the case i do have an internet printer so i would still be
interested in those answers however the option of getting the invoices
to be displayed neatly within my browser one after the other would
suffice.

Options i have thought of is to put it all in a panel that is exactly
one page in size and then loop making new panels with the contents
inside, however if i had any invoices over a page long they would get
truncated i imagine?

I have also thought of making the first invoice then the second one to
always be x many pixels below it relative to the first etc, again very
messy way of doing it.

Surely there is a simple 'new page' ability?
Thank you in advance



Dec 30 '05 #5

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

Similar topics

7
by: Brian Burgess | last post by:
Hi all, Anyone know of any special issues with Server.Execute? Specifically for me it simply is not executing ... the server does not transfer to the page specified. The calling ASP just...
10
by: Mike | last post by:
I know this sounds strange but I am at a loss. I am calling a simple funtion that opens a connection to a SQL Server 2000 database and executes an Insert Statement. private void...
7
by: Jibey | last post by:
Hello: I'm facing a very strange problem. When I run my Web application in Visual Studio.NET the Page_Load event is not executing. Other events like a Button_Click are executing. It doesn't...
7
by: tshad | last post by:
I thought I understood how the SaveViewState is working and was trying to use this (as per some code I found) to detect refreshes. It seemed to be working but I found that the SaveViewState was...
2
by: =?Utf-8?B?Um9nZXIgTWFydGlu?= | last post by:
I am executing an AJAX page method that is a long running task. After starting the first method, I execute a second page method to retrieve the status of the task. It works fine in an empty web...
7
by: jphaycock | last post by:
Hi all I am calling a method in a Page_Load event that makes use of a value from a text box. Unfortunately the textbox value is only set after a javascript runs and the page is rendered....
1
by: yashgt | last post by:
Hi, We have a control Logo.ascx, which queries the DB to obtain the logo image from a blob in the DB and renders it on the page. The logo does not change frequently and hence we have tried to...
0
Frinavale
by: Frinavale | last post by:
I have a peculiar problem... Background: I have a function that I don't want the user to execute more than once while they are waiting for it to process; therefore, I disable all of the...
5
oranoos3000
by: oranoos3000 | last post by:
hi I want to repeat executing a seri of the code in page in interval periodic time without use from infinite loop and i prefer that page is not refreshed only a seri of the code is execute....
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

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.