|
Can u pl. tellme how to give onblur event of textbox in .cs page
Prya
|
|
|
|
|
you can do it like this:
Textbox1.attributes.add(OnBlur,"Javascript:yourfunc();")
Best Regards,
Apurva Kaushal
|
|
|
|
|
i have included master page in that aspx page. so there is a tag
<asp:content>. So shall i place the and tags above this and write the function there. But when I tried in some where its giving problem while adding head tags before content tag.
<div class="ForumSig">Prya</div>
|
|
|
|
|
I think you can put the function there in the head tag itself. What is the problem you are getting on doing the same.
Best Regards,
Apurva Kaushal
|
|
|
|
|
The Error I am getting is:
Content is not supported outside 'script' or 'asp:content' regions.
Prya
|
|
|
|
|
Try it by putting it inside the <asp:content> tag.
Best Regards,
Apurva Kaushal
|
|
|
|
|
you can add the javsscript function inside the <asp:content> tag.
call that javascript function with the help of .cs file.
Pankaj Gupta
(Take it easy)
|
|
|
|
|
Hi guys
I am stuck in one problem. I have table called folder. in that i am storing information of all folders that are made by users. i have one field in this table called parentfolderid. so by that i can store parent folder's id in my table so that i can have hierarchy of folders.
Now my problem is that there can be sub folders in the folder so by following code i get value upto second level but if there is hierarchy like
Root folder --> parent folder --> child folder --> grand child folder
Then it will not handle in my code so if any one can help me i would be very pleased.
--------CODE---------
Try
dr = temp.ExecuteDataReader("Select * from Folder where ID = ParentFolderID")
While dr.Read
Dim tNode As New TreeNode
tNode.Text = dr("Name")
Root = dr("ID")
Tree1.Nodes.Add(tNode)
Try
dr1 = dbaccess.ExecuteDataReader("Select * from Folder where ID <> ParentFolderID and ParentFolderID = '" & Root.ToString & "'")
While dr1.Read
Dim tChileNode1 As New TreeNode()
tChileNode1.Text = dr1("Name")
tNode.ChildNodes.Add(tChileNode1)
End While
Catch ex As Exception
Finally
dr1.Close()
End Try
End While
Catch ex As Exception
MsgBox(ex.Message)
Finally
dr.Close()
End Try
Please help me
|
|
|
|
|
|
|
Please read "How to get an answer to your question" in the top of the message board
Best Regards
3ala2
|
|
|
|
|
Hi prameela...
The .NET framework created by Microsoft is a software development platform focused on rapid application development, platform independence and network transparency.The .NET Framework is an environment for building, deploying, and running Web Services and other applications. It consists of three main parts: the Common Language Runtime, the Framework classes, and ASP.NET.
Cheer
Pavan Pareta
|
|
|
|
|
Hi Prameela,
i am also new to this .net technology. just i started reading .net. i will try to explain u what is .Net Framework.
.Net Frame work is an Environment for building, deploying, and running Applications (and also Webservices).
it is a software development plotform focused onrapid application development, platform independance and network transperancy.
in my own way i can tell u that the .net applications do not access the Operationg system directly, instead they use services of .net Framework.
using .net framework we can devlop the application using multiple languages. we can use the components which are developed in the language which is different from the language in whcih we are developing our application.
hope u got the basic idea about .Net Framework.
Regards,
Rahi
Judge your success by what you had to give up in order getting it.
|
|
|
|
|
I have two directories in the same root folder. Here's the structure...
Path Parent: D:\vhosts\somedomain
Path Child 1: D:\vhosts\somedomain\httpdocs\images\
Path Child 2: D:\vhotsts\somedomain\subdomains\admin\httpdocs\tools\modify.aspx
In Child 1 {somedomain} is the virtualdirectory for http://www.somedomain.com.
In Child 2 {admin} is the subdomain and virtual directory for http://admin.somedomain.com
Can I using some method of UNC paths, Physical Paths, Etc... Set things up in some way such that modify.aspx in Child 2 can upload images into \images\ in Child 1? Both have the same IUSR and IWAM and IUSR has read-write to \images\ in Child 1.
How do I map the call in my custom WriteToFile("\\machinename\\sharedfolder\\" + filename, fileresource) so that I can get the image uploaded into path Child 1 \images\?
If this is confusing I'm happy to clarify anything.
|
|
|
|
|
I am using Visual Studio 2005 to develop a client side control. However, after 3 days, I have yet to discover a reliable way to get it to download into the client side GAC. It does so only about 2% of the time, regardless of whether the control has changed. If any version has already downloaded, then I have to use "gacutil" to clear the GAC download cache before any successive version will install. I cannot seem to find any help online or in books about this either. It is as if no one is trying to develop custom downloadable client side controls (I am not talking about wrapping an html page around edisting web controls). This is a .NET activex-like control... a pure WinForm .NET assembly... not a COM wrapper.
|
|
|
|
|
Hi
Got a Q:
How do i insert eg. Customer info into a database from a web application?
, by using Visual Studio in ASP.Net (VB)
Thanx
-- modified at 16:01 Tuesday 31st October, 2006
|
|
|
|
|
You can take from This[^]
Best Regards,
Apurva Kaushal
|
|
|
|
|
I am having trouble ftp'ing a file from my local hard drive (ftptest.txt) to a mainframe system. I can command-line ftp the file fine, but I can't seem to ftp from ASP.NET 2.0. I keep getting error:
"The remote server returned an error: (501) Syntax error in parameters or arguments.".
here is my code:
' Get the object used to communicate with the server.
Dim request As FtpWebRequest = FtpWebRequest.Create("ftp://ibmmain/")
request.Method = WebRequestMethods.Ftp.UploadFile
' This example assumes the FTP site uses anonymous logon.
request.Credentials = New NetworkCredential("rme", "geac1", "ibmmain")
' Copy the contents of the file to the request stream.
Dim sourceStream As StreamReader = New StreamReader("C:\RME.LGNGEAC.EXTRACT")
Dim fileContents As Byte() = Encoding.UTF8.GetBytes(sourceStream.ReadToEnd())
sourceStream.Close()
request.ContentLength = fileContents.Length
Dim requestStream As Stream = request.GetRequestStream()
Any help would be appreciated.
regards,
RLevron
|
|
|
|
|
hi friends,
I'm trying a program in ASP.net where I need to connect to access Database dynamically.I've a gridview which'll display the results of a select statement. Can you please tell me all the steps involved in connecting to the database and displaying the results in a gridview ?
I'm new to asp.net & hence please provide all the steps that I need to do in order to get the output.
Thanks in advance...
Thank you all for your help..
|
|
|
|
|
Hi There are many ways to connect to database in ASP.net. Instead of telling you about my logic I would prefer you to use Microsoft Standards and tutorial for this.
Please visit http://asp.net/learn/dataaccess/default.aspx?tabid=63[^]
Regards
Tayyab
Lets work it Out.........!
|
|
|
|
|
Thanks Tayyab,
It's a great site.Got to work on DataAdapters,DataTables ,Datasets etc...It was wonderful to see the outputs..
Thanks a lot...
|
|
|
|
|
Hi. I need advice on a manner;
There are lots of items, that I must count for user hits on them. I use mssql to handle item and hit data. There is need to update hit value on time. There for best performance which way is the best? Or could you give a better advice?
1. make an global array in application state and gather hit values for items in this array. When the array total hit count reaches to a big value (for ex: 10000 hits counted). Make update to all items hit field in the database with;
(1.a) with a loop over hit array
(1.b) write a sql text file and triger mssql to execute this sql command file.
2. update item hit value on every hit
item_table
<br />
id | hit<br />
----------- <br />
1 | 54<br />
2 | 48<br />
3 | 13<br />
4 | 80<br />
.<br />
.<br />
.
thanx
karanba
|
|
|
|
|
I think that the first option is better but u don't need to make it like 1000 because if the server is restarted or any other technical problem occured the values will be resetted ...
Best Regards
3ala2
|
|
|
|
|
Hi friends,
Is there any way to lock ur computer with asp.net????
I mean ...i want the computer of client to be locked if he is idle for some 10 minutes...am not asking about sessions....i want the whole computer should be locked....can any of you great .net programmers solve this problem??....plz give me a way....its very urgent and it will be really a great help for me....plz once again and thanks in advance....
Live Life King Size
Asif
|
|
|
|
|
Hi
I have an asp.net 2.0 project and am experiencing a problem.
In the project, I am trying to make use of Membership.
I have one Role, called "Basic User" and two users - "admin" and "test".
"admin" is a member of the Role but "test" is not.
I have only a few pages in the project at the moment: -
• SecurePage.aspx - The page I want only authenticated users that are members of the Role to use.
• Login.aspx - Login page
• Unauthorized.aspx - Informs user that they cannot view the secure page because of a lack of permissions
SecurePage.aspx just contains a ChangePassword control.
Unauthorized.aspx has some text and a LoginStatus control.
So in the SecurePage.aspx, I have this code to handle this: -
Protected Sub form1_Load(ByVal sender As Object, ByVal e As System.EventArgs)
If User.Identity.IsAuthenticated = False Then
Server.Transfer("login.aspx")
End If
If Roles.IsUserInRole("Basic User") = False Then
Server.Transfer("unauthorized.aspx")
End If
End Sub
If I go to the SecurePage and am not authenticated, it transfers me to login.aspx.
If I then login with the user "admin", which is in the Role "Basic User", it works ok.
If I first login with "test", which is NOT in the Role, then I am transfered to the "unauthorized.aspx" page.
However, if I click "Logout" on the LoginStatus control on the "unauthorized" page it refreshes and changes to display "Login".
So, if I then click "Login", I am taken back to the login page. The URL in the address bar at this point is: -
http://localhost:1489/Lesson09/login.aspx?ReturnUrl=%2funauthorized.aspx
If I then login with using "admin" - which is a member of the Role - this is where I get a problem.
Instead of being taken to the SecurePage.aspx as expected, I get taken back to the "unauthorized.aspx" page.
This is obviously wrong.
Now, I know that this should work but does anybody know why it is not working?
Is there some settings or something I need to change on my PC? Am I missing a step or not doing something?
I've checked the obvious things - like that the user was actually in the Role etc.
However, I just cannot get this to work.
I am new to ASP.Net and so I don't really know where to start to look for what the problem is?
I have gone through re-doing the project twice now and I still get the same problem.
For info, I am using: -
- Visual Studio .Net 2005 (Professional) (up to date)
- Latest .Net installed
- Windows XP Pro
- Internet Explorer 6 (version 6.0.2900.2180.xpsp_sp2_gdr.050301-1519) SP2
I would very much appreciate any help or advice on this problem.
Thanks in advance.
Kind regards
Darren Brook
email: darrenbrook@btconnect.com
|
|
|
|