
a_jam_sandwich
Avatar/Signature-
Posts
371 -
Joined
-
Last visited
Content Type
Profiles
Forums
Blogs
Events
Articles
Resources
Downloads
Gallery
Everything posted by a_jam_sandwich
-
To be honest it appears like its not seeing the DLL file and yes the control is within the WebApplication1.dll file it seems very strange I suggest it maybe a .NET security policy maybe try reinstalling the framework. Ill try on my webserver today this is also a win2003 server box with .NET 1.1 and let you know the results. EDIT: I have run the test on my dedicated webserver Test Server and this runs perfectly fine, it would seem like a setup or security policy error you have. Andy
-
Now that is strange. Just got home from work and tried it and it works perfectly no problems at all. if you look in the /BIN is there a webapplication1.dll file? Andy
-
Can you enable remote debugging as follow may give me some more insite Details: To enable the details of this specific error message to be viewable on remote machines, please create a <customErrors> tag within a "web.config" configuration file located in the root directory of the current web application. This <customErrors> tag should then have its "mode" attribute set to "Off". Thanks Andy
-
This is strange have you run it locally on your development PC and if so what the error you get off that? The source I uploaded compiled fine on my PC, may be another unrelated problem but running on you local PC should give a more detailed error EDIT: Did you recompile the source I uploaded because I didn't attach any .DLL files within the .zip Thanks Andy
-
You can make it work by the following first heres you control class using System.Web; using System.Web.UI; using System.Collections; using System.Web.UI.WebControls; using System.Text.RegularExpressions; namespace WebApplication1 { public class emailValidator: BaseValidator { private const string REGULAR_EXPRESSION = "^[a-zA-Z][\\w\\.-]*[a-zA-Z0-9]@[a-zA-Z0-9][\\w\\.-]*[a-zA-Z0-9]\\.[a-zA-Z][a-zA-Z\\.]*[a-zA-Z]$"; protected override bool EvaluateIsValid() { string val = this.GetControlValidationValue(this.ControlToValidate); try { return Regex.IsMatch(val, REGULAR_EXPRESSION); } catch { return false; } } } } The only difference I have made is that i've changed the namespace to the same as the web applications, just for ease. Now for registering the control on the page <%@ Register TagPrefix="emailValidator" Assembly="WebApplication1" Namespace="WebApplication1" %> Nice and simple just register the control in the same namespace as the application the control then is part of the main application DLL. This will the compile and run fine declaring the controls like <emailValidator:emailValidator id="RegularExpressionValidator1" runat="server" ErrorMessage="RegularExpressionValidator" ControlToValidate="TextBox1"></emailValidator:emailValidator> I've attached a webapplication to show Hope this helps Andy WebApplication1.zip
-
While I debug my usercontrols I tend to compile them all within the master project as usercontrol classes this enables me to put break points in this allows me to have a lot more control. Are you using VS2002/20003 or are you using a editor such as webmatrix? Thanks Andy
-
You can add break points in using the editor by clicking on the far left hand side of the line of code you wish to add a break point a small stop symbol will then be shown. Hope it helps Andy
-
You can do this using LDAP in the directoryservices for an example look here List Available Computers Hope that helps Andy
-
With aspx you can output to the debug console using debug.write/writeline as you would using the console commands. Just remember to import the right namespace as below import system.diagnostics Thanks Andy
-
I tend to code that way creating an API dll that deals with data into and out of the mail program but really it depends on how you want to code your application. For the smaller application the above is really overkill. But on a whole keeping all your database code in a class or module is a good way to code. Andy
-
If your getting 550 then the recepient is being rejected if your using exchange as you smtp relay then he need to edit the SMTP relay rules by Opening Exchange System Manager Expand Admistration Groups Expand First Administration Group Expand Servers Expand you current exchange server Expand Protocols Expand SMTP Right click on Default SMTP Virtual Sevrer and select properties Click on the Access Tab then click on the Relay button Click Add and add in the IP address of the PC sending the emails Click Ok, Ok Ok and your done exchange is setup for allowing relays from the IP sending the emails. if it IIS let me know and ill post the instructions for that. Regards Andy
-
You can prove this using telnet from the cmd prompt type telnet <smtp ip> 25 this will then allow you to send commands directly to the smtp server. Type the following in same case as below HELO server will respond .. 250 welcome ... MAIL FROM: <your from email address> server will respond .. 250 sender ok ... RCPT TO: <your to email address> The server should either respond with a 250 command which is the rcpt is accepted or another number like 550 where there is a relay problem. Hope this helps Andy
-
To be honest all you need on a page is a single literal and blast a template out to it. Any changable content could be replaced within the template. This works quite effectivally trust me. The only dam thing I hate about .NET it its stupid god dam editor VS2003 it has the most anoying feature every known got streight from Frontpage! It redesigns your design, make a XHML strict page in the VS2003 editor! no chance, apart from that which you can get round using an external program anyway .NET is very efficant but both languages have there place. Thanks Andy
-
Try that http://www.xtremedotnettalk.com/showthread.php?t=82600 the class uploads and downloads work in progress but works fine PM me if you need help with it Andy
-
Its a very usefull feature shrinks the code down nicely Andy
-
Try the following code Dim DirBase As New DirectoryInfo("c:\winnt") Dim di As DirectoryInfo() = DirBase.GetDirectories("*.*") Dim strDirs As New ArrayList For Each diTemp As DirectoryInfo In di strDirs.Add(diTemp.Name) Next diTemp For Each diNameTemp As String In strDirs Console.WriteLine(diNameTemp) Next Your problem was For Each strDirTemp In strDirs As you have strDirTemp declared as a arraylist when strDirs hows an arraylist of strings Andy
-
.Parameters.Item(0).Value = New Guid(strInvoiceID) Andy
-
Does no one know? it seems that I can only monitor variables local to the sub or function in the while loop on asp.net if a global varible is set somewhere else the sub or function doesn't seem to know? Anyone have any ideas to the weird problem Cheers Andy
-
I am writing a server monitor for asp.net and have run into a problem .. I have a function that waits until a varible is set or until a timeout happens see below Private Function WaitForResponseToBeSent() As Boolean ' This function monitors _ServerResponseReceived if a server ' has sent info then its set to true. If a timeout occurs then ' return false other wise return true Dim StartTime As Long = Environment.TickCount While (_ServerResponseReceived = False) And ((Environment.TickCount - StartTime) < 5000) '_Timeout) Application.DoEvents() End While If (_ServerResponseReceived = False) Then Return False Else Return True End Function Now Application.DoEvents does not work in a asp.net app as far as I can see so the loop times out when commenting out Application.DoEvents Now if I place Debug.WriteLine("IN LOOP") within the loop like below the response comes through and doesn't time out so what do I need to do? Private Function WaitForResponseToBeSent() As Boolean ' This function monitors _ServerResponseReceived if a server ' has sent info then its set to true. If a timeout occurs then ' return false other wise return true Dim StartTime As Long = Environment.TickCount While (_ServerResponseReceived = False) And ((Environment.TickCount - StartTime) < 5000) '_Timeout) Debug.WriteLine("IN LOOP") End While If (_ServerResponseReceived = False) Then Return False Else Return True End Function Thanks Andy
-
For anyone who is intrested on geting you game server details and player on the web I thought you might like the class ive been working on. I included a demo project that places the details in a textbox for now. Supports Halflife All quake3 games (inc call of duty, enemy teritory, jedi knight 2 ...) UT2004 demo More to come.... All the source is included have fun fun fun Andy :D hludp.zip
-
you could send the first message to your self on the from address rest BCC'ed Just look in google dunno if this helps multi threaded mail shot http://www.emailarchitect.net/webapp/smtpcom/developers/netpool.asp Andy
-
Why not use the BCC on the mail object and semicolon each address in the list and send out only one email Andy btw- keep in mind if there is nothing in the to of the email some programs see the message as spam
-
I take it your creating a ftp client if so your commands to the server need to end with a caridge return and linefeed so encode the send string like the following... Dim Str As Byte() = Encoding.ASCII.GetBytes("USER Oth" & VbCrLf) also the socket will wait forever at the point unless the server sends data. try tracing through the code using the step debugger Andy
-
Arh I see my mistake Andy
-
Bump mapping I belive Andy