Jump to content

aspnetguy

Members
  • Posts

    6,787
  • Joined

  • Last visited

Posts posted by aspnetguy

  1. instead do the following

    Dim mycommand As SqlCommand = new SqlCommand("query",myConnection)myConnection.Open()Dim dr As SqlDataReader = mycommand.ExecuteReader()While dr.Read  lblsubject_id.Text = dr.Item("ColumnName")End Whiledr.Close()myConnection.Close()

  2. okay so you applied that tot he "files" folder? Try checking the "Full Control" option for ASPNET. If that doesn't work apply "Full Control" tot he Everyone account for that folder. This is not recommended as it leaves your system open but we will do it just to see if the error is indeed permissions releated.

  3. I think his general position is that his browser is a third-generation browser because he says it is, and he doesn't have to follow any standards because no one called him to get his opinion when the standards were being discussed. Also, something about Microsoft, and he's old.
    :) thanks
  4. try this

    <html><head>	<title></title>	<script>			//clickable item ids		var items = ["item0","item1"];				//function to open and close items		function toggle()		{			//get item			var item = this.parentNode;	//note: this = anchor from attachEvents			//get subitem			var subitem = document.getElementById(item.id + "sub");			//toggle subitem			if(subitem.style.display == "none") //closed				//open it				subitem.style.display = "block";			else //open				//close it				subitem.style.display = "none";						//prevent anchor from following href			return false;		}				//function to attach events		function attachEvents()		{			for(i=0;i<items.length;i++)			{				//get next item				var item = document.getElementById(items[i]);				//get item anchor				var anchor = item.childNodes[0];				//attach onclick event				anchor.onclick = toggle;			}		}				//initial setup		function init()		{			//hide all sub items			for(i=0;i<items.length;i++)			{				//get next item				var item = document.getElementById(items[i]);				//get subitem				var subitem = document.getElementById(item.id + "sub");				//hide subitem				subitem.style.display = "none";				//indent subitem				subitem.style.paddingLeft = "10px"; 			}		}		</script></head><body>	<div id="menu">		<div id="item0"><a href="#">Item 0</a></div>		<div id="item0sub">			<div id="item00"><a href="#">Item 0.0</a></div>			<div id="item01"><a href="#">Item 0.1</a></div>			<div id="item02"><a href="#">Item 0.2</a></div>		</div>		<div id="item1"><a href="#">Item 1</a></div>		<div id="item1sub">			<div id="item10"><a href="#">Item 1.0</a></div>			<div id="item11"><a href="#">Item 1.1</a></div>			<div id="item12"><a href="#">Item 1.2</a></div>		</div>	</div>		<script>		init();		attachEvents();	</script></body></html>

  5. then use the instructions as is.

    Right click the target folder and choose Properties.Switch tot eh Security tab.If the ASPNET user is not shown in the list, add it.Click on the ASPNET user account and make sure that the Modify option is checked.
  6. I'll assume you are using Windows XP. If you are using Windows Server 2003 replace ASPNET with NETWORK SERVICE in the instructions below.Right click the target folder and choose Properties.Switch tot eh Security tab.If the ASPNET user is not shown in the list, add it.Click on the ASPNET user account and make sure that the Modify option is checked.

  7. do this so we can get the real error message

    Sub Upload_Click(source As Object, e As EventArgs)Dim savePath As String = "C:\Inetpub\wwwroot\tution\files"TryDim postedFile = uploadedFile.PostedFileDim filename As String = System.IO.Path.GetFileName(postedFile.FileName)Dim contentType As String = postedFile.ContentTypeDim contentLength As Integer = postedFile.ContentLengthpostedFile.SaveAs(savePath)message.Text = "uploaded"Catch exc As Exceptionmessage.Text = "uploade failed<br/><br/>" & exc.MessageEnd TryEnd Sub

    It is probably because the ASP.NET worker account does not have permission to write to the target folder.

  8. Whose favourite now?! Where the ###### did you get the impression we like Micro$oft? :)
    His strategy seems to be to throw out foolish and unrelated statements when someone disagrees or opposes his claims which only re-enforces how little he knows about what he is talking about.
  9. I can't stop laughing long enough to reply...If you have been in this industry so long then where have you been? Locked i n a basement? Web standards is at the core of designing for the web. A design noob knows this from the simple fact that their page looks different in different browsers.So how old are you, how long have you been programming? More than 25 years? Because to make your statement about having more experience than we are old would require you to be at least 40-45 and have 25+ years experience.I am 25 and have 7 years experience. I don't know everything but it is obvious I know far more about standards and designing and marketing than you do and I know enough to realize you are a complete joke.Why don't you go join a cooking forum or some other group that know nothing about programming or web standards, you might actually convince some of them about your ridiculous claims.

  10. I wrote an object to simulate HTMLElement.prototype in all browsersobject

    var DOMElement = 		{			extend: function(name,fn)			{				if(!document.all)					eval("HTMLElement.prototype." + name + " = fn");				else				{					//					//	IE doesn't allow access to HTMLElement					//	so we need to override 					//	*document.createElement					//	*document.getElementById					//	*document.getElementsByTagName					//								//take a copy of					//document.createElement					var _createElement = document.createElement;								//override document.createElement					document.createElement = function(tag)					{						var _elem = _createElement(tag);						eval("_elem." + name + " = fn");						return _elem;					}								//take copy of					//document.getElementById					var _getElementById = document.getElementById;								//override document.getElementById					document.getElementById = function(id)					{						var _elem = _getElementById(id);						eval("_elem." + name + " = fn");						return _elem;					}										//take copy of					//document.getElementsByTagName					var _getElementsByTagName = document.getElementsByTagName;								//override document.getElementsByTagName					document.getElementsByTagName = function(tag)					{						var _arr = _getElementsByTagName(tag);						for(var _elem=0;_elem<_arr.length;_elem++)							eval("_arr[_elem]." + name + " = fn");						return _arr;					}				}			}		};

    Here is some examples of how to use itexample

    <html><head>	<script type="text/javascript" src="DOMElement.js"></script>	<script type="text/javascript">			DOMElement.extend("foo",function(){alert('bar')});		DOMElement.extend("about","DOMElement v0.1")		DOMElement.extend("contents",function(){return this.innerHTML})		var elem = document.createElement("div");		elem.foo();				onload = function()		{			var elem2 = document.getElementById("myDiv");			alert(elem2.about);						var divs = document.getElementsByTagName("div");			for(var i=0;i<divs.length;i++)				alert(divs[i].contents())		}		</script></head><body>	<div id="myDiv">hi</div>	<div id="div2">there</div></body></html>

×
×
  • Create New...