This is my code:
classDefault={'','','','',''};
fieldNames= {'Class Number','Class Name'};
title='Enter Class Information';
numlines=1;
y =inputdlg(fieldNames,title,numlines,classDefault);
it shows:
I want to change the color of the field name, like this:
How can I do this?
You can use the tex
interpreter:
function q65234922()
classDefault = {'','','','',''};
fieldNames = {'\color{red}Class Number','Class Name'}; % Change 1
title = 'Enter Class Information';
numlines = 1;
opts = struct('Interpreter','tex'); % Change 2
y = inputdlg(fieldNames,title,numlines,classDefault,opts); % Change 3