Posts by AoN

    Re: Pull Numbers From Alpanumerics

    Remove the hyphens from serial numbers, split the result into individual alphanumeric digits, and paste those digits in the original order while right justified on the ERO page.

    Also, I don't wish to sound rude of anything, but the serial number on the Data page was a demo serial I left there for use by programmers while experimenting with code. The ERO sheet was the exact form we use with everything EXCEPT the serial number location erased. My boss wouldn't let me post it otherwise. Attached to the document is also the macro that mikerickson posted for use.

    Re: Pull Numbers From Alpanumerics

    I don't think I was as clear as I had thought. ^^'

    Attached is a blank copy of what I have, nothing of the form except where the serial number will be going. It is in XLS format for PCs at my work without 2007 on them.

    Basically, the user will enter the serial number into a single cell on the data page. Some serial numbers will be 10 digits long not including hyphens. The ERO page, which is the blank form page, is set-up for only 10 digits in the serial number area. I would shorten it but the form will print onto a pre-made form that is manufactured with only 10 slots. As a result, for the 10 digit long serial numbers, or rather any length, the hyphens must be removed. In addition it must be right justified with the remaining field left empty.

    I've created the really long code from my original post to split up the serial number and insert it into the blocks right justified, but it doesn't compensate for hyphens, and if possible I'd like to shorten it.

    Thank you for the code snippet, but it didn't work. :S

    Thanks again for simply looking at it. I really appreciate this. ^^

    I am trying to create a data sheet to simplify the filling of corporate documents on our company computer systems. I have a working system, flawed, but working. What I want is to simplify it and correct some mistakes I made when I first made it. At the moment the priority is the field for our serial numbers. They vary from 1 to 10 digits in length with a alpha-numeric system. Some serial numbers even include hyphens, but the hyphens need to be removed for the forms. My system uses a modified form to allow for hyphens, but my boss wants them removed. ^^'

    I must apologize now, though. My boss knows I'm requesting help here and all, but he said I couldn't put the document up, sorry. :S

    Anyways, the serial number of an item is entered into the data sheet field and my macro breaks down the serial number piece by piece. On the form the there are ten blocks for each digit of the serial number and I have coded the macro to put one digit per box. The trick is that the serial number must be right aligned and any empty fields must stay empty. This is where my request comes into play. I have already programmed the macro to do everything required except remove hyphens. The problem is that it is a REALLY long macro using If Then End statements to to compensate for the varying lengths of a serial number. Is there anyway to simplify this task?

    Oh, I almost forgot, due to the rest of the form the fields the serial number is being put into are merged cells, I hope that doesn't make a difference. :S

    Thank you for simply taking a look at my request! ^^