Automatically changing size of fields on report

J

jwrnana

I have a report (invoice) that has a field, serial numbers, that may be 1
serial number on one invoice and 15 serial numbers on another invoice.

Is there a way to have the field automatically enlarge to hold this
information? If I make the field large enough, then the majority of my
invoices will have a large blank space between line items as they will only
have 1-2 serial numbers.

This is an Order Entry database and I am using the order entry form and
invoice form provided with it.

Thank you
 
R

Rick Brandt

jwrnana said:
I have a report (invoice) that has a field, serial numbers, that may
be 1 serial number on one invoice and 15 serial numbers on another
invoice.

Is there a way to have the field automatically enlarge to hold this
information? If I make the field large enough, then the majority of
my invoices will have a large blank space between line items as they
will only have 1-2 serial numbers.

This is an Order Entry database and I am using the order entry form
and invoice form provided with it.

Thank you

Set CanGrow property of the TextBox to Yes.

Oh and your table model is flawed. You should not have more than one piece of
data in a single field so all your records with more than one serial number in
them are incorrect. You should instead have an additional table with a one to
many relationship to the current one.
 
J

jwrnana

Thank you for your information.

You said my table model is flawed (which very well may be since I am self
taught). I may not have explained the situation clearly. On an invoice, I
will have an order with i.e.; 2 line items: line item one is for quantity
of 1 widget -- this has no serial number, and second line item is quantity
of 10 units -- each unit has a serial number --- this is all one line item.
The serial numbers are unique to each unit and are not duplicated.

Do I need another table and if so for what - serial numbers? I do have a
products table and order details table. The serial number is in the order
details table as it is unique to the items ordered on that particular order.

Thank you in advance.
 
R

Rick Brandt

jwrnana said:
Thank you for your information.

You said my table model is flawed (which very well may be since I am
self taught). I may not have explained the situation clearly. On an
invoice, I will have an order with i.e.; 2 line items: line item one
is for quantity of 1 widget -- this has no serial number, and second
line item is quantity of 10 units -- each unit has a serial number
--- this is all one line item. The serial numbers are unique to each
unit and are not duplicated.

Do I need another table and if so for what - serial numbers?

Yep. Any time you find yourself adding multiple pieces of data into a
single field that means you need an additional table.
 
J

jwrnana

Ok - I create a serial number table with SerialNumID as primary key. Do I
then link tables with the serial number table 1 to many to the products
table or order details table? Does this change my order entry form or
report form? I am currently entering the serial numbers with a comma
between them.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top