I have a site that is built in Classic ASP with ADODB Access databases. I'm moving to a new host and now getting an error for code that runs fine on current host.
ADODB.RecordSet error '800a0c93' operation is not allowed in this
context
I researched the problem and it appears that the problem is related to the way I open recordsets. by default recordsets open forward only. I'm trying to move previous in the code.
I checked and the code to open the RS is:
rsChurches.open strSQL1, adoCON, 3,3
3 = adOpenStatic.
This code should work as it runs fine on my current server. I checked the application pool. it's .net framework 2.0 classic with 32 bit applications enabled like the current server.
After looking at the server all day, I changed the cursor type to 2 and it worked.
rsChurches.cursortype = 2
rsChurches.open strSQL1, adoCON
I'm not sure why the new server didn't like type 3.
Related
I have ran a SQL script to update the UserPreferences.UseLegacyUI to 0 for all of the users in our 2018 R1 system but, the users are still getting the classic UI when they log into the system. Any thoughts on why this might be? We're trying to avoid every user having to change their setting in their profile.
EDIT: Users are having to switch to the modern UI every time they log in. Is there a cookie involved?
Try using the UserPreference graph to change that value, that's how it's used in 'Main.aspx.cs'. Sometimes there's code in event handlers that needs to be executed too:
PX.SM.SMAccessPersonalMaint prefGraph = PX.Data.PXGraph.CreateInstance<PX.SM.SMAccessPersonalMaint>();
PX.SM.UserPreferences prefs = prefGraph.UserPrefs.SelectSingle() ?? prefGraph.UserPrefs.Insert();
prefs.UseLegacyUI = false;
prefGraph.UserPrefs.Update(prefs);
prefGraph.Persist();
There was an HTTP redirect set in IIS on both the web site and the web application that was causing this. I suspect this was a hold over from the 5.3 installation but, not sure. Removing the redirect from the web application and removing the "/main.aspx" from the web site redirect cured this issue.
We've got a new server, and I am trying to set it up for our website.
I got a new application for the engineers set up in the Application Pools called eng_app, then added our applications to it.
Now, we have been given an external drive that these applications need to be on, but I can't seem to edit or delete the existing applications.
I tried following the Microsoft Technet Article • Remove an Application (IIS 7) but, as you can see in the screenshot, those are incorrect.
C:\Windows\System32\inetsrv>appcmd delete app "eng_app/drawing"
ERROR ( message:Cannot find APP object with identifier "eng_app/drawing". )
C:\Windows\System32\inetsrv>appcmd delete app "/eng_app/drawing"
ERROR ( message:Must specify the APP object with identifier or "APP.NAME" parameter. )
Could someone tell me what I missed here?
Using Powershell
Go to folder
cd C:\Windows\system32\inetsrv
List all applications to get the correct APP.NAME
.\appcmd list app
Delete the application using fullname for <APP.NAME>.Ex.: "Default Web Site/The.Application".I mean, you must put it with web site name including the double-quotes.
.\appcmd delete app <APP.NAME>
OK, it looks like you can't do it either through the command line or using the Application Pool interface.
After stopping the webservice, what I did was:
go down to the list of Sites and select my application from the list,
click Basic Settings...
change the Application pool with the Select... button and edit the Physical path
Afterwards, you can restart the webservice.
There might be a better way, but this is how I did it.
appcmd delete app eng_app/drawing
I am trying to run the XSockets WebRTC example found here: http://www.nuget.org/packages/xsockets.sample.webrtc
The package installs and displays index.html, however the websockets server does not appear to start. This seems to work since I renamed the CustomBroker to CustomBrokerController.
A couple notes:
1.) I am running Visual Studio 2013 which appears to self host apps under IIS Express only. Per the application readme file, I should be running under Visual Studio Development Server:
Right click the project and select properties.
Under the "Web" tab go to the "Servers" section and set Use Visual Studio Development Server
Is this a problem, if so - how to fix it?
2.) index.html contains this line: conn = new XSockets.WebSocket('ws://127.0.0.1:4502/Broker');
There is no controller named "Broker" in the controller subfolder under the WebRTCSample folder. Though the remote and local video seems to work, none of my breakpoints are getting hit on the CustomBroker controller. Now I noticed that the CustomBroker class under the controller folder does not have the "Controller" name connected to it as in "CustomBrokerController". I renamed it from "CustomBroker" to "CustomBrokerController" and now I am hitting breakpoints, but on the client index.html page, if I open up two separate windows and pass the same context as querystring the remote video section does not display. The weird thing is that from the console on the client side, I see an object array that seems to hold a list of the connections and seems to accurately reflect the amount of remote connections I have.
3.) I added a XSocketsBootstrapper per the readme file. I added this file to the App_Start folder as per the instructions.
UPDATE:
I created a new project and added XSockets.WebRTC files using the library manager. I hit the home controller to invoke the BootStrapper and the breakpoint triggered. It also hit the breakpoints for the CustomBroker after I changed the name from Broker to CustomBroker. Now, after I refresh the index.html page, none of the breakpoints are called from the CustomBroker. Should this be happening? I would think that when this line is reached in javascript, peerBroker = new XSockets.WebSocket("ws://127.0.0.1:4502/CustomBroker"); the controller events would fire. Am I missing something?
Just to be sure I tried it my self without any issues.
Renaming CustomBroker to CustomBrokerController will do make any difference since the Controller part is a suffix.
Lost you in step 2, will try your exact steps later and let you know the result.
I had written a mini App in asp classic this week. It worked perfectly on the test server connecting to the test data base. Then yesterday evening I moved it from the test server to the live server updating the connection strings to the live db.
I published it as an application to the default website in the default app pool. Then I tested it and it worked perfectly.
This morning however both myself and another user receive a 500 -internal Server error when we try and save changes to the database(there appears to be no issue reading from the db) yet my two other collogues have no issue at all.
Even more odd is that the same thing is happening on the test server where the code hasn't been changed in weeks. But this morning I cannot commit to the db from there either.
I have attempt to enable more detailed error tracking and logging but the property options for the server are seem unavailable when i tried to set up custom Active Server Pages (ASP) error pages off online tutorials.
The server is used by a lot of people so I was wondering is their a permission issue depending on the user that restricts writting to the database. Or something else that may have changed to allow some users to write data and others to receive the error.
Im very knew to IIS so it may be something glaringly obvious that I haven't considered.
Thanks
This article should help you:
In earlier versions of IIS, error messages from classic ASP scripts
were sent to a Web browser, by default. Because these error messages
might reveal sensitive information to malicious users, IIS 7 and above
disables this feature by default. When your classic ASP scripts
encounter an error in IIS, you receive the following error message by
default:
An error occurred on the server when processing the URL. Please contact the system administrator.
If you are the system administrator please click here to find out more about this error.
I have backed up the Kentico Database and website from one of our Live servers and placed it within our Dev server and configured the website in IIS.
When I navigate to the website, it currently asks for New installation.. Whereas it should just show me the current website.
How do I get it to show the website?
EDIT
The following error occurs when going ahead and creating a new instance with the restored Database:
Restore the backed up database and add database connection string to the web.config of the application. Simple as that :)
Who or what is set as the DB objects owner/schema in the DB? Does this match the setting in Site Manager (or, CMS_SettingsKey table)? I would make sure these two match.
Another option is that the connection string was not initialized by .Net - I would do a dummy change in the web.config file to force the app restart and/or also clearing the .Net cache.