Click here to Skip to main content
12,070,171 members (28,960 online)
Rate this:
 
Please Sign up or sign in to vote.
See more: C# ASP.NET C#4.0
Hi,
I have problem with the flow of my project please tell me whether it is possible or not,
I have one grid with radio buttons with the budget names.
i have two buttons under it to load the selected budget and another is to take the snapshot.
now problem is my grid views are filling to the next page when i load the budget but i want snapshot of the gridviews on the same page before loading these budget gridviews.
i have done this,
the procedures i have used for filling the grid views i filled in the dataset on snapshot click and exported to pdf. but the calculations done on next page while loading these grid views obviously not accessible to me. i want some solution to acces these calculations from the next page to previous page. please help me.....
Posted 12-Oct-12 5:07am

1 solution

Rate this: bad
 
good
Please Sign up or sign in to vote.

Solution 1

I believe you have an issue with the way you have structured your pages here. Your pages should only exist to display your information to the user, or collect information from the user. There should never(with few exceptions) be calculations within UI code. Those calculations should be moved either into a domain level class which is where they belong. That way the code becomes reusable and accessible to any page that may require it.

Some may suggest that you should just make the calculation methods public static in the page you need them from, but that is a bad idea, especially when it comes to the maintainability of your application.
  Permalink  
v2
Comments
Nelek 12-Oct-12 11:00am
   
Nice explanation, +5
Marcus Kramer 12-Oct-12 11:03am
   
Thanks Nelek

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
Top Experts
Last 24hrsThis month


Advertise | Privacy | Mobile
Web03 | 2.8.160208.1 | Last Updated 12 Oct 2012
Copyright © CodeProject, 1999-2016
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100