Enhanced Switchboard

WhizzkidWallace

Registered User.
Local time
Today, 03:31
Joined
Jan 10, 2005
Messages
49
I wonder if anyone can help me puzzle this one out. I have nearly 200 items in my switchboards table, and a lot more to be created yet. I have added a field to the switchboard table with a memo type, and put a description of what the item does in it. For example the Item Text might be 'Monthly Sales Report', and the memo field might say 'Prints a Monthly Sales Report'.

I want to put a button on the Switchboard so a user could click it, and search the memo field above for a word, then click a button to jump to that Switchboard.

So, I want to print a sales report, I search for 'Sales Report', and it finds the above item and I can click to quickly go to it.

Any ideas?

Thanks
 
Coding I think for this

Within the form design, add a txt box call it txtExecuteReport
add a button called, cmdExecuteReport

Add code to run on user click

Code:
Private Sub cmdExecuteReport_OnClick()
Dim stExecuteReport As String

If IsNull(Me.txtExecuteReport.Value) Then
Msgbox "Please enter a search string."
Exit Sub
Else
stExecuteReport = Me.txtExecuteReport.Value
End If

Select Case stExecuteReport
'You will have to add more as desired like below
'Disadvantage that user entry needs to be EXACT
Case "Sales Report"
DoCmd.OpenReport "Sales Report"
End Select
Exit Sub

You will have to add your own error handling to inform the user when they have entered wrong text etc

Hope this helps
 
I can see where you are going with that, but thats not what I want. I want to be able to go directly to a switchboard by entering some search text. It may be to run a report, it may be to do something else. For another example, I have one option on a switchboard to 'Enter New Sales Invoice'. I want the user to be able to search maybe for 'Sales', and the system to find all records containing sales and say....'Enter New Sales Invoice'...Execute? The user then clicks YES or NO, and if YES, go directly to that switchboard.

It is just to save them wondering where within the menu structure the item can be found...is it in Sales, or Surveying...or Accounts etc.

Thanks

I think I can do it by maybe running throughj a recordset using the search text and some wildcards, and having a Response = question with the text in it. Then maybe when they click YES, I could apply the necessary filer to the Switchboard using the SwitchboardID and ItemNumber fields...maybe...anyone??
 

Users who are viewing this thread

Back
Top Bottom