Named formula will calculate automatically, see examples below
themeFill = If(_appTheme = "Dark",_appDarkFill, _appLightFill);
themeColor =If(_appTheme = "Dark", _appLightColor,_appDarkColor);
userScore = With({x:Sum(Filter(Posts, PostEmployeeID = _userID),Score)},If(x<0,0,x)) ;
Here instead of writing the condition again and again we written once for each control.
Now see below
selectedPost = First(Filter(Posts,PostID = _selectedItem.PostID));
avatar = LookUp(Avatars, ID = _userAvatarID1).Thumbnail.Small;
Whenver selectedPost is changed we gave the ;latest selectedPost object.
No comments:
Post a Comment