Characters viewed/printed on a report

  • Thread starter Thread starter Ken Steinburg
  • Start date Start date
K

Ken Steinburg

I have added several alpha characters at the front of the parts numbers
(seperated by a dash) to help minimize duplicate parts numbers from several
suppliers contained in the same table. Is there an easy way in Access 2003
to hide these characters from showing on a report.
Thanks
 
Ken:

If you always add a specific number of alpha characters, i.e. all part
numbers always start with two alpha characters, then simply set your control
source for the report to be = Right([PartNumber], Len([PartNumber]) -2)
(You have to alias the name of the part number control on your report to
something like "PartNumberA" so you don't have a circular reference).

If there are variable length alpha situations or some have the characters
and some do not, then you've got a tougher problem, but its still solveable
with a little VBA, looping through the string part number as using the
IsAlpha function along with the Right and Left functions to strip out the
alpha characters. Then wrap your [PartNumber] in the control source for
the control in the function call for the function you write something like
= ParsePartNo([PartNumber])

HTH
 
Works great - Thanks
SA said:
Ken:

If you always add a specific number of alpha characters, i.e. all part
numbers always start with two alpha characters, then simply set your control
source for the report to be = Right([PartNumber], Len([PartNumber]) -2)
(You have to alias the name of the part number control on your report to
something like "PartNumberA" so you don't have a circular reference).

If there are variable length alpha situations or some have the characters
and some do not, then you've got a tougher problem, but its still solveable
with a little VBA, looping through the string part number as using the
IsAlpha function along with the Right and Left functions to strip out the
alpha characters. Then wrap your [PartNumber] in the control source for
the control in the function call for the function you write something like
= ParsePartNo([PartNumber])

HTH
--
Steve Arbaugh
ACG Soft
http://ourworld.compuserve.com/homepages/attac-cg

Ken Steinburg said:
I have added several alpha characters at the front of the parts numbers
(seperated by a dash) to help minimize duplicate parts numbers from several
suppliers contained in the same table. Is there an easy way in Access 2003
to hide these characters from showing on a report.
Thanks
 
Back
Top