function DM_loadduneline(handles)

global data_path
global last_data_path
global data

if isempty(last_data_path)|~ischar(last_data_path)
   init_data_path=data_path;
else
   init_data_path=last_data_path;
end

%Get filename
[fname,pname]=uigetfile([init_data_path '*.txt'],...
       'Load duneline txt file');

%Error message if no data selected
if isnumeric(fname)|isnumeric(pname)
   %errordlg('No file selected','No File')
   return
else
    [hdr,points] = hdrload([pname fname]);
    points_xb = rotate_points(points,data.alfa,[data.xori data.yori],'degs');
    data.duneline = points_xb(:,1:2);
    h = plot(handles.nodune,data.duneline(:,1),data.duneline(:,2),'b-o');
    data.handles.duneline = h;
end
    