Hello,
We have a license system that checks the assembly name and version using
..NETLicenseManager API (Cf Nikhil K. book on server controls) , using a
deployment project we are able to set the assmbly name and version for
resulting dll, and it works ok.
string assemblyPart = type.Assembly.GetName().Name;
string versionPart = type.Assembly.GetName().Version.ToString();
But in dev phase, our assembly name is automatically generated without
possibility of control and it is very uneasyto work with, solution should be
to put #if everywere the license is tested or the assembly name is get from
..net, but this practice doesn't allow real testing.
So what to do: something has been broken here going from 1.1 to 2.0.
What to do ?
Any idea welcome.
CS 6 1199
Hi MT,
Thank you for posting!
Regarding the code:
string assemblyPart = type.Assembly.GetName().Name;
Can you tell me where is the 'type' from? Is it from a Page class?
And I'm not quite clear about your question about "something has been
broken here going from 1.1 to 2.0". Have you tried the suggestion provided
by Ken Cox in your other post regarding this issue? BTW, the Web
Application Projects 1.0 is released just a few days ago. This new model is
ideal for web site developers who are converting a Visual Studio .Net 2003
web project to Visual Studio 2005.
Regards,
Walter Wang
Microsoft Online Community Support
==================================================
When responding to posts, please "Reply to Group" via your newsreader so
that others may learn and benefit from your issue.
==================================================
This posting is provided "AS IS" with no warranties, and confers no rights.
Hi CS,
Sorry for the typo in your name in previous post.
Regards,
Walter Wang
Microsoft Online Community Support
==================================================
When responding to posts, please "Reply to Group" via your newsreader so
that others may learn and benefit from your issue.
==================================================
This posting is provided "AS IS" with no warranties, and confers no rights.
Hello Walter,
No pb with typo.
Concerning the Ken Cox answer, I don't see it, I will refresh my outlook
subscription to this newsgroup.
My project is now converted to 2.0.
type is an instance of a class that resides in the App_Code folder, when I
run my web application under VS2005 debuger , I get in assemblyPart a name
like App_dzk23, each new run gives a different name.
So it is uneasy to test something.
Regards
CS
"Walter Wang [MSFT]" <wa****@online.microsoft.com> a écrit dans le message
de news: yf*************@TK2MSFTNGXA01.phx.gbl... Hi MT,
Thank you for posting!
Regarding the code:
string assemblyPart = type.Assembly.GetName().Name;
Can you tell me where is the 'type' from? Is it from a Page class?
And I'm not quite clear about your question about "something has been broken here going from 1.1 to 2.0". Have you tried the suggestion provided by Ken Cox in your other post regarding this issue? BTW, the Web Application Projects 1.0 is released just a few days ago. This new model is ideal for web site developers who are converting a Visual Studio .Net 2003 web project to Visual Studio 2005.
Regards,
Walter Wang Microsoft Online Community Support
================================================== When responding to posts, please "Reply to Group" via your newsreader so that others may learn and benefit from your issue. ==================================================
This posting is provided "AS IS" with no warranties, and confers no rights.
Hi CS,
Have you tried the Web Application Projects addin? Would you mind letting
me know the result of the suggestions? If you need further assistance, feel
free to let me know. I will be more than happy to be of assistance.
Have a great day!
Regards,
Walter Wang
Microsoft Online Community Support
==================================================
When responding to posts, please "Reply to Group" via your newsreader so
that others may learn and benefit from your issue.
==================================================
This posting is provided "AS IS" with no warranties, and confers no rights.
Hi Walter,
Yes it solved it for final project, but in dev phase, assembly name is lost.
That's a reat problem.
CS
"Walter Wang [MSFT]" <wa****@online.microsoft.com> a écrit dans le message
de news: oH**************@TK2MSFTNGXA01.phx.gbl... Hi CS,
Have you tried the Web Application Projects addin? Would you mind letting me know the result of the suggestions? If you need further assistance, feel free to let me know. I will be more than happy to be of assistance.
Have a great day!
Regards,
Walter Wang Microsoft Online Community Support
================================================== When responding to posts, please "Reply to Group" via your newsreader so that others may learn and benefit from your issue. ==================================================
This posting is provided "AS IS" with no warranties, and confers no rights.
Thank you for your quick response.
I've done some test using Web Application Projects add-in, but was unable
to reproduce the problem. Here's the steps I used to test it:
1) Create a new Visual C# "ASP.NET Web Application"
2) Create a new class Class1
3) In Default.aspx.cs, Page_Load:
Class c1 = new Class1();
Response.Write(c1.GetType().Assembly.GetName());
The result shows correctly the Project's assembly name.
If I use following code in Page_Load:
Response.Write(this.GetType().Assembly.GetName());
It does show an assembly name which is dynamic, but I think it's the same
behavior with ASP.NET 1.1 which is expected.
If there is anything I misunderstood, please feel free to post reply here.
Regards,
Walter Wang
Microsoft Online Community Support
==================================================
When responding to posts, please "Reply to Group" via your newsreader so
that others may learn and benefit from your issue.
==================================================
This posting is provided "AS IS" with no warranties, and confers no rights. This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics
by: David Lindgren |
last post by:
Hi.
I'm using automatic increase on the assembly build number. Only problem is
it's doesn't increase. Anyone know what might cause this?
In AssemblyInfo.cs:
Thanks!
|
by: Aamir Mahmood |
last post by:
Hi all,
How can I set the version information (major, minor) in my assembly.
And also how can I easily get it at runtime?
-
AM
|
by: jez123456 |
last post by:
Hi, I'm trying to add the product, title and version number to my main form
with the following code. I've tried using this code in the public class
FrmMain section but I get the error thisAsm'...
|
by: e_zverev |
last post by:
Hi
The question concerns the ways ASP.NET loads required assemblies into it's
app domain.
I know of a deprecated feature of clr assembly detection in which the use of
environment variable...
|
by: Praveen Ramesh |
last post by:
Hi,
Is there any way to add the @Assembly reference to the aspx files
programmatically from inside a custom control (when it gets dropped on to
the page from the toolbox)?
I have a custom...
|
by: Phil Galey |
last post by:
I created an About box and am able to get all the assembly information from the program to show up in the About box except the Version.
I created the About box as a separate Windows application,...
|
by: Jim Shank |
last post by:
I am attempting to embed a text resource in my assembly and following MSDN
article...
|
by: Andrew |
last post by:
In ASP.NET 1.1 I used to retreive the version of my code-behind assembly
using following syntax:
Assembly.GetExecutingAssembly().GetName().Version
The version was defined in AssemblyInfo.cs using...
|
by: puzzlecracker |
last post by:
is there a way to create a library (assembly/dll) where I can only
export few class? I don't want client to use or know about other
internal classes in the assembly.
Thanks
|
by: isladogs |
last post by:
The next Access Europe meeting will be on Wednesday 7 Feb 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:30 (7.30PM).
In this month's session, the creator of the excellent VBE...
|
by: DolphinDB |
last post by:
Tired of spending countless mintues downsampling your data? Look no further!
In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
|
by: Aftab Ahmad |
last post by:
So, I have written a code for a cmd called "Send WhatsApp Message" to open and send WhatsApp messaage. The code is given below.
Dim IE As Object
Set IE =...
|
by: ryjfgjl |
last post by:
ExcelToDatabase: batch import excel into database automatically...
|
by: isladogs |
last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM).
In this month's session, we are pleased to welcome back...
|
by: isladogs |
last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM).
In this month's session, we are pleased to welcome back...
|
by: Vimpel783 |
last post by:
Hello!
Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
|
by: jfyes |
last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
|
by: ArrayDB |
last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
| |