|
Hi,
By using the Javascript we can able to do this. Just check the below code help's you.
<title>Untitled Document
function clock()
{
var date = new Date()
var hour = date.getHours()
var minute = date.getMinutes()
var second = date.getSeconds()
if (hour > 12) {
hour = hour - 12
}
if (minute < 10) {
minute = "0" + minute
}
if (second < 10) {
second = "0" + second
}
document.f.txt.value = hour + ":" + minute + ":" + second
setTimeout("clock()", 1000)
}
If you want more just visit the link:
http://www.codegrounds.com/articles/2/1/Client-Side-system-time-using-Javascript[^]
Know is Drop, Unknown is Ocean
|
|
|
|
|
how can i apply 'bold' to the selected text in label control.
After some navigation to other pages,when i come back to label control page,that bold should remain as it is to the selected text.
kamalnath
|
|
|
|
|
HI Guys can any any one plz let me know the reason for this Dot net run time exception
"The description for Event ID ( 0 ) in Source ( .NET Runtime ) cannot be found. The local computer may not have the necessary registry information or message DLL files to display messages from a remote computer. The following information is part of the event: .NET Runtime version 1.1.4322.2032- Setup Error: Failed to load resources from resource file Please check your Setup."
thankx in advance for ur help.
|
|
|
|
|
hello all,
how to export data to excel and import data from excel "cell by cell"
without using interop components(owc) or any 3rd party component,pls let me knw
Regards,
Kavitha
|
|
|
|
|
IMO, the simple option is to use the Excel document in the XML format, if the Excel file is in the native format, then you need to learn the this format to work with it as you don't want to use either the automation or a third party.
|
|
|
|
|
Thanks for your reply.
Buti have no clue about IMO,can u pls explain how to go about
|
|
|
|
|
|
module file does not exist in asp.net 2.0 with vb.net 2.0 ???
|
|
|
|
|
Is that a question? Can you be more specific about your context?
|
|
|
|
|
Hi guys can any one let me know what is the memory limitation of asp.net worker process, i am facing problem that when the asp.net worker process in which my application is running starts consuming large amount of memory, the asp.net worker process is reset, plzzzzz let me know ASAP the memory limitation of ASP.Net worker process.
|
|
|
|
|
You might want to see the memoryLimit attribute of the processModel[^] element.
|
|
|
|
|
How to nest the grids? In one grid view I need to see another grid? Thanks in advance...
Kokila
|
|
|
|
|
|
Hi,
I'm new using cookies, I have been trying or testing one with no luck, please see the code below and tell me what I'm doing wrong. Just to let you know, my IE settings allow me to accept cookies.
This is the default.aspx page
Public index As Integer
Public viewexistingcookies As Boolean
Private Sub Page_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
index = IIf(Request("index") Is Nothing, 0, Convert.ToInt32(Request("index")))
viewexistingcookies = IIf(Request("vc") Is Nothing, False, Convert.ToBoolean(Request("vc")))
If Not (Page.IsPostBack) Then
SetGetCookie()
If viewexistingcookies Then
ViewCookies()
End If
End If
Me.HeaderMostrarInformacionDeUsuario = True
Me.HeaderInformaciondeUsuario = Session("FirstName") 'It could be assigned directly from the cookie
Me.HeaderSubMenuOptions = Tools.GetSubMenuItems
Me.HeaderSubMenuSelectedOption = index
End Sub 'Page_Load
Private Sub SetGetCookie()
If Not Request.Cookies("p26m") Is Nothing Then
Dim cookie As HttpCookie = Request.Cookies("p26m")
Session("FirstName") = Server.HtmlEncode(cookie.Values("firstname")) & "</b>"
Else
Dim cookie As New HttpCookie("p26m")
cookie.Expires = Date.Now.AddYears(1)
cookie.Secure = True
'I'm adding this values for now, they will come from a registration form
cookie.Values.Add("firstname", "David")
cookie.Values.Add("lastname", "Gonzalez")
cookie.Values.Add("email", "dgonzale@med.miami.edu")
Response.AppendCookie(cookie)
End If
End Sub 'SetGetCookie
'I'm using this routine to get current cookies
Public Sub ViewCookies()
Dim loop1, loop2 As Integer
Dim arr1(), arr2() As String
Dim MyCookieColl As HttpCookieCollection
Dim MyCookie As HttpCookie
MyCookieColl = Request.Cookies
' Capture all cookie names into a string array.
arr1 = MyCookieColl.AllKeys
' Grab individual cookie objects by cookie name
For loop1 = 0 To arr1.GetUpperBound(0)
MyCookie = MyCookieColl(arr1(loop1))
Response.Write("Cookie: " & MyCookie.Name & "<br>")
Response.Write("Expires: " & MyCookie.Expires & "<br>")
Response.Write("Secure:" & MyCookie.Secure & "<br>")
Response.Write("Value:" & MyCookie.Value & "<br>")
' Grab all values for single cookie into an object array.
arr2 = MyCookie.Values.AllKeys
' Loop through cookie value collection and print all values.
For loop2 = 0 To arr2.GetUpperBound(0)
Response.Write("Value " & CStr(loop2) + ": " & arr2(loop2) & "<br>")
Next loop2
Next loop1
End Sub
When I call the ViewCookies mothod or routine, the only cookie I se is the one created by ASP.NET for the session identifier.
Can anybody tell me what i'm doing wrong here? I based my code in an example I got from MSDN. I'll appreciate your help.
Regards,
David
|
|
|
|
|
I have a textbox with browse function in my web application. This will able user from the web to import or upload their data in CSV file into my SQL Server place at my factory.
The problem is user in my factory office domain can import the file through the directory browse from My Network Place and proceed to import the csv file into the server. But, user not in my domain but from outside country or other location cannot import the CSV through the textbox with directory browse function. They alwasy get the error with "network path not found".
How can i solve this problem to enable user around the internet to proceed import their csv file into my server using this textbox with directory browsing function? I give every user the bulk insert right for this system.
Thank you for advice.
|
|
|
|
|
Young,
Your question does not look clear, at least for me.
1-Your SQL Server is located at a factory somewhere in the world
2-Your users are located either inside or outside your domain, meaning they could be reaching your application via intranet or internet
3-I'm assuming the CVS file is generated locally on the user's workstation located anywhere in the world and then they use your web application to upload it to a web server to then submitted to an SQL DTS package to update your database
4-Is the network path embedded or forced somehow in the path of the object? the object is the directory bworser not the web browser.
5-You have no problem using the textbox with directory browsing function as you called it, you just have to be aware that the application is assigned with the Write permission to the directory where users will upload the CVS file on your web server.
6-There could also be an error formatting the path of the file. Could you please post code?
Please let me know if this make sense for you or if I'm assuming things in the wrong way.
Regards,
David
|
|
|
|
|
You are right on the issue of 1, 2 and 3.
But how about the issue 4th that you are mean by? FYI, i put my code some thing as this:
Dim filetoread As String
filetoread = File1.Value
where the filetoread is the textbox text value after i browse for the file to be import to the server ay my place.
IS this the problem that cause the network path not found issue from my directory browser?
If this the matter, how can i solve this problem using the web browser as you mentioned?
How the web browser code will look like? Any code exmaple or reference?
Thank You, David.
|
|
|
|
|
Yong,
I'm assumming you're using an HTML INPUT object type="File", which comes with a button embedded that once you click it opens a LOCAL directory browsing to select a file from the local workstation, users should select the file and then you should be processing that file saving it on a directory on your web server right!
If the application is the same for everybody, there should not be any different between the 2 groups (local users and internet users), it is the application itself with rights or not to the directory where you upload the CVS file to later use on your SQL Server.
How do you authenticate users?
I don't know but it looks like rights problems....
|
|
|
|
|
I set 'NONE' for the authenticate mode in my web config file of my ASP.NET application.
For the SQL Server, i put NT AUTHORITY/Authenticated Users for the user for database that use by the application as well as dbo.
So, are you sure that not problem i using directory browser in my application?
Thank for advice.
|
|
|
|
|
Hi
I need some serious help with WSE(Web Service Enchanements) 3.0. This what I am trying to do, I am generating a web service, which will basically will take the user credentials, authenticate that user against the database, encrypt the username and passowrd then generate some type of token which will be sent back to the client. The client will that token to access other web services.
I got everything done except I am unable to generate the token which I would like send to the client.
UsernameToken objUserToken = new UsernameToken(strEncryptedUserName, strEncryptedPassword, PasswordOption.SendNone);
I am using above to create the userToken object. The token some properties "Nonce", "Password Digest" etc.
Few questions:
(1) How do I generate the token using the above scenrios?
(2) Do I need to have sort Policy Assertion (Client/Service)?
I also got custom build policies also? Can some please help me? I feel like I am missing something minor. I can share my phone number if some one is willing to help over the phone and then guide me to tell what is that I am doing wrong?
-- modified at 15:48 Tuesday 26th September, 2006
Raj -
|
|
|
|
|
|
Pals, i have problems to show images on gridview control.
i have the image url saved onto a table columns in Sql server express 2005.
ex C:\Inetpub\wwwroot\intranet\imagenes_usuarios\a\bio.jpg, the column name is urlimage
i created an ImageField inside the gridview, its already set the dataurlimagefield value to urlimage, and the image dont show up.
I lost something, refresh event, or something...
keep Learning and you never will be out of date...
|
|
|
|
|
The obvious question is, are you sure the path is correct? Is it being correctly rendered in the urlimage property (path not image itself, of course)?
only two letters away from being an asset
|
|
|
|
|
I follow your suggest and i found that maybe gridview image colunm doesnt work with absolute url image, what do you think, ¿im right??
an Friend Britney
keep Learning and you never will be out of date...
|
|
|
|
|
I haven't tried it with absolute paths but I have with relative paths and it seems fine.
only two letters away from being an asset
|
|
|
|