Murilo Barbosa
Murilo Barbosa
CC#
Created by Murilo Barbosa on 11/28/2023 in #help
How to Dynamically add item to List?
I'll open another thread for this problem. I think its a different issue. Thank you for the help.
17 replies
CC#
Created by Murilo Barbosa on 11/28/2023 in #help
How to Dynamically add item to List?
But I'm getting FK violation
17 replies
CC#
Created by Murilo Barbosa on 11/28/2023 in #help
How to Dynamically add item to List?
SO, I think the Javascript and the controller method are now working
17 replies
CC#
Created by Murilo Barbosa on 11/28/2023 in #help
How to Dynamically add item to List?
'/api/movies' is the controller url right?
17 replies
CC#
Created by Murilo Barbosa on 11/28/2023 in #help
How to Dynamically add item to List?
Thanks, my Javascript skills are bad, but I'll try to figure this out. Also, how would I pass the listId argument? a hidden input would work I guess?
17 replies
CC#
Created by Murilo Barbosa on 11/28/2023 in #help
How to Dynamically add item to List?
The list is not necessarily a Type List. It is a View where I want to display the movies like a list.
17 replies
CC#
Created by Murilo Barbosa on 11/28/2023 in #help
How to Dynamically add item to List?
Yes, it is an .NET CORE MVC
17 replies
CC#
Created by Murilo Barbosa on 11/18/2023 in #help
Can't access object attributes using X.PagedList
Thanks
10 replies
CC#
Created by Murilo Barbosa on 11/18/2023 in #help
Can't access object attributes using X.PagedList
Hehe, all good now. Damn I need some time away. Been grinding
10 replies
CC#
Created by Murilo Barbosa on 11/18/2023 in #help
Can't access object attributes using X.PagedList
Just needed the await
10 replies
CC#
Created by Murilo Barbosa on 11/18/2023 in #help
Can't access object attributes using X.PagedList
Oh
10 replies
CC#
Created by Murilo Barbosa on 11/18/2023 in #help
Can't access object attributes using X.PagedList
But otherwise I can't use the ToPagedListAsync
10 replies
CC#
Created by Murilo Barbosa on 11/18/2023 in #help
Can't access object attributes using X.PagedList
I think it doesn't like the "movieResults = movies.results"
10 replies
CC#
Created by Murilo Barbosa on 11/18/2023 in #help
Can't access object attributes using X.PagedList
This is how I'm returning it from the Action: if (!String.IsNullOrEmpty(searchTerm)) { movies = await _tmdbMovieService.SearchMoviesAsync(searchTerm); } var movieResults = movies.results.ToPagedListAsync(pageNumber, pageSize); return View(movieResults);
10 replies
CC#
Created by Murilo Barbosa on 11/18/2023 in #help
Can't access object attributes using X.PagedList
I think you are right. But now I'm getting this error InvalidOperationException: The model item passed into the ViewDataDictionary is of type 'System.Threading.Tasks.Task1[X.PagedList.IPagedList1[Cinemanage.Models.TMDB.MovieSearchResult]]', but this ViewDataDictionary instance requires a model item of type 'X.PagedList.IPagedList`1[Cinemanage.Models.TMDB.MovieSearchResult]'.
10 replies
CC#
Created by Murilo Barbosa on 11/16/2023 in #help
NullReference from API JSON
Yes, it worked!
8 replies
CC#
Created by Murilo Barbosa on 11/16/2023 in #help
NullReference from API JSON
I'll try that
8 replies
CC#
Created by Murilo Barbosa on 11/16/2023 in #help
NullReference from API JSON
I'm using DataContractJsonSerializer
8 replies
CC#
Created by Murilo Barbosa on 11/16/2023 in #help
NullReference from API JSON
Then I need to use STJ for serialization
8 replies
CC#
Created by Murilo Barbosa on 11/11/2023 in #help
NullReference Exception
It actually helped. Thanks 🙂
11 replies