|
I add hyperlink in gridview and i pass the navigationURL for this hyperlink
but i want to send the rowindex of the gridview in session when i click this hyperlink
HOW CAN I DO THIS?
thanks for help
MD_NADA
|
|
|
|
|
Hi MD_Nada,
Can you post your navigationURL that you are passing in the hyperlink?
In the meantime:
You can send your rowindex id in the URL string itself. For eg: you want to access myhyperlinkpage.aspx your URL string will be - http://xyz/myhyperlinkpage.aspx?id={0} , this will pass the id or the rowindex of that row.
Also, do not forget to add your id or primary key of your table in the 'DataKeyNames' property of your gridview.
If this explanation is not too clear, kindly post your URL.
Aartee.
...HE is watching Us All!
|
|
|
|
|
thanks for ur help
MD_NADA
|
|
|
|
|
hi all,
What does it mean that view state is 32 bit encoded ??
whay specifically 32 bit is used any way ??
and can i see any meaningfull information from view state ??
Thanks for your help
Davids Maguire
|
|
|
|
|
View state is base 64 encoded. It means that the bits of raw viewstate are taken 6 at a time (you need 6 bits to represent 64 numbers [0-63]) and encoded into a string of characters.
When we count we use base 10: 0, 1, 2, 3, 4, 5, 6, 7, 8, 9 and then we add a column for 10 and so on.
That base does not align with with a power of 2 and so does not align with the bits in a numerical representation in a computer.
Two common bases to get around this are base 8 (octal) and base 16 (hexadecimal, or just hex). In Hex the count goes: 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, A, B, C, D, E, F and then we add a column for 10 (which is actually 16 in base 10) and so on.
Base 64 is just an extension of this with 64 symbols representing the numbers 0 to 63.
|
|
|
|
|
Colin Angus Mackay wrote: When we count we use base 10: 0, 1, 2, 3, 4, 5, 6, 7, 8, 9 and then we add a column for 10 and so on.
That base does not align with with a power of 2 and so does not align with the bits in a numerical representation in a computer
what column do you mean ??
and what base ??
and why not align with the power of 2 ??
i need a way to understand this technical speaking .. any help please
colin , Thanks so much for your help any way
|
|
|
|
|
DavidsMaguire wrote: what column do you mean ??
In base 10 you have a units column, a tens column, a hundreds column, a thousands column, a tens-of-thousands column and so on.
DavidsMaguire wrote: and what base ??
What do you mean what base? - the part you quotes was base 10. The counting system we use
DavidsMaguire wrote: and why not align with the power of 2 ??
Because we have 10 fingers (probably) and that is how, historically, we have counted in our number system.
I get the feeling there is some context missing in your questions. Please clarify what you are asking.
|
|
|
|
|
Colin Angus Mackay wrote: Because we have 10 fingers (probably)
And strangely. It would be much more practical to use base 6, then we could count ones on one hand and tens (six's) on the other, in an abacus like fashion. That way we could easily count to 35 (55 in base 6) using our two hands, instead of only ten.
If we look at it another way; why don't we have one digit for each digit? That would make it natural to use base 11, not base 10.
---
single minded; short sighted; long gone;
|
|
|
|
|
hi colin ,
hope you still there !!
any way .. i mean why specifically view state is base64 encoded ??
and if there an example about how the encoding goes ??
My regards
Davids Maguire
|
|
|
|
|
DavidsMaguire wrote: any way .. i mean why specifically view state is base64 encoded ??
I'm guessing because that is how binary data is typically encoded when transmitted through protocols such as HTTP. It is reasonably efficient and isn't subject to odd encoding problems if the text changes code pages and so on. (it only uses 0-9, a-z, A-Z and a few other symbols)
DavidsMaguire wrote: and if there an example about how the encoding goes ??
You'll probably get a better and more comprehensive answer here: http://en.wikipedia.org/wiki/Base64[^]
There are methods in the .NET framework to convert between base 64 and binary already, so it isn't something you'll need to write yourself. See the methods on the Convert class[^]
|
|
|
|
|
How to fire button click event from onmouseover event with javascript
|
|
|
|
|
Just use the click method:
<input type="button" value="Very sensetive!" onmouse0ver="this.click();" />
(The "0" on the event name is there to prevent the forum from changing the text. Replace it with an "o".)
---
single minded; short sighted; long gone;
|
|
|
|
|
Thanks so much in ur reply...
I forgot to say the button is asp control,
I already found solution
Button1.Attributes.Add("OnMouseOver", "document.all." + this.Button1.ClientID + ".focus();document.all." + this.Button1.ClientID + ".click();");
|
|
|
|
|
You don't have to find out the id of the element, as you can use the keyword this to reference it:
Button1.Attributes.Add("onmouseover", "this.focus();this.click();");
Besides, your code only worked in Internet Explorer, as the all collection is non-standard.
---
single minded; short sighted; long gone;
|
|
|
|
|
Hi all,
I am trying to open an aspx file exist in a server in my work, this file is running good without any errors only locally, but when I wanna open after moving it to the server, it does not work and and gives me the following error:
Configuration Error
Description: An error occurred during the processing of a configuration file required to service this request. Please review the specific error details below and modify your configuration file appropriately.
Parser Error Message: It is an error to use a section registered as allowDefinition='MachineToApplication' beyond application level. This error can be caused by a virtual directory not being configured as an application in IIS.
Source Error:
Line 37: by Microsoft that offers a single logon and core profile services for member sites.
Line 38: -->
Line 39: <authentication mode="Windows">
Line 40:
Line 41:
Source File: C:\Inetpub\wwwroot\pcbs\TestAsp\web.config Line: 39
--------------------------------------------------------------------------------
Version Information: Microsoft .NET Framework Version:1.1.4322.2032; ASP.NET Version:1.1.4322.2032
plz help me to solve this problem
Kind Regards
OBarahmeh
Palestinian Central Bureau of Statistics (PCBS)
Ramallah-Palestinian Territory
|
|
|
|
|
Hi OBarahmeh,
I have had this error once in the recent past, from my experience regarding this error I would say that you haven't created a 'Virtual Directory' for your application in the IIS server.
applications always run locally even if VD is not created but you will have to create a VD for the appln to run on your server.
Go to:
IIS Manager-->yourserevr(localcomputer)-->WebSites-->defaultWebsites-->Rightclick YourApplication --> Properties-->Create
I am sure you know this(path) already, but I included just-in-case...
Good Luck.
Aartee.
...HE is watching Us All!
|
|
|
|
|
Hi!
Dear fellow ... i m building an application in visual studio 2003 in C# asp .net web application ....
I had a tree view in one frame and i open new forms accoring to the clik of the tree view But i have to fill this form after capturing the click event of the tree view as i need the value of that particular clicked node so that i may retrive my data From my DB according to that cliked node ........i dont know how to capture the events too please send me code in C#.... instead of asp
Thanx
|
|
|
|
|
Hi!
Dear fellow ... i m building an application in visual studio 2003 in C# asp .net web application ....
I had a tree view in one frame and i open new forms accoring to the clik of the tree view But i have to fill this form after capturing the click event of the tree view as i need the value of that particular clicked node so that i may retrive my data From my DB according to that cliked node ........i dont know how to capture the events too please send me code in C#.... instead of asp
Thanx
|
|
|
|
|
Hi,
I've been using ASP.NET for almost 3 years now, but never did any decent testing. I downloaded NUnit and NUnitAsp, I'm new to unit testing, and would like to know other peoples opinions as well.
Does NUnitAsp work with .NET 2.0 because I only source the project files as 7.1, which means it is intended for VS2003. Are there any similar programs like NUnitAsp, or is this about the best?
Something else...
I quote from the overview section of NUnitAsp:
"NUnitAsp is for unit testing ASP.NET code-behind only. It's meant for programmers, not QA teams, and it's not very good for QA-style acceptance tests. It only tests server-side logic. JavaScript and other client-side code is ignored. But if you're using ASP.NET, it's an essential part of your programmers' toolset."
So what do the QA teams use? And are there programs that test JavaScript and client-sided code?
And lastly, NAnt, what is that used for?
I hope to hear from someone soon?
Take care.
ma se
|
|
|
|
|
i created a simple webservice
<br />
<WebMethod()> _<br />
Public Function HelloWorld(ByVal person As String) As String<br />
Return "Hello" + person<br />
End Function<br />
andi created a vb.net application that i jus wanted to post the name and get back the response
<br />
' Create the web request <br />
request = DirectCast(WebRequest.Create("http://localhost:80/WebService_RPC2"), HttpWebRequest)<br />
<br />
' Set type to POST <br />
request.Method = "POST"<br />
request.ContentType = "application/x-www-form-urlencoded"<br />
<br />
' Create a byte array of the data we want to send <br />
byteData = System.Text.UTF8Encoding.UTF8.GetBytes(data.ToString())<br />
<br />
' Set the content length in the request headers <br />
request.ContentLength = data.Length<br />
<br />
' Write data <br />
Try<br />
postStream = request.GetRequestStream()<br />
postStream.Write(byteData, 0, byteData.Length)<br />
Catch ex As Exception<br />
MessageBox.Show(ex.Message)<br />
Finally<br />
If Not postStream Is Nothing Then postStream.Close()<br />
End Try<br />
<br />
Try<br />
' Get response <br />
response = DirectCast(request.GetResponse(), HttpWebResponse)<br />
<br />
' Get the response stream into a reader <br />
reader = New StreamReader(response.GetResponseStream())<br />
<br />
' Console application output <br />
Console.WriteLine(reader.ReadToEnd())<br />
Catch ex As Exception<br />
MessageBox.Show(ex.Message)<br />
<br />
Finally<br />
If Not response Is Nothing Then response.Close()<br />
End Try<br />
<br />
Dim responseString As String = Convert.ToString(reader)<br />
but this doesn't work when i debug the code i see that the request goes through and no exception is thrown as soon as i try to read the response
response = DirectCast(request.GetResponse(), HttpWebResponse)
i get an exceptiong is thrown saying
Quote:
the remote server return an error405)Method Not allowed
can anyone tell me what i am doing wrong is there something i am not doing correcly from the webservice side?
-- modified at 23:53 Saturday 10th February, 2007
|
|
|
|
|
Hai,
Just started to work with Visual web developer 2005. I want to know how to change the background color of a textbox when it gets focus. Please provide step by step instruction in doing so.
Thanks
|
|
|
|
|
The TextBox control only exists on the server, in the browser all that exists is the html code that the control created, i.e. a form field. As getting focus is something that happens in the browser, you have to use Javascript for that, so it really has nothing to do with ASP.NET.
---
single minded; short sighted; long gone;
|
|
|
|
|
Visual Studio Professional 2005 - C# 2.0, ASP .Net
How do you go about sending reminder notices? I've got an application that the client wants to have a reminder for different tasks go out on various intervals.
Right now it's in an access.mdb file. If a user registers and completes a form we want to remind them that in X more days they need to complete another form. I know how to send the email and all that. What I don't understand is what mechanism you use to track time on a per row basis. Meaning row 136 was entered on February 12th, 7 days later something (what would be a good something) sees that and sends a reminder.
Suggestions? Ideas?
|
|
|
|
|
Ideally, you would write a Windows service to sit in the background and regularly check to see if any notifications need to be sent out.
If it were SQL Server, you could set up a Job to run at regular intervals.
However, if you're absolutely stuck, and out of options, and if the Web site receives a fair amount of evenly dispersed (time-wise) traffic, you can rely on the usage patterns to check for pending notifications. Not a great solution, and if traffic ever falls off, your notifications won't get sent out when they need to be.
I suppose you could also expose a public Web service, and then have an external app "ping" that Web service to tell the server to check for and send notifications.
|
|
|
|
|
Yeah, I was just going to write an .exe and run it at scheduled intervals using the Task Scheduling service. But those are all great ideas. If it is SQL Server (which it might be in production) do you have a link to more information?
|
|
|
|