I have created a spreadsheet which has UK county names across row 1 in several columns.Running down each column, under the county name, are cells with individual city and town names.These need to be exported for use in a web design application for a drop-down menu. However, the application will only accept data for the drop-down in this format:Ascot, Binfield, Bracknell, Bray, etc. (i.e; as one long comma separated string)Is there any way I can output such a string from Excel? What would it be output to and would it be a simple matter of cut and paste from there?Cheers
click here may help.
Cheers VoG™I'm just having a run through your link now.
Sorry mate, I tried it but on running the macro I received a run-time error 1004, 'no cells were found.Any ideas?
Saving an Excel sheet as a CSV will output the contents Row by Row.Could your towns/cities be Across the page, and the Counties down column 1 ? then your csv text strings would be as you want them. Could be a problem though if you have more than 255 towns/cities in any county. Whats the last row number (corresponding to the largest number of towns/cities in a county) ? If less than 256 - select ALL your data, copy, then, in a new sheet "Paste Special, Transpose" will put the data the right way up to save the sheet as CSV in the format you need.eg. Oxfordshire, Banbury, Oxford, Kidlington, Abingdon,..... etc..I think later versions of excel allow more than 256 columns /=/ 256 towns/cities per county.... VoG will know..
That's done the trick, many thanks to both of you.Cheers
Glad you are sorted - I was occupied with visitors hence the quick link and lack of subsequent response.
Visitors eh? Who needs 'em?!Thanks for having a look though. Now all I need is some equally excellent talent to take a look at my post in Webdesign!Cheers
This thread is now locked and can not be replied to.
Galaxy Note 8 vs iPhone X
The secrets of creating gory VFX
How to update iOS on iPhone or iPad
WhatsApp : comment lire vos messages sans que l’expéditeur le sache
© Copyright 2017 IDG UK. All Rights Reserved.