Hi
I have created an account on AWS, as well as a DynamoDB. I have also set the permissions. Basically, I have followed this article to a T docs.aws.amazon.com/mobile/sdkforxamarin/developerguide/getting-started-store-retrieve-data.html
But when I try to save a value into the table I get this error:
"The type initializer for 'Amazon.Util.CryptoUtilFactory' threw an exception."
As you can see the error itself is very vague.
Here is my code:
var Cred = new CognitoAWSCredentials("MY_IDENTITY_ID", RegionEndpoint.USWest2);
var dynamoClient = new AmazonDynamoDBClient(Cred, RegionEndpoint.USWest2);
var dynamoContext = new DynamoDBContext(dynamoClient);
Nearby_Favorites newFav = new Nearby_Favorites()
{
Id = 1,
PlaceName = Details.result.name,
PlaceId = Place.place_id,
Latitude = Place.geometry.location.lat.ToString(),
Longitude = Place.geometry.location.lng.ToString(),
Vicinity = Place.vicinity
};
await dynamoContext.SaveAsync(newFav);
Any help on this would be greatly appreciated.
Thank you.
Answers
did you find any solution for this?
No, I have not. I ditched AWS momentarily. Working on something else. But will get back to it.
your error is really strange. after I wrote you, I achieved successful inserts and updates. my code looks like yours. your problem might be on the server side. maybe you want to create your DB again. But in general, I didnt like aws, when you have error or dont understand something, you cant get enough help, you have to pay for support starting from 29$ which many devs will not be willing to pay. their .net/xamarin sdk is also quite incomplete and i dont think that they care about it.
Hi, i know is a bit late, but here is my code that work fine (actually i'm using the aws api gateway and working with json)
Hope this work for you
edit: and i forgot tha you need to make an class for your table, like this:
I followed the instructions from AWS, to upload the DynamoDB table. Below is my code which should be working but it is not. There are no errors but the table is not getting updated.
using Android.App;
using Android.Widget;
using Android.OS;
using Amazon;
using Amazon.DynamoDBv2;
using Amazon.DynamoDBv2.DocumentModel;
using Amazon.DynamoDBv2.DataModel;
using Amazon.DynamoDBv2.Model;
using Amazon.CognitoIdentity;
namespace AWS_TESTING
{
}
Hi, I am trying to upload data on DynamoDB table. Below is my code. It is running fine without any errors but somehow the table is not getting updated. I followed the AWS tutorial in doing so.