aspnet_wp.exe could not be started.
Hi! I have follow all the microsoft article to solve
above problem but the problem still exists. The only
solution is uninstall .Net Framework 1.1 and re-install
again then the problem is solve but each time i restart
the server, the error message come out again and i need
to uninstall and re-install again. Please advise...thanks!
here is the event viewer error message:-
aspnet_wp.exe could not be started. The error code for
the failure is 80070545. This error can be caused when
the worker process account has insufficient rights to
read the .NET Framework files. Please ensure that
the .NET Framework is correctly installed and that the
ACLs on the installation directory allow access to the
configured account. Tag: FAQ: How To Install Your Assembly in the GAC Tag: 55733
Bug in Start Page ?
Hey...since installing vs.net 2003...I have had to deal
with this annoying bug in the Start Page. Previously,
the "modified date" column of your project list indicated
the last date the project was modified. Makes sense.
Since .net 2003, the "modified date" of the project stays
the same....and never, ever, ever, ever updates. What's
up with that?? What broke? And...can it be fixed??
This is a pain... Tag: FAQ: How To Install Your Assembly in the GAC Tag: 55732
Converting VB App for the web
Hi,
What will be fastest and easiest way to convert the very complex existing
vb6 project using Access database to a web project ? Any idea will be
appreciated.
Thanks Tag: FAQ: How To Install Your Assembly in the GAC Tag: 55728
Hello All
I would like to list the Entire Network from within my VB.NET app and allow
the user to select mulipy machines... I would like to retain those machones
names so I can can pass them via (shell) to a Windows script for excution...
any suggestions?
thanks in advance, Wayne Tag: FAQ: How To Install Your Assembly in the GAC Tag: 55727
Why is HttpWebRequest different than IE?
Why when I retrieve the response from a URL using HttpWebRequest, do I
end up with HTML that is different than IE, even if I set the
HTTP_USER_AGENT to be the same as IE?
Here's a super-simple example. Note that in IE when you load this
URL, there are "£" symbols in front of all of the prices (verified by
View | Source), but in the HttpWebRequest response there are not...the
actual HTML is definitely different...
HttpWebRequest eRequest =
(HttpWebRequest)WebRequest.Create(
"http://cgi6.ebay.co.uk/aw-cgi/eBayISAPI.dll?ViewBids&item=2340661957");
eRequest.Headers.Add("HTTP_USER_AGENT",
"Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; .NET CLR
1.0.3705)");
eRequest.Headers.Add("HTTP_ACCEPT", "*/*");
eRequest.Headers.Add("HTTP_ACCEPT_LANGUAGE", "en-us");
WebResponse eResponse = eRequest.GetResponse();
string eContent = new
StreamReader(eResponse.GetResponseStream()).ReadToEnd();
Debug.WriteLine(eContent);
Any help appreciated.
BTW - I thought it might be cookies, so I disabled cookies in IE to
see if that made a difference - it doesn't! Tag: FAQ: How To Install Your Assembly in the GAC Tag: 55718
Newbie to the .NET World
I've been looking on MSDN website for examples of how to access Active
Directory.
Does any one know of any links to code examples.....
Thanks,
Wayne Tag: FAQ: How To Install Your Assembly in the GAC Tag: 55715
Bug database
I was just wondering if there's a bug database for .NET framework. The
reason I'd like to see one if that I can be aware of bugs in the framework
and won't have to find the bugs the hard way (where I have to eventually
realize something doesn't work because of a bug, not because I'm doing
something wrong).
Jerry Tag: FAQ: How To Install Your Assembly in the GAC Tag: 55705
account the App is running under
Hi,
Is there anyway(programatically) to find out under what
account the current application is running?
Thanks,
Yu Tag: FAQ: How To Install Your Assembly in the GAC Tag: 55690
Mail Address of Current User
Hi All,
You on a workstation logged on as a specific user, and you want to use
SmtpMail
(System.Web.Mail.SmtpMail) to send an e-mail from your program.
The form of the method to send an e-mail is:
SmtpMail.Send(from, to, subject, body);
I already know who the message is going 'to', the 'subject', and the
'body'.
But I can't have the user type in their e-mail address because the app doing
all this 'behind the scenes'.
How can I get the e-mail address of the current user programmatically?
Thanks in Advance,
SteveH Tag: FAQ: How To Install Your Assembly in the GAC Tag: 55688
Primary Key
Can a primary key be permantly set in a VFP table
contained within a DBC as I'm trying to connect a DBC
database to a .net 2003 application but due to a primary
key not being permantly set the application want allow
deletions or updates to the database. I am using the ODBC
VFP connection drivers to connect the database to .net.
I have added the primary key to the table in the DBC but
it want be active unless the order is set to it, but from
the SQL statement in .net it want allow any order to be
set.
Does anyone know if there are issues with updating &
deleting from a VFP Database using .net.
Thank you
James Gardiner Tag: FAQ: How To Install Your Assembly in the GAC Tag: 55687
Lack of Unsigned CLS-Compliant Types in .NET
I'm wrapping a native C++ API with MC++. One of the things that I have
found frustrating is the fact that most (if not all) unsigned types in .NET
are not CLS-Compliant. So, to me, that means you can't use them, say, as
arguments in a method because a particular .NET language is not required to
support those types. The C++ API has a lot of paramters that are U8, U16,
and U32 types. Since the equivalent types in .NET are not CLS-compliant, I
find my self using a larger signed type to hold the possible non-negative
values of the corresponding unsigned type. For instance, for a U32 in the
C++ API, I have to use an Int64 in .NET. While, this works, it's just sort
of messy. For example, it forces you to do runtime checks on numbers that
are larger than can fit in a U32 in case someone passes in a really large
number in a method call (e.g. someone calling a method that takes an Int64
could pass in 4,294,967,306 - this is too large for a U32).
I was just curious if there is a better way to handle this? Not making
unsigned types CLS-compliant seems somewhat short-sighted to me, but maybe
I'm wrong. Any thoughts?
Thanks,
Tim Rogers Tag: FAQ: How To Install Your Assembly in the GAC Tag: 55686
ASP.Net and client side control (SelectedIndexChanged)
I was wondering what capabilities ASP.Net has at the client level.
I have been using a RadioButtonList.
My control and additional textboxes look like this:
o See item number [ ]
o See items from Date [ ] to date [ ]
I have the method defined for SelectedIndexChanged event. Basically,
I am trying to clear and disable the text selections for the
unselected item.
Example:
private void RadioButtonList1_SelectedIndexChanged(object sender,
System.EventArgs e)
{
if (RadioButtonList1.SelectedValue.ToString() == "ItemNumber")
{
txtFromDate.Text = "";
txtToDate.Text = "";
txtFromDate.Enabled = false;
txtToDate.Enabled = false;
txtItemNumber.Enabled = true;
}
}
The problem is that my SelectedIndexChanged event does not fire until
the post. I can set the AutoPost=True, but this is still doing a
post. That seems like a lot of traffic (back to the server and
running code again, etc) just to disable some client level fields. I
should be able to do this all on the client because the server does
not need to know this information.
Well, I could fall back by writing some JScript to do this for me, but
I thought there would be a native way for ASP.Net to handle this.
Does anyone have any ideas?
Thanks in advance! Tag: FAQ: How To Install Your Assembly in the GAC Tag: 55684
Get IntPtr for a byte array
I have a third party Dll with a function which requires an IntPtr but the
data is in a byte array. I need to get the IntPtr for this byte array so I
can pass it into the function.
Thanks in advance,
~Logan Tag: FAQ: How To Install Your Assembly in the GAC Tag: 55681
Primary key
Can a primary key be permantly set in a VFP table
contained within a DBC as I'm trying to connect a DBC
database to a .net 2003 application but due to a primary
key not being permantly set the application want allow
deletions or updates to the database. I am using the ODBC
VFP connection drivers to connect the database to .net.
I have added the primary key to the table in the DBC but
it want be active unless the order is set to it, but from
the SQL statement in .net it want allow any order to be
set.
Does anyone know if there are issues with updating &
deleting from a VFP Database using .net.
Thank you
James Gardiner Tag: FAQ: How To Install Your Assembly in the GAC Tag: 55680
File or assembly name System.Windows.Forms error in Visual Studio.NET Beta 2.
I am using Visual Studio .NET Beta 2, because this is the only version I
could get.
I installed it. Had some problems with starting it. I was getting a
message like this: "Visual studio was installed under another user". I
found out that the way to go around it is to delete
the key from registery. After that it starts and I can create procjects and
everything, but I can't compile asp.net pages and can't view web.config or
global.asax.
The error I get is: Resource transformation failed for file :
WebForm1.aspx.resx. File or assembly name System.Windows.Forms, or one of
its dependencies, was not found.
I can't figure this one out. Please Help.
Andrzej Tag: FAQ: How To Install Your Assembly in the GAC Tag: 55679
Accessing VB6 activex exe in a .net Windows Service
I've been able to acces my VB6 ActiveX Exe via a console
application by building a wrapper around my component.
But when I do the same thing using a windows service, I
get an error during execution saying FileNotFoundException
for the ActiveX Exe. This ActiveX exe component is
registered on my computer. Is it possible to do this
with a Windows Service written under .net? If so, what am
I doing wrong. I've added the reference for the
component, then did the following:
Dim oMyObject as MyACTIVEXComponent.clsServer
oMyObject = new MyActiveXComponent.clsServer
Like I said, this works with the Console Application, but
not with the windows service. Tag: FAQ: How To Install Your Assembly in the GAC Tag: 55674
Visual Studio's Context Menu
Hi,
How can I add a menu options to the context menu in the
ide? I know how to add an option to the commandbar. I
am trying to write an add-in that is invoked by right-
click in the ide.
Thanks Tag: FAQ: How To Install Your Assembly in the GAC Tag: 55672
PDF/RTF Conversion
Hello Guys,
I want to convert all general documents like (doc, xls,
txt, ...etc) in pdf.
Also my requirenment is to first merge 2 or more documents
of same or different types and then convert the merge
result to pdf. Like merge one doc and one xls and convert
it to pdf. Original doc and xls remains the same.
I want to do above through programming in .NET.
I also want to convert same in rtf, like doc to rtf, or
xls to rtf, or 1 doc + 1 xls to rtf.
So if anybody has already spend some time, it would be a
great help required for me.
Waiting for positive responses !!
Regards,
Tushar Tag: FAQ: How To Install Your Assembly in the GAC Tag: 55668
Directory Services
Hi,
i am using VS 2002. and unable to find
System.DirectoryServices. anyone can help me?
it says "the type or NameSpace name is not found". Tag: FAQ: How To Install Your Assembly in the GAC Tag: 55662
O/R Mapping tool like Apple has.....for .NET?!?!
Hi!
I post this text 1 year ago. But no one really could give
me an answer. This is the text that I posted long time ago:
I have a fundamental question about
The way .NET handles the object orientated way of
Persistence. I am coming from JAVA and WebObjects (Apple)
World and I am looking for a convenient way of working
with objects without seeing any SQL statements only
objects. I have used that approach for years on the
WebObjects Platform (Enterprise Object Framework) and in
Java recently (Container Managed Persistence). I am
looking for something like that in the Microsoft world.
As far as I understand Microsoft does not distinguish
between the Object Model and the Relational Model. The
main difference is that the Object model allows n : m
relationships and the Relational does not allow them. Here
a small example to visualize the problem:
Example:
There is a Patient object with following Attributes
String patientGUID;
String name;
Int age;
Hashtable diseases; (or some other Container like
Collection or Array)
And there is a Disease Object
String diseaseGUID;
String name;
In the object Model there is relation between Patient and
Disease where the patient has his diseases but on the
other site one disease can belong to 1..* patients. (n :
m)
That n : m relationship can not exist within a relational
database without a link table that contains the
connections between the tables: Patient and Disease.
Now, I would like to connect the object Model containing
TWO Entities (Patient, Disease) with the relational
database (containing THREE tables). Then I want to work
with my objects; e.g. create new diseases connect them to
existing patients by putting the diseases into the array
or create new Patients and connect them with already
existing diseases or just change a Patients name. When I
am finished I just want to say SAVECHANGES and the
database is updated accordingly including all link table
entries.
So all I have to care about are my objects and the
relations between them, some invisible layer does all the
dirty work like building SQL, converting the data types
and caching. So if I fetch a Patient with a specified GUID
I do not have to care about fetching his diseases. They
are fetched automatically. If there are too many Diseases
I do not care some kind of algorithm handles that problem
in such a way that if I have to search all of them for
something they are simply there. They are loaded on demand
(lazy evaluation)
Supposing that the disease has a further connection with
some DiseaseType Object/Table and that table has an
attribute/column "Description" I can access it by typing
the following code:
TextField1.Text = currentDisease.type().description()
Please note that to retrieve the description value I did
only fetch the Patient. The diseases and its types were
fetched automatically.
Is something like that possible or am I excepting too much
of the .NET?
-------------------------------------------------------------------
This tool should be a mixture between Microsoft Visio (I mean ORM modelling)
and a good object-to-relational mapping tool.
Is something like that NOW available????
thx!
gicio Tag: FAQ: How To Install Your Assembly in the GAC Tag: 55661
Problem in listening on TcpClient ...............
when i am listening on any port
using TcpClient bufferedstream available method ,
No reponse comes .Program hangs there or u can say does
not come out of the read method
tc is TcpClient
ns is networkstream
ns = tc.getStream();
while( ns.DataAvailable )
{
try
{
rec=bs.ReadByte();
Console.Write(rec);
Console.Write("\n");
}catch(System.IO.EndOfStreamException)
{
Console.WriteLine("EndOfStreamException Received ");
}
}
Can anyone help me that in which way i can read socket
correctly.. Tag: FAQ: How To Install Your Assembly in the GAC Tag: 55657
.Net remoting newbie
I'm trying to set up the following:
1. a C# server is instantiated by our hosting application on computer A.
2. a C# client on computer B gets a reference to the server with nothing
more than the server's URI (or URL, I still don't see the difference).
I've found some good documentation on how to create a server that derives
from System.MarshalByRefObject, and activate it with the desired URI using
System.Rumtime.Remoting.RemotingConfiguration. I cannot, however, find how a
client can get an object reference by URI. I am finding plenty of examples
where the server is just-in-time created after a client request, but I need
the server to run even if there are no clients.
Another stupid question, how do I read a server's URI after activation? I
see that the System.Runtime.Remoting.Channels.ChannelServices has a static
GetUrlsForObject method, is that how I do it? I guess I'm old fashioned in
that I believe that if an object has a property, it should expose it through
accessors - you shouldn't have to pass your object into a static method on a
third party object. Tag: FAQ: How To Install Your Assembly in the GAC Tag: 55655
.Net network layer have DNS caching flaw?
We have an asp.net app that makes an http request call to
a server by dns name (there are 3 vips associated with
this dns name). For some reason, all our calls are
resolving to only one of the VIPs. Running an nslookup
command shows all 3 IP address of the 3 VIPs (in
different orders on each call); this confirms that DNS is
not favoring any of these addresses; it was clearly doing
a round-robin. We tried setting the TTL value to 1/0 but
this did not work; most calls were still going to the one
vip. Running "ipconfig/dnsflush" did not work either.
If dns is not the problem, then can .net be the issue?
The code leaves the dns resolution to the .NET Framework
network layer (the ServicePoint class). We don't
explicitly do anything to those objects. Is it possible
that this resolves the IP address and caches it? Tag: FAQ: How To Install Your Assembly in the GAC Tag: 55652
Explicit interface indexer implementations?
Is there a way to explicityly implement an interfaces indexer? I need to
create a collection class, that implements IList, ICollection, and
IEnumerable. I'd like to create a custom indexer, with a return value of my
choosing, rather than object. Whenever I try, though, the compiler spits out
an error (I use C#, BTW). I've tried simply implementing object this[int
index] in addition to MyClass this[int index], but got an error. I also
tried IList.this[int index] in addition to MyClass this[int index] but also
got an error. How does one explicityly implement the indexer of an interface
so you can implement a custom one? Thanks for the help.
Jon Rista Tag: FAQ: How To Install Your Assembly in the GAC Tag: 55650
ADO.net Got speed ?!?!
I recently upgraded from VB6 to VB.net and decided that i
would like to update a program i use a lot. The Program
Connects to a M$ access database (access 2000). It reads
in server logs and parses the infomation using the Split
command and a select statement to pick out appropriate
words. It then inserts each 'record' (each line in the
server log contains 1 record) into the database.
Under VB6 i used DAO (of course) and my program was fine.
The searching was Fast, the data retreival was fast, the
input FAST. It took less than 2 seconds to parse a single
log file and insert the whole thing into the database. I
timed it. To parse 62,398 records it took 6 minutes 23
seconds, Give or take 10 seconds.
Now i switched to ADO.net (thinking new = better :oops:)
I use Datasets to populate a Datagrid (easy and fast). I
use dataadapters to insert the info to the database by
updating the datset and using the .update command.
Now i guess my question is why does it take my program 38
minutes 54 seconds (give or take 1 minute) to parse
62,398 records? ??!?!!?!?!?!?
When i insert the data i dont fill any datasets
(something which could if in a loop add vital seconds to
each loop) i dont do anything other than add the data
then update.
Now i cant for the Life of me imagine that the M$
programmers Butchered the SPlit Code. So in my opinion i
rule that out. So im afriad the only thing left is the
data access....
Sample Code::
-----------------
PlayerDA.InsertCommand = New OleDbCommand("INSERT
INTO Players ([Date], [Time], Name, WonID, IPAddress)
Values(?,?,?,?,?)", DBConnection)
PlayerDA.InsertCommand.CommandType =
CommandType.Text
PlayerDA.InsertCommand.Parameters.Add("@Date",
OleDbType.Char, 50, "Date")
PlayerDA.InsertCommand.Parameters.Add("@Time",
OleDbType.Char, 50, "Time")
PlayerDA.InsertCommand.Parameters.Add("@Name",
OleDbType.Char, 50, "Name")
PlayerDA.InsertCommand.Parameters.Add("@WonID",
OleDbType.Char, 50, "WonID")
PlayerDA.InsertCommand.Parameters.Add
("@IPAddress", OleDbType.Char, 50, "IPAddress")
DBConnection.Open()
Dim newRow As DataRow = DataSet1.Tables
("Players").NewRow()
newRow("Date") = ""
newRow("Time") = ""
newRow("Name") = ""
newRow("WonID") = ""
newRow("IPAddress") = ""
DataSet1.Tables("players").Rows.Add(newRow)
PlayerDA.Update(DataSet1, "Players")
DBConnection.Close()
----------------
Insert blank... is it that ^^^ ? or is it my Split code?
Sample Code:
------------------------------
Do Until LineCount = NumberOfLinesInLogFile
UnformattedLogLine = LogFile(LineCount).Word
UnformattedLogLineSplit = Split
(UnformattedLogLine, " ")
UnFormattedLogLineNumOfValues = UBound
(UnformattedLogLineSplit)
'Formatting the Info
Do Until GettingParsedValues >
UnFormattedLogLineNumOfValues
Select Case GettingParsedValues
Case 0
Case 1
Case 2
Temp = UnformattedLogLineSplit
(GettingParsedValues)
ParsedArray(0) = Temp.Trim
(TrimValues.ToCharArray())
Case 3
Temp = UnformattedLogLineSplit
(GettingParsedValues)
ParsedArray(1) = Temp.Trim
(TrimValues.ToCharArray())
Case 4
GettingName = Split
(UnformattedLogLine, "NAME:")
GettingNameUpper = UBound
(GettingName)
If GettingNameUpper > 1 Then
GettingNameFoundToSplit =
GettingName(1)
GettingName2 = Split
(GettingNameFoundToSplit, ",")
Name = Trim(GettingName2(0))
ParsedArray(2) = Name
Else
GettingName = Split
(UnformattedLogLine, " ")
Name = Trim(GettingName(4))
ParsedArray(2) = Name
End If
Case 5
Case 6
Case 7
GettingWonID = Split
(UnformattedLogLine, ":")
gettingwonidupper = UBound
(GettingWonID)
If gettingwonidupper > 3 Then
GettingWonIDFoundtoSplit =
GettingWonID(5)
GettingWonID2 = Split
(GettingWonIDFoundtoSplit, ",")
WonID = Trim(GettingWonID2(0))
ParsedArray(3) = WonID
Else
GettingWonID = Split
(UnformattedLogLine, ",")
WonID = Trim(GettingWonID(2))
ParsedArray(3) = WonID
End If
Case 8
GettingIP = Split
(UnformattedLogLine, "IP:")
GettingIPFoundToSplit = GettingIP
(1)
GettingIP2 = Split
(GettingIPFoundToSplit, ":")
IPAddress = Trim(GettingIP2(0))
ParsedArray(4) = IPAddress
Case Else
End Select
GettingParsedValues = GettingParsedValues
+ 1
Loop
IncrementLineCount()
IncrementRow()
GettingParsedValues = 0
InsertingParsedValues = 0
Col = 0
Insert_to_database()
Loop
--------------------
I really would like some insight from anyone :) I will be
absolutely speachless to think my split code is causing
this kind of performance degredation especially when its
IDENTICAL to the previous version (under vb6).
So im pretty sure its my Database code. This is my first
ADO.net so be kind ;) Tag: FAQ: How To Install Your Assembly in the GAC Tag: 55649
error CLR: 8007000b
When I run regsvcs I can see the following message: error
CLR: 8007000b
Why?
I have installed Commerce server 2002 developers
edition(with SP2) in windows 2000 server and with .net
framework 1.1 Tag: FAQ: How To Install Your Assembly in the GAC Tag: 55638
XmlConvert bug?
The following code throws a System.Format exception, it
seems like XmlConvert cannot correctly handle TimeSpan
objects. I guess I could use TimeSpan.Ticks but it makes
for ugly XML. Is there a better way?
Thanks,
Pat.
using System;
using System.Xml;
namespace ConsoleApplication1
{
/// <summary>
/// Summary description for Class1.
/// </summary>
class Class1
{
/// <summary>
/// The main entry point for the
application.
/// </summary>
[STAThread]
static void Main(string[] args)
{
TimeSpan foo = new TimeSpan(12345);
string bar = XmlConvert.ToString
(foo);
TimeSpan back =
XmlConvert.ToTimeSpan(bar);
}
}
} Tag: FAQ: How To Install Your Assembly in the GAC Tag: 55634
Inheritance Problem when trying to implement Page Controller
Hi All,
Can somebody tell me what I am doing wrong.
I have a Base Abstract Class
Public MustInherit Class BaseRequestHandler : Inherits System.Web.UI.Page
Protected Overridable Sub Page_Load(ByVal sender As System.Object, ByVal e
As System.EventArgs) Handles MyBase.Load
SomeMethod()
End Sub
Public MustOverride Sub SomeMethod()
End Class
I have a Web Page which Inherits this base class
Public Class ManageCatalog : Inherits BaseRequestHandler
Public Overrides Sub SomeMethod()
'Code Block
end sub
end class
When I try to run it , I get the error
Compiler Error Message: BC30610: Class 'ManageCatalog_aspx' must either be
declared 'MustInherit' or override the following inherited 'MustOverride'
member(s): Public Overridable MustOverride Sub SomeMethod().
Plss Help.. I am doing something really stupid.. Tag: FAQ: How To Install Your Assembly in the GAC Tag: 55633
Using PropertyBuilder with a Dynamic Type
Using the example that microsoft gives in the VS documentation, creating a
property with the PropertyBuilder on a dynamic type will never allow it (the
property) to be exposed as public...only the get and set methods used on the
property show up as public. Has anyone found a way around this?
Thanks,
Tom J Tag: FAQ: How To Install Your Assembly in the GAC Tag: 55631
BinaryWriter.Seek() vs BinaryWriter.BaseStream.Seek()
Can anyone clarify the practical difference, if any, between
BinaryWriter.Seek() and BinaryWriter.BaseStream.Seek()? Under
what conditions might behavior of the two Seeks differ?
Or, can anyone answer: Why does BinaryWriter have it's
own Seek(), instead of using Seek() of contained Stream?
I am porting a desktop data analysis program to C#, and often
have both BinaryWriter / BinaryReader contain same FileStream.
I guess I should just use BinaryWriter.BaseStream.Seek(), since
it's there, but I'd like to know what is going on. I've read
various docs and books, and did not see the answer.
I know the methods don't override each other. Is the duplication
just a convenience? Is one or the other "preferred", and why?
And why is the offset argument int in one, long in the other??
Thanks,
Daniel Goldman Tag: FAQ: How To Install Your Assembly in the GAC Tag: 55622
Authoring non-ui Windows Forms controls
Anyone have an example that behaves similiarly to, say, an OpenFileDialog
control? Creating a control with no painting code just paints badly on the
form itself. But, an OpenFileDialog control (and many others) paint on a
window BELOW the form in the designer.
What's the trick to that? Anyone know? Tag: FAQ: How To Install Your Assembly in the GAC Tag: 55620
Going crazy over HTTP Post from class library
I am trying to do an HTTP POST to a webpage from a DLL. The webpage is
easily called, and a response is given. However, the web page is not
receiving the POSTed variables. None of them. Request.Form returns no
values. I have been over and over examples and have attempted to break my
code down to nothing. As of right now, I'm using the example just how I
found it, and still am having no luck. I'm using the .net framework v1.1.
Please advise.
EXAMPLE:
string lcUrl = "http://localhost/HTMLPDFWeb/testform.aspx";
HttpWebRequest loHttp =
(HttpWebRequest) WebRequest.Create(lcUrl);
// *** Send any POST data
string lcPostData =
"Name=" + HttpUtility.UrlEncode("Name") +
"&Company=" + HttpUtility.UrlEncode("Company");
loHttp.Method="POST";
byte [] lbPostBuffer =
System.Text.Encoding.GetEncoding(1252).GetBytes(lcPostData);
loHttp.ContentLength = lbPostBuffer.Length;
Stream loPostData = loHttp.GetRequestStream();
loPostData.Write(lbPostBuffer,0,lbPostBuffer.Length);
loPostData.Close();
HttpWebResponse loWebResponse = (HttpWebResponse) loHttp.GetResponse();
Encoding enc = System.Text.Encoding.GetEncoding(1252);
StreamReader loResponseStream = new
StreamReader(loWebResponse.GetResponseStream(),enc);
string lcHtml = loResponseStream.ReadToEnd();
loWebResponse.Close();
loResponseStream.Close(); Tag: FAQ: How To Install Your Assembly in the GAC Tag: 55617
.NET web applications on UNIX
This may seem like a wild one, but...
I have a potential client that wants us to develop a web
app on .NET and then port it over to UNIX.
My initial reaction is that the app would have to be
completely re-enginered for UNIX, but another developer I
spoke to said that they didn't think that was necessarily
the case.
Is there a relationship between .NET and UNIX that I'm
not aware of? Tag: FAQ: How To Install Your Assembly in the GAC Tag: 55614
Web Portal
Hey all.
I'm looking into creating a web portal that has a specific task. We have a
multi-user environment and each user has some network space on a mapped
drive. Through a login script, the user is automatically connected to their
network drive when they log into a computer on the LAN. What I would like
to do is have a web site that prompts a user for a username and password (if
you have every used Outlook Web Access, it would basally be the same thing).
Once the user is authenticated, they have access to their network drive.
Nothing else, only THEIR network drive.
The project was handed to me very open-ended. Basically, find a solution.
I'm not a web programmer by trade - I have some experience, but nothing as
advanced as what is being asked of me.
So, the first thing I'm looking at is what are my options? I was thinking
some sort of extranet setting, or some setup with .NET (if you are thinking
VPN as I was originally, that is out -- this is to be a web interface, not
VPN access). What are some other ideas out there? Does anyone have any
experience with such a thing? Are there any websites out there that may be
of assistance (preferably something that starts out simple and basic and
works its way up). I would ideally be looking for something already out
there vs. programming it.
Thanks in advance for your responses!!
Anthony Tag: FAQ: How To Install Your Assembly in the GAC Tag: 55612
Soliciting feedback on two features
I am collecting data for two features that shipped with the CLR in v1.0 and
v1.1. If you use and/or depend on these features, I would appreciate hearing
from you with a brief description of how you use these features.
1) .NET Application Restore tool
A few sources, including Jeffrey Richter's "Applied Microsoft .NET Framework
Programming" book, describe a feature called the "app restore tool", which
can be accessed via the .NET configuration tool. There is logging
information recorded for each managed application that runs, which can be
used by this tool to try to analyze any binding policy (e.g. binding
redirect) changes that affected the application, and suggest ways to get
your application back to an older state.
2) CacheLocation
This is a relatively obscure feature that allows relocation of the GAC via a
registry key setting. Support for this feature is limited, and there are a
variety of known problems when this feature is actually used.
Any comments you have would be apprecaited. Thanks.
.\lan
--
This posting is provided "AS IS" with no warranties, and confers no rights.
http://blogs.gotdotnet.com/alanshi Tag: FAQ: How To Install Your Assembly in the GAC Tag: 55611
Running C# program
I have C# program, what is the minimum setup required on
other PC (XP) to run C# (.NET) program. Do I need to put
Windows update for .Net on every system that I want to
run C# program? If not where can I find such package.
Thanks
lz Tag: FAQ: How To Install Your Assembly in the GAC Tag: 55599
TcpListener Problem
I have created a TcpListener object and I execute the
START and ACCEPTSOCKET method.
When a remote connection is made I execute the Socket's
RECEIVE method. The data I recived is what I expect.
The problem:
When I try to execute the SEND method the remote host
never gets my message.
Any Ideal what is wrong?
My Code
Dim LocalIP As IPEndPoint
Dim Server As TcpListener
Dim BytesRead As Int32
Dim txtMessage As String
Dim Replay As String = "HTTP/1.1 200 OK <CRLF><CRLF>"
Dim ReplayMsg() As Byte
'-- Set up IP and Port number
LocalIP = New IPEndPoint(IPAddress.Parse("127.0.0.1"),
1902)
Server = New TcpListener(LocalIP)
Server.Start()
sClient = Server.AcceptSocket
BytesRead = sClient.Receive(Buffer, 0, Buffer.Length, 0)
txtMessage = CType(Encoding.ASCII.GetString(Buffer, 0,
BytesRead), String)
ReplayMsg = Encoding.ASCII.GetBytes(Replay)
sClient.Send(ReplayMsg, ReplayMsg.Length, SocketFlags.None) Tag: FAQ: How To Install Your Assembly in the GAC Tag: 55598
c# applet
Hi,
Im trying to get a c# 'applet' to work. Like demonstrated here:
http://samples.gotdotnet.com/quickstart/winforms/Samples/IeSourcing/VB/IESourcing.htm
but I can't get it running on my local server (so security should not be a
problem)
I tried simple examples like:
http://www.csharphelp.com/archives/archive109.html
but all I get is an empty object box.
I use Visual Studio 2003 and windows 2000 professional.
I there anything else I need to know?
Do I need to sign the assembly of something?
Do I need windows server to run a proper IIS.
Could a different internal-external IP be a problem?
thnx in advance,
Paul. Tag: FAQ: How To Install Your Assembly in the GAC Tag: 55589
Design Question
I was looking for a clean way to have only get the Id of a reference
object within an object
The situation is when I want create an object for the purpose of adding it
to the db. In that case I dont want to create objects of all the reference
objects. IE. I want to create a new Address object to save. In the Db, I
only need the Id of the state object in order to save it. Not the entire
state object. I thought about adding a StateId in the Address object, but I
dont want that. I was also thinking of adding a constructor to set the Id
class BaseModel
{
int ID
{
get { return _id }
set (_id = Value }
}
}
class Address: BaseModel
{
string State
{
get { return _state }
set (_state = Value }
}
string City
{
get { return _city }
set (_city = Value }
}
}
class State: BaseModel
{
string Name
{
get { return _name }
set (_name = Value }
}
} Tag: FAQ: How To Install Your Assembly in the GAC Tag: 55588
Free tools for .net development
Hi all,
I'm searching for free and open source solutions to develop .net
applications for free.
I've found the SharpDevelop IDE (http://www.icsharpcode.net/OpenSource/SD/),
the WebMatrix IDE (http://asp.net/webmatrix/default.aspx), to develop in
ASP.net, SharpZipLib (http://www.icsharpcode.net/OpenSource/SD/), a library
to work with .zip files, and the Magic Library
(http://www.dotnetmagic.com/), an user interface library with advanced
controls.
But I didn't found a free DBMS and an UML tool, that works with .net code.
Does anyone knows if there's, and where can I find these tools?
Is MSDE free to any .net developer / project, or only for WebMatrix / Visual
Studio projects?
There's a visual tool (like the SQL Server Enterprise Manager) to work with
MSDE databases?
Any other tip about free tools are welcome.
Thanks in advance,
Fabrício de Novaes Kucinskis. Tag: FAQ: How To Install Your Assembly in the GAC Tag: 55586
Problem with .net not finding DLL file
We are using a dll file EHLLAPI.dll, and .net (version 1.0) sporadically
cannot find the DLL at runtime. The DLL is clearly present, and is in the
same directory as the executable. This seems to happen randomly for some
users. This is a windows forms application. Any ideas?
An exception of the following type occurred: System.IO.FileNotFoundException
User Comments:
Stack Trace From Exception:
at System.Reflection.Assembly.nLoad(AssemblyName fileName, String codeBase,
Boolean isStringized, Evidence assemblySecurity, Boolean
throwOnFileNotFound, Assembly locationHint, StackCrawlMark& stackMark)
at System.Reflection.Assembly.InternalLoad(AssemblyName assemblyRef, Boolean
stringized, Evidence assemblySecurity, StackCrawlMark& stackMark)
at System.Reflection.Assembly.LoadFrom(String assemblyFile, Evidence
securityEvidence)
at EHLLAPI.HostStream..ctor(Int32 timeLimit)
at ContactCenterDesktop.Launch.TotalLaunchOperation.execute(Contact contact,
Application appl, Hashtable properties)
at ContactCenterDesktop.Launch.Operation.executeOperation(Contact contact,
Application app, Hashtable properties)
at Workflows.Commands.LaunchAppCommand.doIt()
Exception Information:
Exception Message: File or assembly name EHLLAPI.DLL, or one of its
dependencies, was not found. Exception Source: mscorlib Exception Method:
[mscorlib]System.Reflection.Assembly::nLoad() Tag: FAQ: How To Install Your Assembly in the GAC Tag: 55581
Controls.Clear() fail
I have a TabPage control in a Form that I want to
add/remove TabPages to/from like:
TabControl tabControl1;
TabPage tabPage1;
TabPage tabPage2;
// Add tabs
tabControl1.TabPages.Add(tabPage1);
tabControl1.TabPages.Add(tabPage2);
I now want to remove tabPage2:
tabControl1.TabPages.Remove(tabPage2);
Now clicking the 'X' on the caption bar fails to close the
window. I DO NOT want to Dispose tabPage2, which may fix
the bug. Do You have a solution? Is this a known bug? When
will it be fixed?
Thanks, Jens Tag: FAQ: How To Install Your Assembly in the GAC Tag: 55576
Datagrid help
Hi all,
How can I use the OnItemCommand in the codebehind section of the webform i.e
in a function or a procedure , not in the html generated code.
Many Thanks
Sulafa Malik Tag: FAQ: How To Install Your Assembly in the GAC Tag: 55568
no touch deployment of crystal viewer
I'm looking at the possibility of distributing a crystal report viewer
control within an application on our intranet using "no-touch deployment".
It'll be internally only, and the crystal.net license documents appear to
suggest I can do this, as it's "free runtime"
I'm running into problems though since the dlls aren't part of the standard
.NET runtime install and even with FullTrust for the web launched forms app
I'm still getting security exceptions loading the crystal dlls. I've come
across the Assembly.LoadFrom methods, but I can't yet see just how to employ
this to load the crystal dlls from a web folder at the right time. I've set
the crystal dlls to copy local, yet still no joy. Has anyone had any
experience of doing something like this or who could point me in the right
direction vis-á-vis internal dll references in an http distributed app, or
even conversion of code to enable such functionality. Tag: FAQ: How To Install Your Assembly in the GAC Tag: 55567
Connecting to Oracle DB in Sun Server (Solaris OS)
Hi Guys,
I'm currently interfacing .NET windows application to
connect to Oracle DB in my test server running in windows
2000 server using .NET Oracle provider and it works fine.
Since our production server is running under Sun Server
with Solaris OS, Do I need to configure something (besides
the server name) with my connection string when I connect
to production server which is running in Sun Solaris?
My .NET windows application is running in Windows 2000
platform.
Thanks,
Rod Tag: FAQ: How To Install Your Assembly in the GAC Tag: 55552
Loading UI Controls
Our Windows.Forms user interface uses UserControls for the different parts
of the application. The UserControls present a starting point for entity
maintenance, data display, and data colleciton and displays related forms.
We have constructed a launcher application that among other things creates a
new Panel and Tab item when user's select options from a TreeView. The
selected UserControl is loaded from a separate assembly and the object is
created using CreateInstance then the UserControl is added to the Panel's
control collection. The Tab item is used to select the loaded UserControl's
that are basically stacked on top of each other, contained in their Panel's.
All of the UserControl Panel's belong to one static Panel that is used as a
work area.
Everything works great except that this is all happening in one AppDomain
and after these UserControls are destroyed none of the resources are being
collected so naturally we eventually run out of memory.
Using separate AppDomains for each UserControl seems like the way to go so
that the AppDomains can be unloaded and resources freed. Although we were
anticipating the next problem we continued down this path anyways. We can
create the UserControls in separate AppDomains but Windows.Forms doesn't
like it when we go to add the UserControl, in it's own AppDomain, to a Panel
that is in the default AppDomain and we get the message:
'Remoting cannot find field parent on type System.Windows.Forms.Control.'
Apparently, this property is not exposed through the TransparentProxy of the
UserControl to the launcher application.
Questions:
1. How can we load these UserControls in a separate AppDomain in order to
free resources after they are destroyed?
2. Can we expose all of the members of the UserControl through the proxy so
that Windows.Forms can utilize whatever members are need to site and manage
the UserControl in the second AppDomain from a control container in the
first AppDomain?
3. Is there another method that could be used to load UI controls from
separate assemblies and still be able to free resources after they are
destroyed?
Thanks,
Brian O'Neil Tag: FAQ: How To Install Your Assembly in the GAC Tag: 55546
BUG : Deployment Launch Conditions - Help
I am having a real problem with the Launch conditions in VS .NET and can
only come to the conclusion that it is a bug.
It states quite emphatically in the MSDN that Launch Conditions WILL be
executed in the order added. This statement holds true if every Condition
has a InstallURL value set. but not if there is no InstallURL value.
For Example :
I want to check that W2K exists on the target machine before installing SP4.
So, I add a Launch condition to check if versionNT=500.
I leave the InstallURL Blank as you are supposed to if you do not want the
user to continue and just display the OK button to terminate.
This works fine by itself
I add another Launch condition which check for SP4 viz. ServicePackLevel >=4
which has a InstallURL to enable me to install SP4 if it does not exist (ie
sp1, 2, 3 is installed)
As soon as I add it it jumps the queue and trie to install SP4 before even
checking in W2k is installed. ???
Add a MDAC Check with option to install and it executes after the SP4 check
(good)
remove the SP4 Checks InstallUrl (ie quit if SP4 or greater not found)
and MDAC jumps the queue.
This is a problem as I do not want to put a installURL in for W2K Check as I
don't want to install W2K (or the app) if the user is running W9x or NT or
XP and I definately don't want to install the SP if W2k does not exist
(granted that the SP install will moan, but too late!)
Things I have tried :
Launch condition addition in sequence of supposed execution ( no good)
Alphabetical Naming sequence, any addition order (no good)
Alphabetical Naming sequence with the correct addition order (no good)
Physically Editing and Swopping (in notepad) the entries n the .vdproj file
(no good)
Adding the W2K check into the default Framework Check section (which happens
before anything anyway) (no good)
Not that it makes a difference but the application I am building a package
for is written in C#...
Any Help on the matter would be greatly appreciated.
My Systems (tried it on all of them) :
All have the following Software : (and one JUST have this software, nothing
else so its nice and fresh)
~~~~~~~~~~~~~~~~~~~~~~
W2k SP4
VS.NET Architect edition
.Net Framework 1.1 (version : 1.1.4322)
Microsoft Development Environment (version : 7.1.3088)
Microsoft Visual C# .NET 69586-335-0000007-18303
Microsoft Visual Basic .NET 69586-335-0000007-18303
Microsoft Visual J# .NET 69586-335-0000007-18303
Crystal Reports for Visual Studio .NET AAP50-GS00000-U7000RN
IE6 sp1 (required by the VS.NET install)
All the VS.NET stuff is the latest that came with the 2003 MSDN
subscription.
Different Hardware
~~~~~~~~~~~~~~
Compaq P4 2.1GHz
512Mb DDR Ram
40GB HD
Dell Laptop P4 2.4GHz
512MB DDR Ram
40gb HD
Celeron 2.3GH
512MB DDR Ram
80GB HD Tag: FAQ: How To Install Your Assembly in the GAC Tag: 55542
Version 1.1.4322.0 vs 1.1.4322.573
All,
Is there any difference in the code of the version
1.1.4322.0 vs 1.1.4322.573 (the one available at MS
Windows Update site)?
All of our server got 1.1.4322.0 but one of them got the
update from the website and has 1.1.4322.537.
Any concern/ideas?
Thanks
Ari Ott. Tag: FAQ: How To Install Your Assembly in the GAC Tag: 55535