Hi All,
FACTS:
> I've created a VB.NET 2005 form, with a SQL Server 2000 backend
> The form has about 30 fields that populate 30 columns in the SQL database
> The form has mostly text feilds, with standard info such as Customer, order Number, etc.
> Im trying to autopopulate one of the feilds on the form, called Reference Number.
> The SQL column on the backend auto increments fine
> The Reference Numbercolumn has identity specification 'Yes', Increment '1', etc.
WHAT IS WORKING:
> I fill out all the fields on the .aspx form, it populates the database fine
> The Reference number auto increments by 1, which is great
WHAT I WANT:
> Employee should be able to launch the form, and have the Reference Number field auto populate on the form.
QUESTION:
> Should the Reference Number part of the VB.NET web form be a label?
A text box accepts input from a user... but in the case of the Reference Number, the user should have it automatically populated open launching the page. sounds like a label to me.
Any help, code samples would be appreciated.
Thanks,
Best,
Paul
2 4742 tlhintoq 3,525
Recognized Expert Specialist
A label would certainly work. Does it give you the visual appearance you want on the form? If everything else is a text box, maybe using a textbox would give you a more consistent appearance. Setting it to "read only" would keep people from changing the value. Changing the backcolor to something slightly off from the other textboxes gives the look that it is *meant* to not be changeable. You could also just set it to "enabled = false" to give it a dimmed appearance, not changeable, yet still readable.
So yes, a label will work. Do you like how that looks?
Well, tlhintoq, your absolutely correct. A text box is better, set as read only - and changing the back color to show its not supposed to be changable. Your already getting me in the right direction!!
Now... how do I get this Text box populated with the auto increment from the database. It probably starts with some code in a Page_Load event... since a page load by the visitor is the event that fires the web form.
Thanks again!
Paul
Sign in to post your reply or Sign up for a free account.
Similar topics |
by: John |
last post by:
I have two fields on a form. Once called School, the second called
SchoolZip
I want the users to be able to go to the ComboBox field called School,
select the school they want, and have it auto populate the SchoolZip
field too.
Combobox name = School
Row Source Type = Table / Query
Row Source = SELECT tSchools.School, tSchools.ZipCode FROM tSchools;
Bound Column = 1
|
by: John Phelan-Cummings |
last post by:
I'm not certain if this made the post. Sorry if it's a repeat:
Using a Button to take an autonumber from one form to populate another
autonumber field on another form.
I have a Mainform "A" with a button and code that opens another Mainform
"B"
with a subform which has the same table as Mainform "A".
The button is supposed to tell the subform with the autonumber field
|
by: Jim |
last post by:
I have a new database in which I have a form where in one field I type
a letter A, B, C or D and the field next to it autofills (auto lookups)
with a description associated with the specific letter. If I edit the
description for one record, it edits the same for all records in which
I've applied the same autofill (auto lookup). I'm set up where the
letters come from a lookup combo box (limit to list "Yes") and the
record source for the...
|
by: keri |
last post by:
Hi,
I'm still struggling with my tables - frustrating.
If a field in table one is completed I want the following field to auto
populate (dependng on the answer to the first field). I have created a
seperate table with the data to auto populate from but I don't have a
clue.
If you could answer with baby language i'd appreciate it! Or e-mail
|
by: alphaomega3 |
last post by:
OKay here is the situation. I am creating an inspection log database and have previously created an Non-conformance database. I am trying to get the NCRno field to auto-populate after I update the qtyrej field. the procedure is that we receive the material, inspect it, then log it. The Inspector will get to the point of accepting or rejecting and click a control button that takes them to a form that is has a linked table to enter the...
| |
by: jacklindsay |
last post by:
Hello smarter people than me
I am creating a database for college, and have requested some help, but they are unable to help me. ( im obviously too eager)
anyway, im creating a database on computer components and peripherals (i.e networking devices, hard drives etc etc), the previous mentioned devices are in a table called product catagories which in the form, are a drop down. I also have 2 text box fields, 1 is for the product...
|
by: joshua.nicholes |
last post by:
I have an access database that consists of two tables.A data
collection table and a species list table. The data collection table
has about 1500 records in it and the species list has about 600. The
species list has 7 fields the first is a four digit unique identifier
(species) it is set as the primary key. I have created a relationship
to the data collection table which also has a species field (4 digit
id). In my form I have the species...
|
by: whamo |
last post by:
I have the need to populate a field based on the selection in a combo box.
Starting out simple. (2) tables tbl_OSE_Info and tbl_Input;
tbl_OSE_Info has three fields: Key, OSE_Name and OSE_Wt
tbl_Input has three fields: OSE_Job, OSE_Name, OSE_Wt
I have populated tbl_OSE_Info table.
I need to create a form that will store the data in tbl_Input
I have racked my brain so much trying to figure out how to auto populate a field based on a...
|
by: Puzzled and Confused |
last post by:
It seems like a simple request, but I cannot get it to work. Does anyone know to how to make data from one field auto populate in another field, only if the answer is yes/true? I have a form that I would like the exact data, which varies, to auto populate only after an update to yes. A toggle button is to answer the field, but I would like for the answer to be the data from another field. Please advise. Thanks!
|
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, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look !
Part I. Meaning of...
|
by: Hystou |
last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it.
First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
| |
by: Hystou |
last post by:
Overview:
Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
|
by: tracyyun |
last post by:
Dear forum friends,
With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
|
by: agi2029 |
last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own....
Now, this would greatly impact the work of software developers. The idea...
|
by: isladogs |
last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 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 a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules.
He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms.
Adolph will...
|
by: adsilva |
last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
|
by: 6302768590 |
last post by:
Hai team
i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
| |
by: bsmnconsultancy |
last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...
| |