|
I have a numeric keypad on a panel and the number keys are pressed it populates the field that currently has focus. I think that I have done this in a rather clunky way, but can't think of anything else - can anyone help?
I store focus in a textbox field that will be hidden away.
In the pageload id do the following:
TextBox1.Attributes.Add("onFocus", "UpdateText('TextBox1','textBoxFocus')");
TextBox2.Attributes.Add("onFocus", "UpdateText('TextBox2','textBoxFocus')");
The aspx file is:-
<%@ Page Language="C#" AutoEventWireup="true" CodeFile="Default.aspx.cs" Inherits="_Default" %>
<title>Untitled Page
<asp:textbox id="TextBox1" runat="server"><asp:textbox id="textBoxFocus"
="" runat="server">
<asp:textbox id="TextBox2" runat="server" textmode="Password">
<asp:panel id="Panel1" runat="server" height="154px" width="185px" cssclass="panel">
function numClicked(elem) {
try {
if (document.getElementById("textBoxFocus").value == "TextBox1")
if (document.getElementById("TextBox1").value.length < document.getElementById("TextBox1").getAttribute('maxlength'))
document.getElementById("TextBox1").value+=elem.value;
if (document.getElementById("textBoxFocus").value == "TextBox2")
if (document.getElementById("TextBox2").value.length < document.getElementById("TextBox2").getAttribute('maxlength'))
document.getElementById("TextBox2").value+=elem.value;
}
catch(e)
{
response.write(e);
}
}
function UpdateText(x, TxtCntrl2)
{
document.getElementById(TxtCntrl2).value = x;
}
Clueless
|
|
|
|
|
I have developed a search engine in asp(vbscript) which search the text on whole web page if found then display its link. but i want to search whole page but not tags.means that if desired text exists in tag it not be searched.remaing page will search
wht should i do .can any body give me idea
|
|
|
|
|
Hi,
I'm trying to ask a web button to fire an event in javascript which is called PrntPreview(). But when I run, it gave this error below:
BC30456: 'PrntPreview' is not a member of 'ASP.DisplayStkCode_aspx'.
Anyone can tell me wat is wrong?
<asp:Button id="btnPreview" OnClick="PrntPreview()" runat="server" Text="Print Preview"></asp:Button>
Thanks in advance,
Chiari
|
|
|
|
|
Hi there,
The onclick is the server side event of the button web control, so you need to provide the PrntPreview method which will be running at the server side, and you cannot assign a client side function to the event in the html editor. If you just want to add the client side function for the onlick event, you can do that as below:
btnPreview.Attributes.Add("onclick", "PrntPreview();");
|
|
|
|
|
Hi there,
I know what went wrong and I have corrected it by using HTML input button.
Thanks a lot.
Chiari
|
|
|
|
|
I have a Value Object, vo, that has a System.DateTime field that is populated with the help of an SqlDataReader, sdr, as follows:
vo.MyDateField = Convert.ToDateTime(sdr["MyDateField"]);
vo.MyDateField is tied to an ObjectDataSource that is used to populate a GridView.
The problem is when MyDateField is null in the database. In that case sdr["MyDateField"] = DBNull.Value, and since System.DateTime cannot take the value of null, vo.MyDateField = "1/1/1", and that value is displayed in the grid, instead of a blank entry as required.
I do not want to resort to SqlDateTime because it is not as precise as System.DateTime. How can I have a blank entry in the GridView for a date field that is equal to DBNull?
|
|
|
|
|
hi members,
i need help to develop ringer in my project.problem is that how i slect a file that be applied as incoming in project and it should be saved in registry too.i am able to select a file and write that on system. but how it will done in registry.
Regards
ashish
|
|
|
|
|
Ashish,
You can manage registry on a windows System using Microsoft.Win32 namespace. However, from an ASP.NET web application, you may not have full privileges for ASP.NET user account to manipulate Windows registry and you may need to use impersonation to achieve this trick.
Vasudevan Deepak Kumar
Personal Web: http://www.lavanyadeepak.tk/
I Blog At: http://deepak.blogdrive.com/
|
|
|
|
|
Hi,
I am working in Sharepoint. The scenario is that we are using a tree view and have linked it to an iframe on the same page. I tried to make it behave exactly like Windows Explorer ie when u click a link in the tree view the page will open on the iframe.
But the problem is the iframe moves to its original onload URL when the whole page gets refreshed. I do not want it that way. I want the iframe to hold its position or url even when the page is refreshed.
Is there any way of using autopostback in iframe so that it will catch the original url. Or is there any other way to achieve this. please let me know immediately.
Thanks in Advance,
Regards,
Sriraj Kannan.
|
|
|
|
|
I am having problems using iFrame. I have the following body of code with two layers called "Bckgnd" (z-index =1 ) and "Title" (z-index = 2), and the iFrame is hidden behind the "Bckgnd" layer. I made sure the two layers in the "dataonly.asp" file had a z-index greater than 3.
Any idea why I can not see the iFrame on top of the "Bckgnd" layer? I have seeing the information when I copy the code from "dataonly.asp" into this file. The reason I am trying to use iFrame is to eliminate the flickering I see when the data is being refreshed. Any suggestions on how I can eliminate flickering would be greatly appreciated.
Thanks, Sonia
Code:
Operational Data
-- modified at 21:16 Monday 3rd October, 2005
|
|
|
|
|
Hi
I’m not sure why it won’t show but I also don’t know if this would solve you flickering (refreshing) problem totally.
What will happen when you use this, the whole I-frame would still flicker but the rest of the page wont. You could then split the page into multiple I-frames but they would still flicker depending on the post back time.
The biggest cause of the flicker is the post back to the server so I create a I-frame which is hidden which then executes my Asp page but instead of generating standard Html, it generates a html string which I then inject into div tags on my page using JavaScript with the “innerhtml” method.
I hope this helps
My life for Aiur!
-- modified at 5:54 Tuesday 4th October, 2005
|
|
|
|
|
I was hoping by using iFrame, only the data will flicker instead of the background also. If basically broke the code up into two segments; background (do not need refreshing) and foreground (need refreshing). When the whole page updates, it turns white before it redraws the page. Since the background is blue, the flickering should not be as bad. Is there any other way I can put one frame on top of another or do I have to use iFrames?
I figured out why I can't see the iFrame (see original posting)....I was able to make this work by adding another layer with z-index higher than the z-index of the background layer. I moved the iFrame into the new layer. I just don't know why the iFrame z-index attribute didn't work in INternet Explorer. It worked okay in Opera.
-Sonia
-- modified at 16:58 Tuesday 4th October, 2005
|
|
|
|
|
Hello, I'd like to know how to hide the verticle scrollbar in box in Netscape. If the "size" properity of a box is set, the box will be display in the form of a list which display all the options. But even if the "size" is set bigger than the length of the options, the vertical scrollbar will still show up in Netscape. Is there a way to hide that scrollbar? I tried "scrolling:none;" and "overflow:hidden;" but none of these works.
The following is sample code:
one
two
three
four
The size is 6, which is bigger than the length of the options, which is 4. but the scrollbar is still showing up in Netscape. I tried to figure this out for several days. I also tried to set the scrollbar colors to background, but still cannot find solution.
I also have another question. In the above example, the mouse-over an option event won't highlight it. Is there a way to make the mouseover highlight a choice item, just like in the "normal" box?
If you know answer to any of my question, please kindly drop me a couple lines.
Thank you very very much in advance..
Bin
|
|
|
|
|
Currently I have a web application that runs in secure socket. The Web app access Web services also by calling the secure socket.
Example:
Web App runs here
https://secure.webapp.com/app/default.aspx
access database thru Web service call
https://secure.webapp.com/appWS/getmydata.asmx
Now.
If I create a windows application that needs to get data from the same webservices, can my windows application make the same web services call
https://secure.webapp.com/appWS/getmydata.asmx
with the data being secure coming back to the windows application on my client?
I do not know enough about SSL to know. My concern is that taking the secure web page out of the picture is the data still secure coming out of the web service?
Thanks
-- modified at 10:47 Monday 3rd October, 2005
|
|
|
|
|
|
Of course! How do you expect a Cell as a Hyperlink Text. That is a presentation tag right.
If you want the entire cell to be clicable, then I think you can try and use a javaScript function.
Vasudevan Deepak Kumar
Personal Web: http://www.lavanyadeepak.tk/
I Blog At: http://deepak.blogdrive.com/
|
|
|
|
|
I have this code:
<base href="http://ngolehung.com" />
<base href="http://ngolehung1111111.com" />
I want each table has different <base href="" ......="" /> but I can't do with the above code?
How can I do?
Hung
|
|
|
|
|
|
Hello,
Please suggest me a way to allow my users to download a file from one link on the web page and the File is located in a different folder (This is a Link to another file server).
Balu
|
|
|
|
|
Balu,
Which technology are you using? Assuming ASP.NET, you may StreamRead the file and the write into the Response Stream, allowing suitable buffers. You may need to have impersonation to have ASP.NET access the network resources.
Vasudevan Deepak Kumar
Personal Web: http://www.lavanyadeepak.tk/
I Blog At: http://deepak.blogdrive.com/
|
|
|
|
|
vasudevan,
Thanks for your response and i appreciate it. The technology i am using is JSP->Struts->Bean. The environment is Unix. There is a seperate server for files from appserver. This is a report where the jsp is loaded with recordset results and allows user to download the same in excel form. The files that user downloads has to be stored in the fileserver aswell. There is one Link created on the appserver to a file server. The link is outside the web folders on App server. Is it possible to allow user downloads when the file resides outside web folder (link especially).
Thanks and hope to get some help from you.
Regards,
Balu
|
|
|
|
|
A user can not download a file outside the web folder, unless the user has direct access to the file server.
Make a proxy page, that gets the file from the file server, and sends it as response to the user.
Make sure that the page can only be used to fetch the files that the user should have acess to, otherwise you will open up a huge security hole...
---
b { font-weight: normal; }
|
|
|
|
|
this site is done in php format, and he combined it with flash
this is good if you have good internet connection rinformp3.com[^]
|
|
|
|
|
|
How in the world did this guy make a flash code to work on a site like this, can i make something like this in vb, and then convert it to falsh??
www.ringformp3.com[^]
|
|
|
|