local CountSelTrack = reaper.CountSelectedTracks(0);
    if CountSelTrack == 0 then  return end;

S_track  =reaper.GetSelectedTrack(0, 0)
retval, i1 = reaper.GetUserInputs("EnterTrackNumber", 1, "","")    
if  retval == false then return end
Xtrack = reaper.CountTracks(0)    

    if (retval  == 0) or (tonumber(i1) > Xtrack)  then return end


  reaper.Undo_BeginBlock()
SS_track =             reaper.GetTrack(0,i1-1);
    reaper.CreateTrackSend( S_track,SS_track)
		reaper.SetMediaTrackInfo_Value(SS_track, "I_NCHAN", 4)
    reaper.BR_GetSetTrackSendInfo( SS_track, -1, 0, "I_DSTCHAN", 1, 2 )
  reaper.Undo_EndBlock("make new send to track and set its channel to 3/4", -1)