Solved

referencing integers with condition

Posted on 2007-03-29
7
223 Views
Last Modified: 2007-03-29
How could I reference a colon followed by a space and then an integer, such as    : 23    ?
I need to reference all integers that are preceded by a space and a colon.  This is for another vba app.  

0
Comment
Question by:zubin6220
  • 2
  • 2
  • 2
  • +1
7 Comments
 
LVL 142

Expert Comment

by:Guy Hengel [angelIII / a3]
ID: 18815004
in a query?
in VBA?
could there be something after the integer? if yes, what?
0
 
LVL 39

Expert Comment

by:stevbe
ID: 18815020
what do you mean by reference?
0
 
LVL 9

Expert Comment

by:TheSloath
ID: 18815084
WHERE [YourField] LIKE "* :*"
0
Complete VMware vSphere® ESX(i) & Hyper-V Backup

Capture your entire system, including the host, with patented disk imaging integrated with VMware VADP / Microsoft VSS and RCT. RTOs is as low as 15 seconds with Acronis Active Restore™. You can enjoy unlimited P2V/V2V migrations from any source (even from a different hypervisor)

 

Author Comment

by:zubin6220
ID: 18815253
I have a visio app in which I need to format all numbers on a page that are prefixed with
colon and space.  I will have to look elsewhere (visio) to get the objects etc, but wanted to know from a vba perspective how to reference.  vba is vba?  Sorry if I shouldn't have posted here.  So to put it in 'access' perspective, say I had a text field with values of:
34
: 34
023, etc.
How could I pull out just the numbers prefixed with : space number?  LIKE "* :*" doesn't do it.
0
 
LVL 9

Accepted Solution

by:
TheSloath earned 275 total points
ID: 18815362
Sorry, in your original question you indicated 'preceded by a space and a colon', if you ra re looking for a 'colon then a space' then:

LIKE "*: *"
0
 
LVL 39

Assisted Solution

by:stevbe
stevbe earned 125 total points
ID: 18815498
assuming the object that contains the data is called objNum ...

you could loop through and remove all of the instances of ": "

For Each objNum in objNums
    objNum = Replace(objNum, ": ", "")
Next
0
 

Author Comment

by:zubin6220
ID: 18815604
I plugged LIKE "*: *" with a query and it worked fine.  Thanks
0

Featured Post

Complete VMware vSphere® ESX(i) & Hyper-V Backup

Capture your entire system, including the host, with patented disk imaging integrated with VMware VADP / Microsoft VSS and RCT. RTOs is as low as 15 seconds with Acronis Active Restore™. You can enjoy unlimited P2V/V2V migrations from any source (even from a different hypervisor)

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Most if not all databases provide tools to filter data; even simple mail-merge programs might offer basic filtering capabilities. This is so important that, although Access has many built-in features to help the user in this task, developers often n…
A simple tool to export all objects of two Access files as text and compare it with Meld, a free diff tool.
Basics of query design. Shows you how to construct a simple query by adding tables, perform joins, defining output columns, perform sorting, and apply criteria.
Using Microsoft Access, learn some simple rules for how to construct tables in a relational database. Split up all multi-value fields into single values: Split up fields that belong to other things into separate tables: Make sure that all record…

896 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

12 Experts available now in Live!

Get 1:1 Help Now