How to Change the URL When Viewing and Using ASP.NET ASMX Services

Asked 2 years ago, Updated 2 years ago, 59 views

Create a web API in ASMX in ASP.NET.
This can be referenced from the C# project and used in the form of a function call.

Do I have to specify this URL when setting up the reference?
The URL is different in the production environment, so if possible, I would like to obtain it from a configuration file and program it.
If anyone knows how to do it, please let me know.

c# .net asp.net

2022-09-29 22:30

1 Answers

There are two ways to browse web services, both of which can be modified by default by configuration file.

If you used a newer service reference, change it to endpoint in the system.serviceModel section of app.config.Learn more about WCF.

Setting service references

Also, for web browsing, items will be added to Settings.settings, so make changes from the applicationSettings in app.config or from the properties of the project properties.

Setting Web Browse


2022-09-29 22:30

If you have any answers or tips


© 2024 OneMinuteCode. All rights reserved.