Hi @dylandavis09,
I have pretty much created what I could see on your screen. But I have made it to what I think is more logical.
What I have Done:
I have three tables called Courses, Students, StudentCourses



In my app. Currently there is no courses for student 2 (ST002 Logged in user)

After creating some test data. As you can see only the courses for the student that is logged in can be seen in the gallery (Remove Courses gallery)

Making your changes.

Updating Changes. This clears the galleries on the right hand side and also moves the name of the course from CourseAdd to CourseDrop column.

-----------------------------------------------------------------------
This is the Code focusing on the Student Course galleries
Remove Course :
Filter(StudentCourses, (StudentName = LookUp(Students, StudentName = User().FullName).StudentName) && !IsBlank(CourseAdd))
Review: Drop Course: colDropCourse
Add Courses: Courses (The courses table)
Review: Add Course: colAddCourse
For the add icon: Switch the collection name for the Add courses gallery
Collect(colDropCourse, {CN: ThisItem.CourseAdd, CC: ThisItem.CourseCode})
For the minus icon: Also switch the collection name
Remove(colDropCourse, ThisItem)
The submit button:
ForAll(colAddCourse,
Patch(StudentCourses,
Defaults(StudentCourses),
{
StudentCode: LookUp(Students, StudentName = User().FullName),
StudentName: User().FullName,
CourseAdd: CN,
CourseCode: CC
}
)
);
Clear(colAddCourse);
ForAll(colDropCourse,
Patch(StudentCourses,
LookUp(StudentCourses, StudentName = User().FullName && CourseCode in colDropCourse.CC),
{
StudentCode: LookUp(Students, StudentName = User().FullName),
StudentName: User().FullName,
CourseDrop: CN,
CourseCode: CC,
CourseAdd: ""
}
)
);
Clear(colDropCourse);
I hope this helps and you can follow what I did.
Please tick Accept as solution if the answer is useful.
Thanks,
@AARON_C