Crop Text to Col Width

R

rrstudio2

I have just started to learn about using VB to make macros for excel
and would like a pointer. I need to export a space delimited text file
that has more than 256 chars per line which means I can't use excel to
export as .prn file. So the microsoft site has a macro for this at
http://support.microsoft.com/kb/q131554/. The problem is, that the
macro errors out if any columns have more text chars than the set col
width. So, I was wondering, how would you make a macro that would
simply crop the text in each column to the col width? There are abot
30 columns with all difference widths, and I would just like to cut the
text in them to the col width. For learning purposes, I would like to
see a seperate macro that would just do this, however it would also be
really cool to see this inserted into the microsoft macro.

Thanks for any ideas,
Andrew V. Romero
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top