G
Guest
Hello---HelpPlease!
I created a simple Access database to store records of problems (named
Requests) and each problems answers (named Solutions) .
I have designed this database so each that Request and Solution is
associated with an appropriate Topic when recorded which I then use to
conduct searches by Topic to quickly access relevent records
The database comprises of;
tblRequests
RequestID (PK AutoNumber)
TopicID (FK) One in one to many relationship
Topic (Text lookup to tblTopics)
Request (Text)
Solution (Text)
tblTopics
TopicID (PK AutoNumber) Many part of one to many relationship
Topic (Text)
frmRequests
cboTopics
txtRequests
txtSolutions
The cboTopics is working to display all records in txtRequests----
HOWEVER..............
It only fills in part of the records in txtSolutions field
Eg: There are multiple records under the Topic Printer and when I choose
Printer from the cboTopics on my frmRequests; multiple records are displayed
in txtRequests but only one record is displayed in txtSolution
My code
Option Compare Database
Option Explicit
Private Sub cboRequest_Change()
With Me.lstSolution
.Requery
If .ListCount > 0 Then
.SetFocus
.Selected(0) = True
End If
End With
End Sub
Private Sub cboTopic_Change()
With Me.lstRequest
.Requery
If .ListCount > 0 Then
.SetFocus
.Selected(0) = True
End If
End With
With Me.lstSolution
.Requery
If .ListCount > 0 Then
.SetFocus
.Selected(0) = True
End If
End With
End Sub
Private Sub cmd_Close_Click()
On Error GoTo Err_cmd_Close_Click
DoCmd.Close
Exit_cmd_Close_Click:
Exit Sub
Err_cmd_Close_Click:
MsgBox Err.Description
Resume Exit_cmd_Close_Click
End Sub
Any suggestion welcome
Cheers Ohbe
PS: How do I create Folder type tabs to forms to improve a dayabases
navigation
I created a simple Access database to store records of problems (named
Requests) and each problems answers (named Solutions) .
I have designed this database so each that Request and Solution is
associated with an appropriate Topic when recorded which I then use to
conduct searches by Topic to quickly access relevent records
The database comprises of;
tblRequests
RequestID (PK AutoNumber)
TopicID (FK) One in one to many relationship
Topic (Text lookup to tblTopics)
Request (Text)
Solution (Text)
tblTopics
TopicID (PK AutoNumber) Many part of one to many relationship
Topic (Text)
frmRequests
cboTopics
txtRequests
txtSolutions
The cboTopics is working to display all records in txtRequests----
HOWEVER..............
It only fills in part of the records in txtSolutions field
Eg: There are multiple records under the Topic Printer and when I choose
Printer from the cboTopics on my frmRequests; multiple records are displayed
in txtRequests but only one record is displayed in txtSolution
My code
Option Compare Database
Option Explicit
Private Sub cboRequest_Change()
With Me.lstSolution
.Requery
If .ListCount > 0 Then
.SetFocus
.Selected(0) = True
End If
End With
End Sub
Private Sub cboTopic_Change()
With Me.lstRequest
.Requery
If .ListCount > 0 Then
.SetFocus
.Selected(0) = True
End If
End With
With Me.lstSolution
.Requery
If .ListCount > 0 Then
.SetFocus
.Selected(0) = True
End If
End With
End Sub
Private Sub cmd_Close_Click()
On Error GoTo Err_cmd_Close_Click
DoCmd.Close
Exit_cmd_Close_Click:
Exit Sub
Err_cmd_Close_Click:
MsgBox Err.Description
Resume Exit_cmd_Close_Click
End Sub
Any suggestion welcome
Cheers Ohbe
PS: How do I create Folder type tabs to forms to improve a dayabases
navigation