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 Pages / Unable to save custom ...
Power Pages
Unanswered

Unable to save custom code in powerpages vs code editor

(0) ShareShare
ReportReport
Posted on by 24

Hi Everyone,

I am currently working in a powerpages project and I am using custom code  for every requirement. Recently I have encounter an error while saving custom code in vs code editor. It does not allow me to save and this error is occurring frequently whenever I added new code. This error is not related to my code(I think) and I am also not able to find the solution regarding the error. I have also shared the screeen shot below. Can anyone help me in this?

Categories:
I have the same question (0)
  • Saud Ali Profile Picture
    812 Super User 2024 Season 1 on at

    Hi  @RohitAswal , 

    There could be couple of reasons to this error. Try following:

     

    • Take backup, change your browser, clear cache and try save.
    • Ensure internet connection is stable.

    Sometimes due to large size of file can cause this issue. To check this, try cut out some code and try to save your file. If it works, most likely you've reached the maximum limit, and you can move your changes to another Web File.

    Please try above and share if it works for you.

     

    Thanks,

    Saud

     
    If you like this post, give a Thumbs up. Where it solved your request, Mark it as a Solution to enable other users find it.

     

  • RohitAswal Profile Picture
    24 on at

    Hi @saudali_25 

    I finally found the reason why it was not working, the reason was due to my file having reached its maximum limit.

    I have added my function inside a web template and now it is working fine.
    Just want to know if this approach is good?

  • Verified answer
    Saud Ali Profile Picture
    812 Super User 2024 Season 1 on at

    Hi @RohitAswal , 

     

    As I said in my earlier comment, Web File is best option. Web Templates and Web Files have a completely different purpose. Web Files are using to store your portal assets (css, js, images). And Web Templates provide you with actual HTML code for your pages. You, of course, can write a js code as a part of your Web Template (and you often will) but is not a most reusable scenario if you want to use that code in multiple places. So, better to move in Web Files.

     

    Feel free to ask, if you have any questions and Mark answer as a Solution to enable other users find it.

     

    Thanks,

    Saud

     

    If you like this post, give a Thumbs up. Where it solved your request, Mark it as a Solution to enable other users find it.

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 Pages

#1
Jerry-IN Profile Picture

Jerry-IN 71

#2
Fubar Profile Picture

Fubar 62 Super User 2025 Season 2

#3
sannavajjala87 Profile Picture

sannavajjala87 31

Last 30 days Overall leaderboard