Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

excel file question...


Guest

Recommended Posts

Posted

how do I past (.jpg) after a whole column... BUT NOT replace the text that is there... Just want to add it to it...

I did it once in the past and it worked but for the LIFE OF ME... LOL cant figure out how I did it...

I know that I did it under FORMAT CELL

But then every thing I try under that dont work... :'(

Posted

Suspect you need to to use a formula to add .jpg to the end of the values in a field then cut it and use paste special (values) to

finish off.

 

 

Say the product name is in cell A1, the formula is =A1&".jpg"

Need help installing add ons/contributions, cleaning a hacked site or a bespoke development, check my profile

 

Virus Threat Scanner

My Contributions

Basic install answers.

Click here for Contributions / Add Ons.

UK your site.

Site Move.

Basic design info.

 

For links mentioned in old answers that are no longer here follow this link Useful Threads.

 

If this post was useful, click the Like This button over there ======>>>>>.

Posted

Ok cool... Sry to be so lame on the question... But I am pasting in the field and it is not working... I am sure that you are being clear but where to i put (=A1&".jpg")

I actually have to do from A1 thru A1563

Posted

MAN... lol... I am sure that it is something simple that I am not quite understanding... JUST about there... If any one else could input just a hair more... thx so much for all of your help...

Posted

I wrote a small VBScript that will do it:

 

Set objExcel1 = CreateObject("Excel.Application")
Set objWorkbook = objExcel1.Workbooks.Open _
("C:\Documents and Settings\Owner\My Documents\screensaver\sheet2.xls")

objExcel1.Visible = True 

junk = inputbox("Enter the start row:")
intStartRow = CInt(junk)

junk = inputbox("Enter the end row:")
intEndRow = CInt(junk)

junk = inputbox("Enter the column (A=1, B=2, etc.):")
intCol = CInt(junk)

for i = intStartRow to intEndRow
 sts = objExcel1.Cells(i, intCol).Value
 if len(sts) then 
sts = Rtrim( sts ) & ".jpg"
objExcel1.Cells(i, intCol).Value = sts
 end if
 intRow = intRow + 1
next

Wscript.Echo "All done!!!"

Copy it into Notepad, and save it as junk.vbs

 

You need to alter the path/name to the Excel sheet you want to work on in this line:

 

Set objWorkbook = objExcel1.Workbooks.Open _
("C:\Documents and Settings\Owner\My Documents\screensaver\sheet2.xls")

 

<double-click> the junk.vbs file to run it.

 

It will ask you 3 questions:

 

1. The starting row to begin modifying.

2. The ending row to stop modifying.

3. The column the data is in (A=1, B-2, C=3, etc.)

 

So, if your data is in row 2 thru 50, in Column C, you'd answer the 3 prompts with:

 

2

50

3

 

It will skip blank cells.

If I suggest you edit any file(s) make a backup first - I'm not perfect and neither are you.

 

"Given enough impetus a parallelogramatically shaped projectile can egress a circular orifice."

- Me -

 

"Headers already sent" - The definitive help

 

"Cannot redeclare ..." - How to find/fix it

 

SSL Implementation Help

 

Like this post? "Like" it again over there >

Posted

very... sry... I have tried every thing... LOL... I have a macintosh... and can not get the script that you so nicely made for me to work...

 

Here is a bit of an example... When I got to format cells... it will for some reason add it to the 4 diget numbers but not the others...

and I need it to add it to all 15,000 numbers... Might you have a different idea what I could do... LOL... I know what I am going to hear next...

GO BUY A PC... LOL... sry cant do that yet...

 

9996.jpg

9997.jpg

9998.jpg

1000-20

1001-0108

1001-0207

Posted

I've tried everything in Excel I can think of, and I can't get it to append anything to any cells.

 

You could email me your Excel data and I could run the script and send it back.

 

Although, I'll have to warn you......

 

You sent the last Excel file (last) Sunday, and I didn't get it in my "inbox" until Wednesday afternoon!

 

Shoot, you could have driven here faster than that!

:lol:

If I suggest you edit any file(s) make a backup first - I'm not perfect and neither are you.

 

"Given enough impetus a parallelogramatically shaped projectile can egress a circular orifice."

- Me -

 

"Headers already sent" - The definitive help

 

"Cannot redeclare ..." - How to find/fix it

 

SSL Implementation Help

 

Like this post? "Like" it again over there >

Posted

Ok I just sent it... THX so much for offering to help me...

Posted

JUST sent NEW FILE... Please disregard last file...

Posted

WOW... Cool THX... What is there that I could of done to do what you did...

ONE SMALL Problem tho... That was the old file... SRY... I sent ya 2 of them... With in about 5 min apart...

The file starts out like this sir...

Item No.

56

1009

1010

1018

1019

1020

1021

1022

1031

1048

1049

 

Can I learn how u did this...

 

/bows B4 u

Posted

Thx so much... Got it back... PERF... I am going to get a PC laptop so that I can do this... Thanks so much for the help... ALL WILL BE UPLOADED 2night...

I could not of done it with out ya... BUT for now back to work... I work daytime for FedEx Ground... Driver...

 

Thx again

 

L8R

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...