Display a JPG image

supergilou Posted messages 71 Registration date   Status Membre Last intervention   -  
supergilou Posted messages 71 Registration date   Status Membre Last intervention   -

Hello,

How to display a JPG image conditionally, e.g., if the value of a cell is >1

Thank you in advance!


7 réponses

via38 Posted messages 91 Registration date   Status Membre Last intervention   24
 

Good evening

An example to adapt:

https://www.transfernow.net/dl/20250611k1bo0WAs

Best regards

Via


1
supergilou Posted messages 71 Registration date   Status Membre Last intervention  
 

Good evening!

For now, it's impossible for me to display the image; if I replace the image with text, it's fine, but the image shows 0, so either I'm not placing the image correctly in the box or I have a problem because the image is not in the same folder???????????

Thank you!

GILLES

0
supergilou Posted messages 71 Registration date   Status Membre Last intervention  
 

Hello VIA38

Thank you for your help, I was indeed able to achieve what I wanted thanks to your template, but I still have a problem!! Because if the image is on a sheet that is not in the same workbook, which I want, it doesn't work if the sheet containing the image is not open itself??????

Do you think it's possible to get around this condition?

Thanks in advance!

GILLES

0
Mike-31 Posted messages 18405 Registration date   Status Contributeur Last intervention   5 145
 

Hello,

there are several possibilities, but you need to tell us more.

Are your photos to appear in the same directory, or in another directory, or pasted in a tab of the same file with each photo in a cell?

Then you mention a cell, so a spreadsheet, but which one: Excel, Calc from Libre Office, etc...


See you later,
Mike-31

I am responsible for what I say, not for what you understand...

0
danielc0 Posted messages 2145 Registration date   Status Membre Last intervention   272
 

Hello everyone,

In Excel, it's easily doable with a simple macro. If that works for you, let me know.

Daniel


0
supergilou Posted messages 71 Registration date   Status Membre Last intervention  
 

OK, I'M OPEN TO A MACRO BUT I'LL NEED SOME HAND-HOLDING BECAUSE I DON'T KNOW ANYTHING ABOUT IT.

0
supergilou Posted messages 71 Registration date   Status Membre Last intervention  
 

Good evening!

Thank you very much for your response Mike-31

So I'll try to be clear and concise therefore:

In the Excel spreadsheet (2019) I created; a spreadsheet for property management with a multitude of files and thus pages with lots of links between them.

Everything works perfectly on the calculation side; but what I still need to achieve is to display an image (a file edited with Paint) which is saved as JPG.

So; the first condition (0 or 1) that I want to use is indeed in another file but is part of the same spreadsheet and the second condition (>1) is in the same sheet where I want to display this "image". If both conditions =0 or <2 no image; if both conditions met (= or >2) display the image.

I searched and found on the forum, but part of the explanation is not clear enough for me; (VBA????); and yes!!! I am not a programmer at all, I have no problem creating links between the different sheets of the different files but unfortunately I stop there!

If you can guide me to resolve this little issue, I would be very happy.

Thanks again to you

GILLES

0
danielc0 Posted messages 2145 Registration date   Status Membre Last intervention   272
 

Hello everyone,

We have a vocabulary issue that is preventing me from understanding what you want to do. A "folder" is a set of files located on the disk. It cannot be found in an Excel workbook. Do you mean:

...another sheet that is part of the same workbook

?

On another note, please share your workbook by removing any confidential data. To share it, click on:

https://www.swisstransfer.com/fr-fr

Upload your workbook, copy the generated link, and paste it in your reply.

Daniel

0
supergilou Posted messages 71 Registration date   Status Membre Last intervention   > danielc0 Posted messages 2145 Registration date   Status Membre Last intervention  
 

Hello and thank you again!

So, yes, the image is indeed on another sheet; that sheet is in another workbook, but it is still in the same folder!!!!

I'm sorry for this poor explanation, this really shows my level (Sniff Sniff)

So I've worked on the VIA38 solution; it works but it requires that the sheet containing the image be opened, (or located in the same workbook) if it is not open, it doesn't work??? I absolutely do not want to place the sheet containing the image in the workbook that contains the sheets where I want to display the image.

0
danielc0 Posted messages 2145 Registration date   Status Membre Last intervention   272 > supergilou Posted messages 71 Registration date   Status Membre Last intervention  
 

Hello everyone,

If the images are embedded in another Excel workbook, it will be extremely difficult, if not impossible - at least to my knowledge - to extract them, even with a macro.

If that's the case, I'll leave it to someone more knowledgeable than me. It would be much easier to have the independent JPG files.

Daniel

0
Mike-31 Posted messages 18405 Registration date   Status Contributeur Last intervention   5 145
 

Hi again,

It's indeed not very clear, download my example file where you will find explanations to display images using basic formulas without going through VBA

https://www.swisstransfer.com/d/535c305b-b139-40a3-87f6-2ce456b7675a

or even this fun possibility with a photo in a directory

https://www.swisstransfer.com/d/8c6cf206-e2fc-412f-9201-048b57be91a4


See you later
Mike-31

I am responsible for what I say, not for what you understand...

0
supergilou Posted messages 71 Registration date   Status Membre Last intervention  
 

Thank you very much! But unfortunately, I was not able to achieve the desired result??? It doesn't work with an image located in another folder, even if I place it on an Excel sheet.

Sniff sniff, bad luck for me!! I will try to find another system????????????

Thanks again everyone!!

0
supergilou Posted messages 71 Registration date   Status Membre Last intervention  
 

Thank you all!! I will close this post because I managed to accomplish what I wanted;

So once the document was created; since I had to convert it to PDF anyway, to send it, I used the signature feature of PDF and there I can insert my image!! which is located in another directory!!

Thanks again to all of you!!

GILLES

0