Type. GetType always returns NULL;
Later, I checked the reference in the web project and found that there was a reference to the corresponding project ..
Therefore, the applicationProgramThe corresponding DLL cannot be found in the web project ..
Add a reference to solve the problem ....
Amount... I don't know how to make it better.
For example
For example, type. GetType ("system. String") // This is okay, because system. String is in mscorlib. dll.
Below I Want To Get myproject. Data. sqlserverdal
Type. GetType ("myproject. Data. sqlserverdal") // This write method is not valid. We need to specify the DLL file of its data.
Type. GetType ("myproject. Data. sqlserverdal, myproject. Data") // This is correct.
If the problem persists, another possibility is that myproject. Data is not referenced in the web project, so the DLL file cannot be found.
Add a new reference.
There are other solutions online
If the above steps cannot be solved, you can look at this