4
I need one column to show the following text: prxyz,(data1 here),0699,ABCD(data2 here),xxx
data1 is in column A and data2 is in column B.
the format of data1 needs to be 5 numbers (sometimes beginning with zeros). for data2, they need to type in data that's 9digits long and ends in a letter. if they enter 9 digits only, the letter needs to automatically be substituted with 0 (zero).
so for example i enter '123' in A1, '12345' in A2, '123456789' in B1 and '987654321Z' in B2, it needs to come out as:
| A | B | C
1| 00123 | 123456789 | prxyz,00123,0699,ABCD1234567890,xxx
2| 12345 | 987654321Z | prxyz,12345,0699,ABCD987654321Z,xxx
I've formatted col A out w custom format 00000 for it to always display 5digits. But I'm stuck on Column B and C.
This is what I've come up with but it's not correct: ="prxyz,"&A1&",0699,"&"ABCD"&B1&",xxx"
Please help? Ideas?
i learned that ="prxyz,"& TEXT(A1,"00000")&",0699,"& "ABCD"& LEFT(B1,9)&IF(ISNUMBER( VALUE(RIGHT(B1,1))),"0,xxx",( RIGHT(B1,1)&",xxx")) works too but yours is a lot simpler. :)
I think the last bit with the LEN and b1*10's pretty clever too.
Thanks a lot, Joel! – None – 2009-02-07T06:32:26.633