private void RegistrarCommands() { CameraCommand = new Command(() => { MessagingCenter.Send <AtendimentoFoto>(this.AtendimentoFoto, "Camera"); }); AlbumCommand = new Command(() => { MessagingCenter.Send <AtendimentoFoto>(this.AtendimentoFoto, "Album"); }); GravarFotoCommand = new Command(async() => { AtendimentoFoto.Atendimento = AtendimentoFoto.Atendimento; AtendimentoFoto.AtendimentoID = AtendimentoFoto.Atendimento.AtendimentoID; var dal = new AtendimentoFotoDAL(AtendimentoFoto.Atendimento, DependencyService.Get <IDBPath>().GetDbPath()); await dal.UpdateAsync(AtendimentoFoto, AtendimentoFoto.AtendimentoFotoID); MessagingCenter.Send <string>("Atualização realizada com sucesso.", "InformacaoCRUD"); MessagingCenter.Send <string>("consultar.png", "AtualizarFoto"); AtendimentoFoto = new AtendimentoFoto(); OnPropertyChanged(nameof(Observacoes)); }, () => { return(!string.IsNullOrEmpty(Observacoes) && !string.IsNullOrEmpty(CaminhoFoto)); }); }