Click here to Skip to main content
15,887,821 members
Home / Discussions / ASP.NET
   

ASP.NET

 
AnswerRe: Which is more secure cms in asp.net web development ? Customized cms or Third party cms(DNN,umbraco,etc) Pin
Dave Kreskowiak16-Feb-15 14:32
mveDave Kreskowiak16-Feb-15 14:32 
GeneralRe: Which is more secure cms in asp.net web development ? Customized cms or Third party cms(DNN,umbraco,etc) Pin
RajeeshMenoth16-Feb-15 17:03
professionalRajeeshMenoth16-Feb-15 17:03 
GeneralRe: Which is more secure cms in asp.net web development ? Customized cms or Third party cms(DNN,umbraco,etc) Pin
Dave Kreskowiak16-Feb-15 17:59
mveDave Kreskowiak16-Feb-15 17:59 
Questionnavigation method Pin
Member 1145476815-Feb-15 20:14
Member 1145476815-Feb-15 20:14 
AnswerRe: navigation method Pin
Dave Kreskowiak16-Feb-15 14:34
mveDave Kreskowiak16-Feb-15 14:34 
QuestionError code 500 Pin
Member 1101185313-Feb-15 23:50
Member 1101185313-Feb-15 23:50 
AnswerRe: Error code 500 Pin
Afzaal Ahmad Zeeshan14-Feb-15 0:01
professionalAfzaal Ahmad Zeeshan14-Feb-15 0:01 
QuestionDisplay one month's result regardless Pin
samflex13-Feb-15 4:04
samflex13-Feb-15 4:04 
Special credit for code below goes to the great Richard Deeming.

Originally, the code was intended to search by date range or specific date.

Currently, a couple of changes have been made to the code per user specs.


Search is now done specifically with date range using jQuery datepicker.

The range could be just one day or multiple days.

Requirement 1: User selects a begin date, let's say 02/22/2015 and end date 02/22/2015(1 day).

The user selection searches Reservations table to see if the date(s) user selected have already been used for prior reservations.

If the date(s) have been taken, present user with on month's worth of results including the taken dates.

If the date(s) have been taken, present one month's worth of results including the taken dates.

How do I modify code below to get it to work?

So far, I run the code and no results are displayed.

Thanks a lot in advance.

PHP
Private Sub showGrid()

    Dim conn As New SqlConnection(ConfigurationManager.ConnectionStrings("conString").ConnectionString)

    Dim cmd As New SqlCommand("-placeholder-", conn)

    Dim sb As New StringBuilder("Select siteID,siteName,AssetName,Capacity,AvailableFacilities,dateReserved,GroupStatus " & _
    ",amenities,RentalFeeAmount,ExtraHourAmount,DepositAmount,CancellationAmount,KeyDepositAmount, Duration " & _
    " FROM ParksNRecsData WHERE siteId = @siteCode and capacity <= @roomcapacity and (CONVERT(VARCHAR(10), dateReserved, 101) >= @FromDate And CONVERT(VARCHAR(10), dateReserved, 101) <= @EndDate)")
    cmd.Parameters.AddWithValue("@siteCode", ddlParks.SelectedValue)
    cmd.Parameters.AddWithValue("@roomcapacity", ddlPartySize.SelectedValue)
    cmd.Parameters.AddWithValue("@FromDate", txtFromDate.Text)
    cmd.Parameters.AddWithValue("@EndDate", txtToDate.Text)

    cmd.CommandText = sb.ToString()
    Dim dt As DataTable = GetData(cmd)
    If dt.Rows.Count = 0 Then

        cmd.Parameters.Clear()
        cmd.Parameters.AddWithValue("@FromDate", Date.Today.ToString("MM/dd/yyyy"))
        cmd.Parameters.AddWithValue("@EndDate", Date.Today.AddMonths(1))
        cmd.CommandText = "Select siteID,siteName,AssetName,Capacity,AvailableFacilities,dateReserved,GroupStatus " & _
    ",amenities,RentalFeeAmount,ExtraHourAmount,DepositAmount,CancellationAmount,KeyDepositAmount, Duration " & _
    " FROM ParksNRecsData" & _
    " where dateReserved Between @FromDate And @EndDate"
        dt = GetData(cmd)
    End If
    gvCustomers.DataSource = dt
    gvCustomers.DataBind()

End Sub

GeneralHow to convert HTMl Div to word Pin
abjchr12-Feb-15 22:33
abjchr12-Feb-15 22:33 
QuestionRe: How to convert HTMl Div to word Pin
Richard MacCutchan12-Feb-15 22:47
mveRichard MacCutchan12-Feb-15 22:47 
AnswerRe: How to convert HTMl Div to word Pin
abjchr12-Feb-15 22:59
abjchr12-Feb-15 22:59 
GeneralRe: How to convert HTMl Div to word Pin
Richard MacCutchan12-Feb-15 23:45
mveRichard MacCutchan12-Feb-15 23:45 
GeneralRe: How to convert HTMl Div to word Pin
abjchr12-Feb-15 23:55
abjchr12-Feb-15 23:55 
GeneralRe: How to convert HTMl Div to word Pin
Richard MacCutchan13-Feb-15 0:11
mveRichard MacCutchan13-Feb-15 0:11 
Questionhow do I insert word, pdf and text to sql database in vb.asp Pin
Shelby12312-Feb-15 14:11
Shelby12312-Feb-15 14:11 
GeneralRe: how do I insert word, pdf and text to sql database in vb.asp Pin
PIEBALDconsult12-Feb-15 14:17
mvePIEBALDconsult12-Feb-15 14:17 
AnswerRe: how do I insert word, pdf and text to sql database in vb.asp Pin
Rollin Shultz12-Feb-15 15:59
Rollin Shultz12-Feb-15 15:59 
Questioniframe is displaying the same document even I am trying to open different documents. Even in byte array is containing different bytes and number of bytes. Pin
VPSingh malhi11-Feb-15 13:58
professionalVPSingh malhi11-Feb-15 13:58 
QuestionMVC Newbie Question - Controller and View - page not found Pin
jkirkerx11-Feb-15 8:17
professionaljkirkerx11-Feb-15 8:17 
Answer[GOT IT] - got that from that Google App Pin
jkirkerx11-Feb-15 11:06
professionaljkirkerx11-Feb-15 11:06 
AnswerRe: MVC Newbie Question - Controller and View - page not found Pin
Afzaal Ahmad Zeeshan12-Feb-15 5:53
professionalAfzaal Ahmad Zeeshan12-Feb-15 5:53 
GeneralRe: MVC Newbie Question - Controller and View - page not found Pin
jkirkerx12-Feb-15 10:45
professionaljkirkerx12-Feb-15 10:45 
AnswerRe: MVC Newbie Question - Controller and View - page not found Pin
Afzaal Ahmad Zeeshan13-Feb-15 0:06
professionalAfzaal Ahmad Zeeshan13-Feb-15 0:06 
GeneralRe: MVC Newbie Question - Controller and View - page not found Pin
jkirkerx13-Feb-15 6:23
professionaljkirkerx13-Feb-15 6:23 
AnswerRe: MVC Newbie Question - Controller and View - page not found Pin
Afzaal Ahmad Zeeshan13-Feb-15 7:02
professionalAfzaal Ahmad Zeeshan13-Feb-15 7:02 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.