473,785 Members | 3,285 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

datagrid design question

JJ
Hi,

I am using a datagrid to display employee time sheets and need a running
total for datagrid.
So I am wondering since I am displaying totals in footer, should I use maybe
a new datalist or datagrid for new records? So basically have 2 grids one for
updates and the other for new records? If so should I use a panel so that in
update mode it would hide the new records grid and vice versa? What do you
guys think would look and work the best?

Thanks,

JJ
Nov 19 '05 #1
4 1659
Why not have ONE grid with textboxes for each value... ?

I have made one myself that does this for a week at a time where you add
activities dynamically and show the totals in the footer

I have 7 textboxes (one for each day) on each row.. works fine.

/Lars

"JJ" <JJ@discussions .microsoft.com> skrev i meddelandet
news:8E******** *************** ***********@mic rosoft.com...
Hi,

I am using a datagrid to display employee time sheets and need a running
total for datagrid.
So I am wondering since I am displaying totals in footer, should I use
maybe
a new datalist or datagrid for new records? So basically have 2 grids one
for
updates and the other for new records? If so should I use a panel so that
in
update mode it would hide the new records grid and vice versa? What do you
guys think would look and work the best?

Thanks,

JJ

Nov 19 '05 #2
JJ
So what are you using to decide if its a new rec or just an update to a rec?
Do you have an add button in your details area i would assume instead of in
the footer?

JJ

"Lars Netzel" wrote:
Why not have ONE grid with textboxes for each value... ?

I have made one myself that does this for a week at a time where you add
activities dynamically and show the totals in the footer

I have 7 textboxes (one for each day) on each row.. works fine.

/Lars

"JJ" <JJ@discussions .microsoft.com> skrev i meddelandet
news:8E******** *************** ***********@mic rosoft.com...
Hi,

I am using a datagrid to display employee time sheets and need a running
total for datagrid.
So I am wondering since I am displaying totals in footer, should I use
maybe
a new datalist or datagrid for new records? So basically have 2 grids one
for
updates and the other for new records? If so should I use a panel so that
in
update mode it would hide the new records grid and vice versa? What do you
guys think would look and work the best?

Thanks,

JJ


Nov 19 '05 #3
I save the DataTable that I use for DataSource on the Grid in the session
all the time.

Above the grid I have dropdownlist where the user select an activity to add
the the grid.. and then an Add button beside (this is all separated from the
GridControl). When the user clicks the Add button I add the new activity to
the datatable (based on the session variable I have save from the first
DataBound) and then rebind the grid.

Then Underneath the grid I havea save button for when the user is ready to
save it all into the database.. this means you can add as many rows you want
before you save. And if you realize you are doing it on a wrong week or
something.. you simple don't save:)

In the save Sub... I loop thru the grid and check a bunch of things (have
hidden columns for new or old records in the grid) for each row and save
each row at a time.

Does this help?

/Lars
"JJ" <JJ@discussions .microsoft.com> skrev i meddelandet
news:BB******** *************** ***********@mic rosoft.com...
So what are you using to decide if its a new rec or just an update to a
rec?
Do you have an add button in your details area i would assume instead of
in
the footer?

JJ

"Lars Netzel" wrote:
Why not have ONE grid with textboxes for each value... ?

I have made one myself that does this for a week at a time where you add
activities dynamically and show the totals in the footer

I have 7 textboxes (one for each day) on each row.. works fine.

/Lars

"JJ" <JJ@discussions .microsoft.com> skrev i meddelandet
news:8E******** *************** ***********@mic rosoft.com...
> Hi,
>
> I am using a datagrid to display employee time sheets and need a
> running
> total for datagrid.
> So I am wondering since I am displaying totals in footer, should I use
> maybe
> a new datalist or datagrid for new records? So basically have 2 grids
> one
> for
> updates and the other for new records? If so should I use a panel so
> that
> in
> update mode it would hide the new records grid and vice versa? What do
> you
> guys think would look and work the best?
>
> Thanks,
>
> JJ


Nov 19 '05 #4
Check out this article, here i have explained how you can add and update the
datagrid at same time.

Editing and Inserting Multiple Rows at Once:
http://www.microsoft.com/india/msdn/...Questions.aspx

--
Saravana
http://dotnetjunkies.com/WebLog/saravana/
www.ExtremeExperts.com
"JJ" <JJ@discussions .microsoft.com> wrote in message
news:BB******** *************** ***********@mic rosoft.com...
So what are you using to decide if its a new rec or just an update to a rec? Do you have an add button in your details area i would assume instead of in the footer?

JJ

"Lars Netzel" wrote:
Why not have ONE grid with textboxes for each value... ?

I have made one myself that does this for a week at a time where you add
activities dynamically and show the totals in the footer

I have 7 textboxes (one for each day) on each row.. works fine.

/Lars

"JJ" <JJ@discussions .microsoft.com> skrev i meddelandet
news:8E******** *************** ***********@mic rosoft.com...
Hi,

I am using a datagrid to display employee time sheets and need a running total for datagrid.
So I am wondering since I am displaying totals in footer, should I use
maybe
a new datalist or datagrid for new records? So basically have 2 grids one for
updates and the other for new records? If so should I use a panel so that in
update mode it would hide the new records grid and vice versa? What do you guys think would look and work the best?

Thanks,

JJ


Nov 19 '05 #5

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

Similar topics

0
1061
by: Tom S | last post by:
Whenever I put a DataGrid onto an ASP page that has C# code-behind, the code-behind method for DataGrid_SelectionChanged() doesn't fire off unless I've double clicked the DataGrid in design view and had Visual Studio send me to the code. It's as if it doesn't realize that I've coded the method until I double click on the DataGrid. In the current project I'm working on, this poses a problem since I'm not able to see the DataGrid in design...
2
2764
by: SammyBar | last post by:
Hi, I'm trying to bind a custom collection class to a data grid, following the guidelines from the article http://msdn.microsoft.com/msdnmag/issues/05/08/CollectionsandDataBinding/default.aspx. The problem is the article is in VisualBasic. I already get the collection to be recognized as a Data Source by the IDE. It populated the DataGrid correctly from the fields on the items object of the collection, but I can't get the DataGrid to...
2
3272
by: magister | last post by:
Hello, I have xml like this.... <test> <question>sdfsa</question> <section><question>43ga</question> <question>asdf</question> </test>
3
2549
by: Diego TERCERO | last post by:
Hi... I'm working on a tool for editing text resources for a family of software product my company produces. These text resources are found in a SQL Server database, in a table called "Resource" with the following structure : Resource{,en,fr,es} Yes.. these are the only languages supported actually. A couple of rows in that table would look like this :
1
1121
by: Peter | last post by:
Hello, Thanks for reviewing my question. I hope this is a simple question. I would like to know if I have a datagrid attached to a dataset, which in turn is associated with a table, is there a way to hide columns? Can I do it at design time? Thanks again Peter
1
1497
by: Tom S | last post by:
Whenever I put a DataGrid onto an ASP page that has C# code-behind, the code-behind method for DataGrid_SelectionChanged() doesn't fire off unless I've double clicked the DataGrid in design view and had Visual Studio send me to the code. It's as if it doesn't realize that I've coded the method until I double click on the DataGrid. In the current project I'm working on, this poses a problem since I'm not able to see the DataGrid in design...
2
2339
by: Sky | last post by:
Hello: Another question about trying to wring functionality from a DataGrid... Have a DB table of "Contacts" -- 14 or more fields per record Show in datagrid -- but only 5 columns (First,Last, Fax, Phone, Category). Put an Edit column at the end... Now what?! If you go into Edit mode -- you can only edit 5 cells -- not all the rest of the Record's fields...not enough!
4
2126
by: The Alchemist | last post by:
I am having a problem with a dynamically-generated Datagrid. It is important to point out that this problem does not exist with a design-time created Datagrid, but only with a dynamically generated Datagrid in a Web Custom Control (WCC) : The datagrid has LinkButton Column which has a select LinkButton for each row. When this button is clicked, the Datagrid raises its 'ItemCommand' event which captures the information for that row and...
0
2081
by: | last post by:
I have a question about spawning and displaying subordinate list controls within a list control. I'm also interested in feedback about the design of my search application. Lots of code is at the end of this message, but I will start with an overview of the problem. I've made a content management solution for my work with a decently structured relational database system. The CMS stores articles. The CMS also stores related items --...
7
3036
by: Mark B | last post by:
Can someone write some VB.Net example code for me that does this: 1) Creates a gridview control with the results of a SQL stored procedure that has 1 parameter (text) 2) Adds an extra column that displays the result of a VB.Net function that uses a value from an existing column I have spent 4 hours trying to do this after Googling for examples... There are many new concepts that I haven't had much experience with...
0
9643
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, 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...
0
10315
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
10147
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 tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
10085
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,...
0
9947
tracyyun
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...
0
8968
agi2029
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...
0
6737
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
2
3645
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
2877
bsmnconsultancy
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...

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.