I have a usercontrol with textboxes. Most of which refer to a gridview on selection. A user clicks a looking glass and a gridview appears to select items (like a dropdown). The page loads with databound to each textbox from the DB. They can change fields and update.
The problem I'm having is one textbox with gridview populates another based on selected value. If the textbox is not bound it works fine - make a selection go to the next...
User Profile
Collapse
-
Textbox w/Gridview Databind
-
Gridview/DetailsView/EmptyData
Okay okay this is killing me. I have a gridview with a footerrow to add rooms to the selected value of bldg. When there are no rooms I dropped a detailsview in the emptydatatempla te. I wanted to use the same code I have so the user doesn't have to deal with bldgid but nothing is working. Any ideas how I can accomplish this task, maybe I need to redo everything. Footer row says this and works
Code:Protected Sub gridLocations_RowCommand(ByVal
-
Use of HiddenFields
How do I take a gridview's selected value, hold it in a hidden field and then use it to "insert" view a rowcommand. -
Referencing Detailsview from emptydatatemplate
I have add functionality in my gridview footer and a detailsview in the emptydatatempla te. I need to write the same code I have for gridview_rowcom mand but i'm not sure how to reference it. Basically how do i say this for a detailsview
Code:Protected Sub gridLocations_RowCommand(ByVal sender As Object, ByVal e As GridViewCommandEventArgs) If e.CommandName = "Insert" AndAlso Page.IsValid Then ' Insert
-
Adding foreign key field from gridview
I have a gridview with add functionality embedded in the footer row. My problem is I have an id field in the table that is foreign to another table since I cannot add a record with this id field as a null I've been trying to figure how to get this to work. This grid is already populated from another grid's select based on their related id's. I can manually type the id (did to test). I've tried to bind it to a label so it takes it with the other add... -
Actually I have that page you showed built for the rooms updating, I just got stuck on some of the C# syntax since i'm in VB but switched gears to work on the grid for bldgs. I am working on this one http://www.gridviewguy .com/ArticleDetails. aspx?articleID= 98
However, I don't know how to handle the fact that bldg_id can't be null. I keep getting record cannot be added because nulls aren't allowed?? -
What is this c# snip in vb
Can anyone convert this vb.net. I don't need all the sql commands. Just the first line and declarations.
Code:[B]public List<User> GetAllUsers() { List<User> userList = new List<User>(); [/B] SqlConnection myConnection = new SqlConnection(ConnectionString); SqlCommand myCommand = new SqlCommand(SP_GET_ALL_USERS, myConnection); myConnection.Open();
-
How to accomplish this programmatically - ASP.Net
Here's what I need to do, I have two tables bldgloc (bldg_id, bldg_desc) and roomloc (room_id, room_num, bldg_id). I am trying to build a maintenance screen so that the user can add a bldg or a room. I picture the user selecting the bldg from a list which would then populate all the rooms. When they add room it should be added to the id of the bldg selected.
I'm a beginner and have tried a few things with gridview but can't seem to... -
Is this a homework assignment? Do you need a full paint application or just something that uses the graphics object and mouse events for drawing?Leave a comment:
-
In the add screen (the one that works) I have default settings
Code:If Not Page.IsPostBack Then WQ_Inventory.Util.setDefault("owner", txtOwner) WQ_Inventory.Util.setDefault("status", txtStatus) WQ_Inventory.Util.setDefault("handheld_mfg", txtMfg) WQ_Inventory.Util.setDefault("handheld_model", txtModel) txtStatusDate.Text
Leave a comment:
-
Gridview and Textbox Inconsistent Functionality
I have two pages (asp.net) an add screen which loads with blank text boxes with a gridview so users can select items from a list. Two of them work together when the user selects a building from one and they go to select a room they only see the rooms in the bldg they selected. That works fine.
I have the same functionality on another page in a user control that references the same gridview object. However this page has bound data in... -
Binding data to Gridview footer template textbox
I have a page with two gridviews. One is a list of bldgs, when a bldg is selected the user then sees in another gridview a list of that bldg's rooms. I have converted the room grid into a template and added a footer row with add button and some textboxes for adding a new room to that bldg.
Since i'm new to asp.net I couldn't figure out how to make sure the newly added room would go to the right bldg so I have binded the bldg selected... -
I have a sp that will refresh employee data from one db to another. Although I think it would be easier to just schedule a job nightly. I am told to run the sp from application_sta rt, set the application data to current date. Then in sesssion start if application date is today then don't run sp if not then run so that the first person who hits the asp.net application first will get fresh data.
I'm new and have not ever ran an sp from...Leave a comment:
-
Okay I think I already solved this using a stored procedure joining my employee table and employee history table.Leave a comment:
-
Displaying Updated Columns
I want to use a gridview in my asp.net app to just show changes to one field in an employee table. I have a history table trigger on all fields already for other reasons, however for this purpose i want to be able to show the user what the column said before and after the change.
I read up on the columns_updated function and it seems like it could work however It seems there would be an easier way than figuring out what the bitmask... -
I guess I'm really confused now. I am a trainee developer at work and am told that I need to update the application's employee table from another table so I have a sp written then i should
1. set the application variable in the app to today
2. everytime time i load the app, check if date=today if yes don't run sp, if no run sp
I thought I needed to fire the sp, set the application date to today then in session...Leave a comment:
-
Stored Procedure from Application_start
Does anyone know how I can execute a stored procedure from application
start?Seems like it would be an easy answer to find from online
reading but it's not?! -
Stored Procedure from Application_start
Does anyone know how I can execute a stored procedure from application start?Seems like it would be an easy answer to find from online reading but it's not?! -
Not sure what you are asking, do you want to share the same sp for both db's or how to create the same sp in another db?
Describe what you're trying to do?Leave a comment:
-
Insert/Update SP
Background:
I'm a beginner developer learning when to use the app and when to use the DB to execute what I need. I have two tables in separate databases with employee data. I need to set my asp.net application variable to today so a sp would run based on that.
Question:
The sp needs to check for empid in Table B. If exists update based on info in Table A if not found insert from Table A.
I have this update...
No activity results to display
Show More
Leave a comment: