Discover MakerZone

MATLAB and Simulink resources for Arduino, LEGO, and Raspberry Pi

Learn more

Discover what MATLAB® can do for your career.

Opportunities for recent engineering grads.

Apply Today

New to MATLAB?

using MultiSelect for selecting multiple selection of images

Asked by Elysi Cochin

Elysi Cochin (view profile)

on 1 Apr 2013

if i select images, i want to display those images.... and if i dont select any images.... i want to display the first 4 images from that folder..... how to do it sir.... please do reply....

0 Comments

Elysi Cochin

Elysi Cochin (view profile)

Products

No products are associated with this question.

1 Answer

Answer by Walter Roberson

Walter Roberson (view profile)

on 1 Apr 2013
Accepted answer

Use fullfile() instead of concatenating the pathname and filename.

You can detect no items selected by length(oldFileNames) being 0.

Getting the first 4 images in a folder can be done by using dir().

http://matlab.wikia.com/wiki/FAQ#How_can_I_process_a_sequence_of_files.3F

0 Comments

Walter Roberson

Walter Roberson (view profile)

Contact us