function GetLayerNoByName(ALayerName: string): integer;



Description:


    Get  layer's No and it's name is ALayerName, if do not match ALayerName, return -1;


Sample:


procedure Form1.Button1Click(Send:TObject)

begin

with MyCAD1 do

 ShowMessage(' The Layers name is:'+'MyName' +' layer No is: '+Inttostr(GetLayerNoByName('MyName')));

end;


See Also:

GetLayerIdByNo

GetLayerNameById

GetLayerNobyId