Forms :: Hyphen Not As Wild Card Character
May 18, 2013
I have a series of dates that I inherited from former DB. Some of the dates are Mon-Fri, Mon-Thu, Sun-Fri, etc. That is, there is a hyphen "-" in the middle of the text. I have an unbound control with an IIF statement using the LIKE condition, I just get an error. I tired the following to no avail. Using Access 2010.
IIF([Day1] Like "*-*", 5, 1)
IIF([Day1] like "-", 5, 1)
IIF ([Day1] like '-', 5, 1)
IIF ([Day1] like [-], 5, 1)
I've looked it up and the hyphen _ is used as a wild card character, but I need to include it just as a dash.
View Replies
ADVERTISEMENT
Aug 3, 2004
Is it possible to use a * (Wild Card) in a pop up box for a query?
I read the previous post about pop up boxes for quires and it worked worked great! I created one for my month field
My criteria in my search fieled is a follows:
05-May
06-June
07-July
08-August
etc...
As you can see someone would have to type a 08-August to get the results for August, can a wild card be used? Example 08* would return all of 08-August data. I tried it but it wouldn't return any data.
Any help would be appreciated.
Thanks, Scott
View 6 Replies
View Related
Jan 28, 2008
I am using a criteria entry form as the source of parameters for a select query, and I am using IIF statements in the query so that if the user does not want to specify for that particular field, the search still works based on the other parameters specified. Therefore the statement I am using is;
IIf([Forms]![Criteria Form]![Customer Account] Is Not Null,[Forms]![Criteria Form]![Customer Account],[Data]![Customer Account]).
This works.
However for some of the criteria I want to also use wild cards, so that the user can enter just part of the data, and the relevant records will be returned. I understand that wild cards cannot be embedded into the IIF statement above.
I have tried many methods, and trawled the web for ideas, but I cannot get this to work. I either want the user to enter the wild card themselves ie "100*" returning records starting with "100", or for the query to append the wild card itself.
Can someone help please?
View 7 Replies
View Related
Feb 27, 2008
How would I make a query find a person like this:
Inputted Data: Smit
Outputted Data: Smith, Smithy etc..
The formula I have entered in the criteria of my query is:
Like [Enter the person's last name]
With this formula, if I type Smith, then the data that comes out is Smith. But if I type in smit or smi, Smith doesnt come out.
Thanks.
View 4 Replies
View Related
Jun 22, 2005
Ive read loads of posts about Wildcard searches but am unable to find the answer to my problem. In one of my boxes on my search form the user places in the search criteria value, this can be from A1 - A16 all the way to G16. At the moment i'm using this as my seasrch query:
[Forms]![Search]![BoxNo]
So if I put in C1 then I get all the C1's, great. If I want to wildcard then I put in Like "*" & [Forms]![Search]![BoxNo] &"*", and again it works, this time it call enything with C1 in it i.e C13.
How can I adjust my query to do both, sometimes I only want the exact match othertimes I want to wildcard :confused:
View 4 Replies
View Related
Nov 3, 2007
Hi all,
I need a little help with a wild card issue, Ive looked and looked and cant spot whats wrong.
I have two forms "Requisitioner" & "Engineers", each form has a subform.
These are basic search forms (unbound) that find related records in the subforms. The work is done in the query of the subform and then the form is refreshed. I have used this approach many many times without issue until now.
If the engineers form is opened "G*" is entered into the text box then all the entries beginning with "G" are found in the subform.
If the "*" is then removed from the text box leaving "G" no results are found in the subform, (Working Correctly)
Now if the "*" is added again "G*" then the subform shows all the entries beginning with "G"
Everything is good with the Engineers Form, If the same steps are made on the Requisitioners form after adding the "*" again no records are displayed.
I could change the way this works by doing a recordset find but i really want to know why this is working on one form but not on another.
I would appreciate any help with this.
Garry
View 1 Replies
View Related
Jun 26, 2014
I want to prompt the user to enter a merchant name, but want the results to return close matches.I know how to use the wildcard in the Criteria field of the query, but I want to use brackets.I know that "*Southwest*" Will return Southwest Airlines.So I tried *[Southwest Airlines]* and it treats the criteria like a text string.
View 1 Replies
View Related
Aug 30, 2006
I have a search box and it looks up project id number.
the orginal code works but filters anything with that particular number.
I like to adjust the filter to equal to the number enter.
ex,, I enter 22 , i get records with 622, 223, etc
I want it to be only 22
I can't seem to figure this out.. here's te code
Private Sub txtSearchString_AfterUpdate()
' Find the record that matches the control.
Dim rs As Object
LSearchString = txtSearchString
'Filter results based on search string
LSQL = "select * from [Projects - Active]"
LSQL = LSQL & " where ID LIKE '*" & LSearchString & "*'"
Form_frmSearch_sub.RecordSource = LSQL
lblTitle.Caption = "Project ID: Filtered by '" & LSearchString & "'"
'Clear search string
txtSearchString = ""
End Sub
View 6 Replies
View Related
Apr 21, 2015
How may I write a criteria in the query where I can pull records with date/time data type (01/31/15 1:30:23 PM) based on today's date?
Example using today's date (4/21/15):
Date()= 4/21/15
The query will pull these records:
ABC 4/21/15 9:14:40 AM
DEF 4/21/15 10:50:02 AM
GHI 4/21/15 2:32:35 PM
etc.
The time does not matter as long as the date is 4/21/15.
I have tried using these formulas:
=Date() & *
=Date(Now)
but these are no success.
View 3 Replies
View Related
Jul 12, 2005
Hello all,
I have always been wondering why this happens, and now I have a problem with it.
When I export a Table/Query from Access to Excel (be it with Right CLick -> Export...or TransferSpreadsheet) there is an apostrophe character (') appended to the front of some/each cell in Excel. You cannot see it immediately, but when you click on the cell, there is this character. WHY? Does anyone else have experience in this? :confused:
Thanks in advance.
View 3 Replies
View Related
Mar 25, 2014
GOAL - I would like to have one text box where I enter a sentence
txtKeywords: Access Is For Smart People Smarter Than I
I would like to create a button when clicked moves txtKeywords into another textbox [txtKeywordscombined] field and removes the spaces between the words and adds hyphens
txtKeywordscombined: Access-Is-For-Smart-People-Smarter-Than-I
Would I use the 'Replace' command in even procedures to do this? Another way? Example?
View 1 Replies
View Related
Feb 7, 2014
I want to have a report card where I can have attendance embedded in for each students and also the highest score for each class each session.
View 4 Replies
View Related
Feb 10, 2006
Can someone give me an easy way to put a hyphen between two numbers, such as with wins and losses of teams? I want it to come out 5-3, not 5 3.
I tried entering a text box with no success.
View 3 Replies
View Related
Mar 18, 2006
I cant get the comment feature to work in SQL. If I type the following...
Code:SELECT * FROM tblMembers WHERE OrderNo='xxxx' -- Finds the member
An error message is returned saying 'Syntax Error (Missing Operator)'. What am I doing wrong?
View 6 Replies
View Related
Jun 9, 2013
I have a table field that contains a lot of part numbers in different format. One could be with hyphen while others are without hyphen.
record#1 : 4535-300-34567
Record#2: 453530034567
Record#3: 4535-301-56721
In this case record# 1 & 2 are same part number only difference is hyphen.
I want to set my query parameter [Enter part number] such a way, when some one enter 453530034567 it should pull both the record (record#1 & 2).
View 5 Replies
View Related
Dec 14, 2005
Hi,
I'm trying to search a field which has both names and numbers in it.
For purely text entries the wildcard search works just fine.... like this:
Like "*" & [What is Last Name?] & "*"
I can type in "Smi" and get all of the Smith, Smiths, etc.
However, when I try to use this for entries which include numbers (123), which should return "Smi123" I don't get any results at all.
Any suggestions? I can put in the SMI123 as straight text in the criteria box, and will get the appropriate record.... so I know it is there!
Thanks .....
Gordon
View 4 Replies
View Related
May 4, 2015
I have been doing an exercise to split the data from the list of the information into column A, B & C. Unfortunately the data value that i have consist of several set of data format therefore it create an issue for me to separate the information in Access 2010 easily.
eg.
Original Data Field
FLRY-B-0.75-L-GY
FLRY-4.0-V-R
VTAC-GY 19X20
COT-F2-5-DL
Actual Data To Populate Into Column A, B & C should be the following :
A
FLRY-B
FRY
VTAC-GY
COT-F2
B
0.75
4
19X20
5
C
L-GY
V-R
(No data captured for this column)
DL
View 14 Replies
View Related
Oct 23, 2013
how can i set a character as hyperlink in access form label...like GO ,in this G use as hyperlink for run a query
View 2 Replies
View Related
Feb 17, 2015
I started off with a blank form and added a command button, three labels and a text box. None of these are bound to anything.
The sole purpose of this form is to show the progress of a VB script I've written that retrieves all the table names and the number of records contained in each. This information is also exported to Excel.
Everything works great apart from the log I'm producing inside the text box. This log is just a replica of what is being exported to Excel. Once the log reaches a length of 1,837 characters, it fails to have anything else added to it. The code below is where I have an error returned.
Code:
Me.LogList1.Text = Me.LogList1.Text & vbCrLf & tdf.Name & "|" & intRecCount
The error I receive is "Run-time error '2176': The setting for this property is too long.". From what I've read elsewhere though, an unbound text box is meant to have a character limit of a good few thousand. Around 60,000 from what I remember.
I did try a few other options such as using a label or a listbox but they weren't great. The label doesn't support a scroll bar and if the text goes past the size of the label it doesn't scroll down by default. A list box worked but I want the user to be able to copy the text after in-case the Excel report doesn't work for whatever reason.
I could possibly setup a table with a single field set to 'memo' and bound the text box to that. I don't know if that works though as I don't want to have to create an extra table. This form is to be used across other databases when required and this solution would add an unnecessary table to the list (which I could code out) and also means the table has to be exported to the other database along with the form.
Why my text box is limited to around 1,837 characters?
View 4 Replies
View Related
Feb 15, 2013
I'm struggling with a validation rule that almost works but not quite.
I want to restrict the values in a feild by characters between 0-9, A-Z, _ and -
Using the following string works for all except the hyphen, which I assume is because it's an operator:
Is Null OR Not Like "*[!((a-z) or (0-9) or (_) or (-))]*"
Is there something I can do to make it recognise the - as text?
View 2 Replies
View Related
May 3, 2013
I've built a macro with wildcards that replaces multiple spaces of varying numbers after perods, commas, and before and after numbers. Now I want to add a search for the same before and after en dashes and hyphens. (Pretty soon I'll have Word streamling a lot of documents I edit!)
View 1 Replies
View Related
Nov 26, 2014
Is it possible to have a text box momentarily show the character that is input, and then hide it with a dot (or similar)?
This is for password input so that users can see momentarily, but others won't be able to.
View 4 Replies
View Related
May 4, 2014
I am trying to filter data in a table using vba where I have a split form setup. My goal is to filter data where the user can input a character such as "a" for the "FirstName" field and have results from the table filtered with persons first name that starts with "a". Here is my code so far one of the text boxes.
Private Sub txtFirstName_DblClick(Cancel As Integer)
If Me.Filter = "" Then
'Compares the values that begin with the input values in txtFirstName
'text box from the table field name FirstName
Me.Filter = FirstName & " LIKE '" & txtFirstName & "*'"
[Code] .....
I get a error in the else statement and please note that I am linking this form to an sql server so I can not delete or modify existing data in the table.
View 1 Replies
View Related
Dec 21, 2005
Sorry All,
I have a simple question, how can I tell if my laptop has a wireless network in it. Thanks.
View 1 Replies
View Related
Jun 4, 2006
Hi,
I'm in a a lot of trouble. My graphics card has stopped functioning, leaving me with a perfectly good computer that I cannot use.
In order to retrieve the information from the harddisk, I got a cable between this computer and another one.
This is my plan:
When the "blind" computer is started, I will enter the cmd. From there I would like to be able to "share" one of my folders on the small network (ie the two computers). Is there a DOS command for this?
second question:
If I have VNC server installed, will I be able to see the desktop from another computer allthough I can't see it on the blind computer? Does that information go through the graphics card before it is sent over the internet, or after it has arrived in the VNC viewer computer?
Fuga.
View 1 Replies
View Related
Apr 7, 2008
Looking at creating a database that looks up records based on a number from a magnetic card. Has anyone ever come across any code that will pull the info from the serial port? I have been looking for 2 days and not able to find anything. I have the card reader but do not have any software to get the info from the serial port and my limted coding does not even come close to what I need. Any help or a push in the right direction would be greatly appreciated.
Thanks,
Matthew
View 4 Replies
View Related