简体   繁体   中英

Where am I missing an IP address in the connection string of my web application?

Ok, First of all, I want to make the disclaimer that aside from some HTML I have done very little programming in my lifetime. However, as necessity so often dictates, I am in dire need of some assistance with that very thing at this moment.

Our agency has a web site that is hosted by another entity, and that entity is forcing our hand in moving the content of that site onto one of our own servers. All content has been moved to the new server, and all database tables from the old database have been moved onto our internal SQL server. The site primarily consists of asp files, but there is one page that is aspx. The problem arises when taking the "old" database tables offline and testing the aspx page. Even though all instances of the IP address to the old SQL server have been changed to reflect the IP of the new SQL server, the aspx page insists on requiring the connection to the old database (the error indicates the tables are offline, thus pointing to the old SQL server). Everything else works as it should, and the "Web Application" has been designated as such in IIS.

I know I am missing something somewhere... but I just can't put my finger on it. Any ideas would be greatly appreciated. I'm starting to wonder if the reference to the old IP address is compiled in a file somewhere that I just can't find.

Thanks

Ok guys, I found my solution. For programmers, this solution probably would have been a no-brainer, but for others maybe not so much.

I have to give a pat on the back to "Creator" for pointing me in the direction of the project file. I wasn't sure that it was still available, but thankfully the programmer who designed this application somewhere a little over ten years ago was nice enough to leave it in the web directory with everything else.

What I wound up doing was as follows:

  1. Opened the project file in Visual Studio 2010 and converted the project from 2003 to 2010.
  2. Added the connection strings into the web.config to the new SQL server.
  3. Right clicked on each item and excluded all of the old pieces to the application (in Solution Explorer) that were no longer needed.
  4. Right clicked on the project and navigated to Package/Publish Settings > Package/Publish SQL and chose to "Import from Web.config".
  5. Saved the project, then right clicked and "Converted to Web Application".
  6. Right clicked and performed a "Build". I'm guessing this re-wrote the dll file.
  7. Copied the directory and needed files back over to the web server and converted the directory in IIS to a Web Application.
  8. Sat back and marveled at my success.

Thank you guys for pointing me the right direction!

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM