Current location: Hot Scripts Forums » Programming Languages » ASP.NET » Need help creating this Form with a backend Class reference file...


Need help creating this Form with a backend Class reference file...

Reply
  #1 (permalink)  
Old 02-10-07, 02:54 PM
iampedro iampedro is offline
Newbie Coder
 
Join Date: Dec 2003
Posts: 10
Thanks: 0
Thanked 0 Times in 0 Posts
Question Need help creating this Form with a backend Class reference file...

I am creating a simple form for a customer such as this one: http://www.pctech247.com/Reservations.jpg

Now I am trying to attach a class to this form with the following constants. The following is what I have in my ReservationClass.vb file.

Code:
Private StartDate, EndDate, NumberDays As Integer
    Private Const KINGWEEK_Decimal As Decimal = 95D
    Private Const KINGWEEKEND_Decimal As Decimal = 105D
    Private Const QUEENWEEK_Decimal As Decimal = 85D
    Private Const QUEENWEEKEND_Decimal As Decimal = 95D
    Private Const DOUBELEWEEK_Decimal As Decimal = 69.95D
    Private Const DOUBLEWEEKEND_Decimal As Decimal = 79.95D
    Private Const RoomTax_Decimal As Decimal = 0.07D
    Private Const CustomerDiscount_Decimal As Decimal = 0.1D
    Private Const SummerRate_Decimal As Decimal = 0.25D

    Private DiscountBoolean As Boolean




    'Constructor

    'Sub New(ByVal checkinDate As Date, ByVal checkOutdate As Date)
    'Assign properties and calculate the pay.
    Me

    Private Property Total()
        Get

        End Get
        Set(ByVal value)

        End Set
    End Property

End Class
Now if the dates are selected on the weekend I need to discount by 25 percent and in May through September. As you can see that I have set with " Private Const SummerRate_Decimal As Decimal = 0.25D"

If someone checks AAA & AARP customers they receive 10% off which I defined in this "Private Const CustomerDiscount_Decimal As Decimal = 0.1D"

Now I don't know how I am suppose to attach this back to the form or even figure out what I need to do. I am very basic at this and I know that I need to get something back to the customer by Monday afternoon. Please help me out on this...

Last edited by koncept; 02-10-07 at 03:37 PM. Reason: use code tags please
Reply With Quote
  #2 (permalink)  
Old 02-10-07, 03:40 PM
koncept
Guest
 
Posts: n/a
the easiest way to add this to that page is add it into the <script runat="server"> tag on the page. if you are using codebehinds, then add it with in the module section.
Reply With Quote
  #3 (permalink)  
Old 02-10-07, 05:31 PM
iampedro iampedro is offline
Newbie Coder
 
Join Date: Dec 2003
Posts: 10
Thanks: 0
Thanked 0 Times in 0 Posts
Well as you see from the link to the screen shot this is a program not a web page...


Where would you suggest that I look at for some code about this?
Reply With Quote
  #4 (permalink)  
Old 02-10-07, 07:17 PM
koncept
Guest
 
Posts: n/a
ok, you can create a new file and attach it that way or at the bottom of code for the form between the very first sub and the module like you can paste it (it can go any where between subs but it is typically found at the top)
Reply With Quote
  #5 (permalink)  
Old 02-12-07, 12:07 PM
iampedro iampedro is offline
Newbie Coder
 
Join Date: Dec 2003
Posts: 10
Thanks: 0
Thanked 0 Times in 0 Posts
Do you have any examples of code out on the web or something like what you are stating koncept?
Reply With Quote
  #6 (permalink)  
Old 02-12-07, 03:50 PM
koncept
Guest
 
Posts: n/a
i am not sure what you mean. and let me back up a bit the .vb file you mention, is that one tied to the form with its functions and such?
Reply With Quote
Reply

Bookmarks


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Writing to php file, via a form? j-a-m-i-n PHP 4 10-14-06 04:43 AM
ASP upload prob minority ASP 1 06-27-05 08:35 AM
checkCheckboxGroup broken after form consolidation ski_woman JavaScript 0 01-12-05 11:00 AM
Write form data to file dragge PHP 1 12-27-03 07:26 PM
Upload file to table so ONLY files tied to primary key are displayed in record? grafixDummy PHP 4 12-20-03 04:28 PM


All times are GMT -5. The time now is 02:30 PM.
vBulletin® Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.