-------- Original Message --------
Here's my code, all of a dozen or so
lines. ...This is the only change to the default site created
automatically ..
Default.aspx.cs:
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using MCCommon;
using VistaDB;
namespace TestDLL
{
public partial class _Default : System.Web.UI.Page
{
protected void Page_Load(object sender, EventArgs e)
{
//VistaDB.Provider.VistaDBConnection.ClearAllPools();
string dbLocation = @"C:\ProgramData\BlahBlah\Resources";
ASPxLabel1.Text = dbLocation;
//int result =
MyTools.ConvertSNumberToBaseBookingNumber(3.45);//
CommonData.DataDirectory = dbLocation;
//ASPxLabel1.Text = result.ToString();
//Application["DataDirectory"] = dbLocation;
//Application["AppDirectory"] = dbLocation;
//CommonData.AppDirectory = dbLocation;
//string test = CommonData.AppDirectory;
//using (ConfigManager cfgmgr = new ConfigManager())
//{
//// cfgmgr.SetConfigData("DataDirectory", "C:\\");
//// cfgmgr.SetConfigData("SharedDataDirectory", "C:\\");
//// //cfgmgr.GetConfigData();
//}
}
}
}
and web.config:
<system.web>
<trust level= "Full" legacyCasModel="true" />
<compilation debug="true" targetFramework="4.0">
<assemblies>
<add assembly="DevExpress.Web.ASPxEditors.v10.2,
Version=10.2.3.0, Culture=neutral,
PublicKeyToken=B88D1754D700E49A" />
<add assembly="DevExpress.Web.v10.2, Version=10.2.3.0,
Culture=neutral, PublicKeyToken=B88D1754D700E49A" />
<add assembly="System.Windows.Forms, Version=4.0.0.0,
Culture=neutral, PublicKeyToken=B77A5C561934E089" />
<add assembly="System.Design, Version=4.0.0.0,
Culture=neutral, PublicKeyToken=B03F5F7F11D50A3A" />
<add assembly="DevExpress.Data.v10.2, Version=10.2.3.0,
Culture=neutral, PublicKeyToken=B88D1754D700E49A" />
<add assembly="VistaDB.4, Version=4.1.0.0,
Culture=neutral, PublicKeyToken=dfc935afe2125461"/>
<add assembly="MCCommon, Version=9.0.4.0,
Culture=neutral, PublicKeyToken=d0c57861bf8e7fbf" />
</assemblies>
If I comment out the two references in web.config ie VistaDB4 and
MCCommon, the site works fine.
If I uncomment either of these two lines AND LEAVE THE web.config
references commented out:
//VistaDB.Provider.VistaDBConnection.ClearAllPools();
string dbLocation = @"C:\ProgramData\BlahBlah\Resources";
ASPxLabel1.Text = dbLocation;
//int result =
MyTools.ConvertSNumberToBaseBookingNumber(3.45);//
CommonData.DataDirectory = dbLocation;
The web page displays but with no data displayed for result.
All the above worked just fine in asp.net2 - well at least in my
real project.
The whole project can be downloaded here. I've
included MCCommon.dll in the project directory but I left the
project structure as is for information purposes.
On 25/01/2011 2:02 PM, Noon Silk wrote:
So then, your code - how much of it is there?
If you like, send it to me privately and I'll have a quick look
later tonight (I don't have VS2010 on this machine; too blue).
I'm really a bit confused. It seems pretty hard to diagnose
without knowing more, but at this point I'm not sure what to ask.
I would think, if your dll compiles fine for .net 4, and so does
the other project, the combination thereof shouldn't cause
anything particularly "magical" to happen. It should just crash in
the typical way and allow deduction of the errors, or work.
On Tue, Jan 25, 2011 at 1:32 PM, Glen
Harvy <[email protected]>
wrote:
On 25/01/2011 12:56 PM, Noon Silk wrote:
So, is it the combination of your
dll and the commercial dll that causes the hang in
vs2010?
No - either causes the problem ... I have tested all three
scenarios
1. No dlls works fine
2. commercial dll - nope
3. My dll - nope
It seems like you're affected by
two issues at once; a crash in the commercial dll is
initating the debugger, and vs2010 isnt handling that
correctly. So it seems like we can just claim there is
an issue with the commercial dll, but I'm probably
missing something. I really can't say anything useful.
The commercial dll; is it publically available? What is
it? Is it definately built for .net 4? Does it work when
attached to other non-webforms projects? (Say, a console
application)? What does it do? Did you have to install
anything, or is it just as-is?
The commercial dll targets .net2 and works very well in all
other .net2 and .net4 web forms projects. My dll targets
.net4 and works well in all my win forms projects.
The commercial dll works well in win forms applications
targeting .Net2 and as far as I know, everyone else's
projects.
How much code is required, and
what is it, to generate this issue from scratch?
Very simple....
Create a new win forms project targeting .net4. Add the dll
and try to use a method in said dll in the load event of the
default page.
On Tue, Jan 25, 2011 at 12:46
PM, Glen Harvy <[email protected]>
wrote:
Thanks for responding
....
I have tried a completely new web forms
project and it is that project I am now trying
to get working. The only thing that I add to
the new project is my dll and then as another
test the commercial dll. The result is the
same.
I have the source for my dll however this is
no longer the sole issue. The commercial dll
has the same affect as my dll.
I also distribute this web forms site as a
built-in web server so including my source is
not my desired option.
mmmmmmmmmm.....
On 25/01/2011 12:25 PM, Noon Silk wrote:
It's hard to answer
this as-is I think.
Can you try starting a totally new
webforms project and check if you can
reference the dll there?
What is the dll? The person on the asp.net
forum was asking you to add a reference to
the project instead of the dll, on the
assumption you actually have the source
for the project (that generates the dll).
Do you? If so, including it in your
solution, and just adding a reference to
it, will be fruitful, but may not be
possible.
On Tue, Jan 25,
2011 at 11:42 AM, Glen Harvy <[email protected]>
wrote:
Hi,
I have asked this question in the
asp.net
forums as well as stackoverflow
without any success and I am
hoping that someone could help me
out.
First of all I just changed my
Target Framework from 2 to 4 in a
asp.net web
forms application that was working
perfectly well in asp.net2 and now
I have this problem.
My post on
asp.net has all the gory
details but essentially I have
created a new Web Forms
application in VS2010 that targets
.Net4. It runs fine in the
developer web server - it should
as there are no changes :-). I
then add a reference to a dll that
I have compiled for .Net4 and
VS2010 freezes. When I use Task
Manager to shut VS2010 down I get
the following error messages. The
message regarding the source file
is not displayed until I run Task
Manager to shut VS2010 down. For
testing purposes, I removed that
dll and added a reference to a
commercial dll compiled that
targets .Net2 with the same
results.
Can anyone suggest what I am doing
wrong.
![Error Messages]()
Thanks - any and all suggestions
appreciated .....
--
Noon Silk
http://dnoondt.wordpress.com/
(Noon Silk) | http://www.mirios.com.au:8081
>
"Every morning when I wake up, I
experience an exquisite joy — the joy
of being this signature."
--
Noon Silk
http://dnoondt.wordpress.com/
(Noon Silk) | http://www.mirios.com.au:8081
>
"Every morning when I wake up, I experience an
exquisite joy — the joy
of being this signature."
--
Noon Silk
http://dnoondt.wordpress.com/ (Noon Silk) |
http://www.mirios.com.au:8081 >
"Every morning when I wake up, I experience an exquisite joy — the
joy
of being this signature."
|