#FireCoder

1 messages · Page 1 of 1 (latest)

warm egretBOT
wanton tulip
#

Hi there

frail pasture
#

Hello

wanton tulip
#

What language are you using? And can you provide your full update Customer request code?

frail pasture
#

C#

#

I've updated it since my post.

wanton tulip
#

Hmm that looks fine. Are you seeing an error or just seeing null?

frail pasture
#

Well, right now I cannot get the red squiggles to go away. customer.StreetAddress is a string.

wanton tulip
#

Oh I thought you said you changed that. What does it indicate when you hover over the red?

frail pasture
#

I originally had: updCustInfo.Address.Line1 = customer.StreetAddress; That was giving me a null ref.

wanton tulip
#

Mmmk one sec — I'm not super familiar with .NET so gimme a moment

frail pasture
#

sure

wanton tulip
#

So instead of dictionary try AddressOptions Address { get; set; }

frail pasture
#

Got it I think, based off your input.

#

var updCustOptions = new CustomerUpdateOptions
{
Address = new AddressOptions { City = customer.City },
};

wanton tulip
#

Nice

frail pasture
#

Yeah, it was a bit confusing at first. Thank you for your assistance.

wanton tulip
#

Glad you figured it out!