web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / ShowColumns code or bug?
Power Apps
Unanswered

ShowColumns code or bug?

(1) ShareShare
ReportReport
Posted on by

Hi Team,

 

NICE Day!

 

Would like to know or seek asssitance regarding the error I encountered in ShowColumns? or maybe it is some sort of a bug?

I encoded and saved ShowColumns with it's actual Column Name on sharepoint lists on which you will see on the URL.

I.e 

Field=Title.

Reference was the screen shot below on PowerApps I build. I will save the changes I've made and published it to the live App. Unfortunately, when I edit the app again, the ShowColumns code will change the data from I previously encoded from,

ACCOUNTNAME to 'ACCOUNT NAME'. Then my export button will not work due to this. To fix this, I need to copy again the reference data I saved to notepad and paste it again to the ShowColumn code in order to work again then published it again. Is this some sort of a bug? 

BTW, I use ShowColumns on my export to CSV function which parsing JSON.

 

 

Hoping someone can clear this out. It's just very tedious on for the developer to copy and paste from time to time when editing the app.

 

nmlsanmiguel_0-1720152907323.png

 

 

Categories:
I have the same question (0)
  • Michael E. Gernaey Profile Picture
    53,479 Super User 2025 Season 2 on at

    Hi @nmlsanmiguel 

     

    Let's start over and not worry about what it makes a pain for you, that just gets in the way of resolving and sometimes confuses us.

     

    Lets restate the issue and have you share the code for that since I dont see it. You say you have an error, but I don't see any errors. Can you share the error you are talking about. That or you are saying there is some "weird situation" which isnt the same as an error.

     

    Again, being clear helps us help you faster 🙂

     

    What does this mean

    I encoded and saved ShowColumns with it's actual Column Name on sharepoint lists on which you will see on the URL.

    What url you didnt share a Url

    Are you saying you created a Collection based on using ShowColumns and then encryped it???

     

    I am not sure what information matters and relates to the Error. 

     

    You keep speaking about some ShowColumns code... Where exactly is that in your post?


    If I have helped you, I would really appreciate if you please Mark my answer as Resolved/Answered, and give it a thumbs up, so it can help others

    Cheers

    Thank You
    Michael Gernaey MCT | MCSE | MCP | Self-Contractor| Ex-Microsoft
    https://gernaeysoftware.com
    LinkedIn: https://www.linkedin.com/in/michaelgernaey

     

     

     

  • nmlsanmiguel Profile Picture
    on at

    Hi Sir,

     

    This is my code.

     

    Set(varNafsVisMinEJF,
    JSON(ShowColumns(With(
    {
    cData: If(
    And(
    nfUserRole = "user" Or nfUserRole = "approver",
    nfHandlingUnit = "Zamboanga" Or nfHandlingUnit = "Cagayan De Oro"
    ),
    Filter(
    colEJFList,
    And(
    IsBlank(ComboBox1_1.SelectedItems) Or IsEmpty(ComboBox1_1.SelectedItems) Or STATUS in ComboBox1_1.SelectedItems,
    'REPO YARD'.Value = "Zamboanga" Or 'REPO YARD'.Value = "Cagayan De Oro"
    )
    ),
    If(
    And(
    nfUserRole = "user" Or nfUserRole = "approver",
    nfHandlingUnit <> "Zamboanga" Or nfHandlingUnit <> "Cagayan De Oro"
    ),
    Filter(
    colEJFList,
    And(
    IsBlank(ComboBox1_1.SelectedItems) Or IsEmpty(ComboBox1_1.SelectedItems) Or STATUS in ComboBox1_1.SelectedItems,
    'REPO YARD'.Value = nfHandlingUnit
    )
    ),
    Filter(
    colEJFList,
    IsBlank(ComboBox1_1.SelectedItems) Or IsEmpty(ComboBox1_1.SelectedItems) Or STATUS in ComboBox1_1.SelectedItems
    )
    )
    )
    },
    Sort(
    Filter(
    cData,
    FilterByNameDacion_1.Text in Title Or FilterByNameDacion_1.Text in STATUS.Value Or FilterByNameDacion_1.Text in 'ACCOUNT NAME' Or FilterByNameDacion_1.Text in LAN Or FilterByNameDacion_1.Text in 'REPO DATE' Or FilterByNameDacion_1.Text in 'PMS BOOKING DATE' Or FilterByNameDacion_1.Text in Month Or FilterByNameDacion_1.Text in YEAR Or FilterByNameDacion_1.Text in 'REPO YARD'.Value Or FilterByNameDacion_1.Text in 'Collateral Description' Or FilterByNameDacion_1.Text in REMARKS Or FilterByNameDacion_1.Text in 'Chassis Number' Or FilterByNameDacion_1.Text in 'Motor Number' Or FilterByNameDacion_1.Text in 'PLATE NUMBER' Or FilterByNameDacion_1.Text in 'Reason of EJF' Or FilterByNameDacion_1.Text in 'EJF FILING NO.' Or FilterByNameDacion_1.Text in YEAR Or FilterByNameDacion_1.Text in Month
    Or FilterByNameDacion_1.Text in TAGGING.Value Or FilterByNameDacion_1.Text in 'AFS Date' ),
    'REPO DATE',
    SortOrder.Descending
    )
    ),

    Title,
    UNITS,
    LAN,
    ACCOUNTNAME,
    REPODATE,
    DOCDEF,
    OB,
    DocDefRegularizationDate,
    DateofKFRequestforAppraisal,
    TYPEOFDOCDEF,
    STATUS,
    EJFFILEDDATE,
    EJFFILINGNO_x002e_,
    AUCTIONDATE,
    COSDATE,
    DateRoutedKFforPMSBooking,
    CollateralDescription,
    REMARKS,
    MANNER,
    ReasonofEJF,
    TAT,
    Aging_x0020_from_x0020_repossess,
    DocumentsSubmitted,
    AppraisalDate,
    PAN,
    PLATENUMBER,
    ChassisNumber,
    SerialNumber,
    DisposalDate,
    WithRedemption_x003f_,
    SPNAME,
    RedemptionDate,
    RepoDatefromClient,
    DateTurnovertoREPOYard,
    Written_x002d_OffAccount_x003f_,
    OBbeforeWrite_x002d_Off,
    TAGGING,
    AFSDate,
    APPRAISALAMOUNT));vISMINEXPORTDACION.Run(varNafsVisMinEJF,User().Email);Notify("Export Successful",NotificationType.Success)

     

    it is working fine if published. But once I go again to powerapps studio and needs to edit some things.

    Codes of ShowColumns will change from 

     

    AFSDate,
    APPRAISALAMOUNT

    To

    'AFS Date'

    'APPRAISAL AMOUNT'

     

    Which resulted to an error and my export button will not work. and I need to re copy and paste the correct column name based on SP lists url from list settings.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 765 Most Valuable Professional

#2
Michael E. Gernaey Profile Picture

Michael E. Gernaey 343 Super User 2025 Season 2

#3
Power Platform 1919 Profile Picture

Power Platform 1919 272

Last 30 days Overall leaderboard