cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
Frequent Visitor

Address Block

I have a need to present on a screen an address block. 

 

Needed format

 

CustName

CustAddress1

CustAddress2

CustCity, CustSt CustZip

 

Any guidance is appreciated. 

1 ACCEPTED SOLUTION

Accepted Solutions
Highlighted
Super User I
Super User I

Re: Address Block

Hi @bmarcowka 

 

You could use the expression below to create a column in your table:

Address Block = 
VAR Name = Table1[CustName]
VAR Add1 = Table1[CustAddress1]
VAR Add2 = Table1[CustAddress2]
VAR City = Table1[CustCity]
VAR Zip = Table[CustZip]
VAR Result = 
Name & UNICHAR(10) & Add1 UNICHAR(10) & Add2 UNICHAR(10) & City & ", " & Zip
RETURN Result

 

If you need it as a measure, use this instead:

Address Block = 
VAR Name = SELECTEDVALUE( Table1[CustName] )
VAR Add1 = SELECTEDVALUE( Table1[CustAddress1] )
VAR Add2 = SELECTEDVALUE( Table1[CustAddress2] )
VAR City = SELECTEDVALUE( Table1[CustCity] )
VAR Zip = SELECTEDVALUE( Table[CustZip] )
VAR Result = 
Name & UNICHAR(10) & Add1 UNICHAR(10) & Add2 UNICHAR(10) & City & ", " & Zip
RETURN Result

 

Best regards,
Martyn


If I answered your question, please help others by accepting it as a solution.





Did I answer your question? Mark my post as a solution!

Proud to be a Super User!




View solution in original post

5 REPLIES 5
Highlighted
Super User I
Super User I

Re: Address Block

Hi @bmarcowka 

 

You could use the expression below to create a column in your table:

Address Block = 
VAR Name = Table1[CustName]
VAR Add1 = Table1[CustAddress1]
VAR Add2 = Table1[CustAddress2]
VAR City = Table1[CustCity]
VAR Zip = Table[CustZip]
VAR Result = 
Name & UNICHAR(10) & Add1 UNICHAR(10) & Add2 UNICHAR(10) & City & ", " & Zip
RETURN Result

 

If you need it as a measure, use this instead:

Address Block = 
VAR Name = SELECTEDVALUE( Table1[CustName] )
VAR Add1 = SELECTEDVALUE( Table1[CustAddress1] )
VAR Add2 = SELECTEDVALUE( Table1[CustAddress2] )
VAR City = SELECTEDVALUE( Table1[CustCity] )
VAR Zip = SELECTEDVALUE( Table[CustZip] )
VAR Result = 
Name & UNICHAR(10) & Add1 UNICHAR(10) & Add2 UNICHAR(10) & City & ", " & Zip
RETURN Result

 

Best regards,
Martyn


If I answered your question, please help others by accepting it as a solution.





Did I answer your question? Mark my post as a solution!

Proud to be a Super User!




View solution in original post

Highlighted
Frequent Visitor

Re: Address Block

Thank you @MartynRamsden. Getting message The sysntax for UNICHAR is incorrect.  

 
Address Block =
VAR CustName = OrgStops[CustName]
VAR Add1 = OrgStops[CustAddress]
VAR City = OrgStops[CustCity]
VAR State = OrgStops[CustState]VAR Zip = OrgStops[CustZip]
VAR Result =
CustName & UNICHAR(10) & Add1 UNICHAR(10) & City & ", " & Zip
RETURN Result
 
 
Highlighted
Super User I
Super User I

Re: Address Block

Hi @bmarcowka

You're missing an ampersand '&' between Add1 and UNICHAR(10)

Best regards,
Martyn




Did I answer your question? Mark my post as a solution!

Proud to be a Super User!




Highlighted
Super User I
Super User I

Re: Address Block

Sorry @bmarcowka

Just realised it was missing from my original example. Apologies!




Did I answer your question? Mark my post as a solution!

Proud to be a Super User!




Highlighted
Frequent Visitor

Re: Address Block

Worked perfectly.  Now to get it to be left justified.  

 

Thanks again @MartynRamsden 

Helpful resources

Announcements
Upcoming Events

Upcoming Events

Wondering what events you could join or have an event to promote yourself? Check out our Upcoming Events.

Upcoming Events

Community Summit North America – Join Online!

Join this community-driven Power Platform digital event for unbiased support and problem-solving.

Community Blog

Community Blog

Visit our Community Blog for articles, guides, and information created by fellow community members.

Top Solution Authors