Results 1 to 7 of 7
  1. #1
    Join Date
    Nov 2003
    Location
    england
    Posts
    95

    Unanswered: which way is best?

    Hi guys need some advice:

    I want the students 2 b able to book more than 1 piece of equip out at one time....is it:

    a) more easyier to program - to get them to make one booking in the sys

    b) easier for user (but appa harder to program) - to let the users make a selection??

    on a booking form????

    cheers guys :>

  2. #2
    Join Date
    Aug 2003
    Location
    Argentina
    Posts
    465

    Re: which way is best?

    Originally posted by lucyg_2000
    Hi guys need some advice:

    I want the students 2 b able to book more than 1 piece of equip out at one time....is it:

    a) more easyier to program - to get them to make one booking in the sys

    b) easier for user (but appa harder to program) - to let the users make a selection??

    on a booking form????

    cheers guys :>
    Can you clarify the question
    Saludos
    Norberto

  3. #3
    Join Date
    Mar 2004
    Location
    Nashville, TN
    Posts
    557

    Not sure exactly.

    I am not exactly positive I got what you are trying to get across, but I would have to say based on what you have asked I would go with allowing the user the ability to select.

    Making applications 'user friendly' is one of the biggest problems with most databases today. The less the user has to do, to get what they want the better.

    I hope that helps, If not let me know and try and restate your question.


    Thanks,
    Jarvis
    Have you ever thought about thinking on purpose?

    Jarvis Stubblefield
    Patriot Designs
    Web/Database Development and Consulting
    The-Patriot.net by Patriot Designs

  4. #4
    Join Date
    Nov 2003
    Location
    england
    Posts
    95
    I know there i a way where you can have a form that lets u select from drop down list items to aapear on another (sub form) i think but am not sure. But apparently that would be hard to program, so I just want to be able to let the user select one item to loan out and go back and do it again....its for a projet but is going to be used in real life so im not sure whether to do it the easy way first then as i ave time to implemnt it do it the first way i described?!?!?!

    Its just gonna be like a library system....

  5. #5
    Join Date
    Sep 2003
    Location
    The extremely Royal borough of Kensington, London
    Posts
    778
    Users(user_id)
    Loan_Items(user_id, item_id, date_out)

    1) Check that count(*) from Loan_Items where user_id = 'user' is less than library limit.
    2) Once item is returned, compare current date with date_out + item_duration.
    3) Delete records from system. (depends on business rules)

    An alternative may be to delete all loan_item records periodically once returned (ie, date_returned is not null), except for those records where an item corresponds to an outstanding fine.
    Bessie Braddock: Winston, you are drunk!
    Churchill: And Madam, you are ugly. And tomorrow, I'll be sober, and you will still be ugly.

  6. #6
    Join Date
    Mar 2004
    Location
    Nashville, TN
    Posts
    557

    Hrm...

    I dont know how to tell you to code the forum to do what you are wanting it to, but I think it would be best to figure it out first off to save you the time and trouble later. I would hate for you to have to restructure your database for some reason because you wanted to take the quick way right now. :-/ (I have had to do that and it totally sucked )
    Have you ever thought about thinking on purpose?

    Jarvis Stubblefield
    Patriot Designs
    Web/Database Development and Consulting
    The-Patriot.net by Patriot Designs

  7. #7
    Join Date
    Aug 2003
    Location
    Argentina
    Posts
    465
    Originally posted by lucyg_2000
    I know there i a way where you can have a form that lets u select from drop down list items to aapear on another (sub form) i think but am not sure. But apparently that would be hard to program, so I just want to be able to let the user select one item to loan out and go back and do it again....its for a projet but is going to be used in real life so im not sure whether to do it the easy way first then as i ave time to implemnt it do it the first way i described?!?!?!
    Its just gonna be like a library system....
    This code make a query from the item select in a control list of your main form. That query must be the RecordSource of your Subform.
    You can put the code in a Comand Button.......
    Some part of the code is in spanish because i must do some adaptation.
    I hope this can help you

    Private Sub cmdRunReport_Click()
    On Error GoTo Err_cmdRunReport_Click
    Dim MyDB As Database
    Dim qdf As QueryDef
    Dim i As Integer, strSQL As String
    Dim strWhere As String, strIN As String
    Dim flgAll As Boolean


    flgAll = False
    Set MyDB = CurrentDb


    strSQL = "SELECT [Tbl Movimientos Ingresos].CODTIT, [Tbl Movimientos Ingresos].NUMMIN, [Tbl Movimientos Ingresos].CODTMI, [Tbl Movimientos Ingresos].DISEMI, [Tbl Titulos].DENTIT, [Tbl Vendedores].DENVEN, [Tbl Asignaciones].CODTIT AS [Cod-TiT], [Tbl Vendedores].CASVEN, [Tbl Vendedores].SENSUS," & _
    "[Tbl Asignaciones].PERASI, [Tbl Asignaciones].TEMASI, [Tbl Asignaciones].RECASI, [Tbl Vendedores].CODVEN, [Tbl Movimientos Ingresos].CANMIN, [Tbl Movimientos Ingresos].SOLTRA" & _
    " FROM [Tbl Vendedores] INNER JOIN ([Tbl Titulos] INNER JOIN ([Tbl Movimientos Ingresos] INNER JOIN [Tbl Asignaciones] ON [Tbl Movimientos Ingresos].CODTIT = [Tbl Asignaciones].CODTIT) ON [Tbl Titulos].CODTIT = [Tbl Asignaciones].CODTIT) ON [Tbl Vendedores].CODVEN = [Tbl Asignaciones].CODVEN"


    'create the IN string by looping thru the listbox
    For i = 0 To lisURLs.ListCount - 1
    'If lisURLs.Selected(i) Then
    strIN = strIN & "'" & lisURLs.Column(0, i) & "',"
    ' End If
    Next i

    'create the WHERE string, stripping off the last comma of the IN string
    strWhere = " WHERE ((([Tbl Movimientos Ingresos].CODTMI)<>'R') AND (([Tbl Movimientos Ingresos].DISEMI)=False) AND (([Tbl Titulos].DENTIT) In (" & Left(strIN, Len(strIN) - 1) & "))" & " AND (([Tbl Vendedores].SENSUS)=False) AND (([Tbl Asignaciones].PERASI)>0))"
    strWhere = strWhere & " OR ((([Tbl Movimientos Ingresos].CODTMI)<>'R') AND (([Tbl Movimientos Ingresos].DISEMI)=False) AND (([Tbl Titulos].DENTIT) In (" & Left(strIN, Len(strIN) - 1) & "))" & " AND (([Tbl Vendedores].SENSUS)=False) AND (([Tbl Asignaciones].TEMASI)>0))"
    strWhere = strWhere & " ORDER BY [Tbl Titulos].DENTIT, [Tbl Vendedores].CASVEN"

    'if "All" was selected, don't add the WHERE condition
    If Not flgAll Then
    strSQL = strSQL & strWhere
    End If

    MyDB.QueryDefs.Delete "qryLocalDistribucionCasillero"
    Set qdf = MyDB.CreateQueryDef("qryLocalDistribucionCasillero ", strSQL)


    Dim Mensaje, Estilo, Título, respuesta, MiCadena


    Mensaje = "> Si < Para Imprimir > No < Para Visualizar" ' Define el mensaje.
    Estilo = vbYesNo + vbCritical + vbDefaultButton1 ' Define los botones.
    Título = "Forma de Salida" ' Define el título.


    respuesta = MsgBox(Mensaje, Estilo, Título)

    If respuesta = vbYes Then ' El usuario eligió el botón Sí.
    MiCadena = "Sí" ' Ejecuta una acción.
    DoCmd.OpenReport "Planilla Asignaciones por Titulo", acNormal

    Else ' El usuario eligió el botón No.
    MiCadena = "No" ' Ejecuta una acción.
    DoCmd.OpenReport "Planilla Asignaciones por Titulo", acPreview
    End If


    Exit_cmdRunReport_Click:
    Exit Sub

    Err_cmdRunReport_Click:
    If Err.Number = 3265 Then '*** if the error is the query is missing
    Resume Next '*** then skip the delete line and resume on the next line
    ElseIf Err.Number = 5 Then
    MsgBox "Debe hacer una selección"
    Resume Exit_cmdRunReport_Click
    Else
    MsgBox Err.Description '*** write out the error and exit the sub
    Resume Exit_cmdRunReport_Click

    End If

    End Sub
    Saludos
    Norberto

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •