|
<br />
lnkButton.Attributes.Add("OnClick", "if(!confirm('Are you sure?')){return false;}__doPostBack('" + lnkButton.ClientID + "');");<br />
<br />
lbRemove.Click += new EventHandler(lnkButton_Click);<br />
<br />
protected void lnkButton_Click(object sender, eventargs e)<br />
{<br />
<br />
}<br />
<br />
I didn't get any requirements for the signature
|
|
|
|
|
Hi,
In pageload event, add attributes to the button using the following code.
Button1.Attributes.add("Onclick","return callconfirmation()");
In the aspx page, in between the head tages
write the javascript function with the name callconfirmation.
function callconfirmation()
{
if(confirm("Are You Sure You want to close the application"))
{
window.close();
}
else
{
return false;
}
}
Try the above code and let me know if you have any issues.
Bhanu
|
|
|
|
|
Hi All,
I am using a datagrid in a ASP.NET page.
The data grid is inside a div tag.
<div id="divEditProjectRes" style="OVERFLOW: auto; HEIGHT: 150px">
<asp:datagrid id="dgEditResource" runat="server" Width="100%">
There is edit option in each row of the data grid and the user can edit on a few fields.
The grid has many records and the user has to scroll down.After scrolling to the record and clicking on edit there is a post back ,and the grid is set back to the top and he again has to scroll back to the row in which now fields are editable.
What I want here is that after he clicks on edit the same row must come at the top and the user need not scroll it again.
I have used the following code in dgEditResource_EditCommand to set focus to the editable text box in the particular scroll row ,Although it gets the focus but again we need to scroll down .
Dim descTB As TextBox
descTB = dgEditResource.Items(e.Item.ItemIndex).Cells(2).FindControl("sdate_edit")
'Set the script to focus and select the TextBox
RegisterStartupScript("focus", "<script language=""JavaScript"">
vbTab & "Form2." & descTB.ClientID & ".focus();"
vbCrLf & vbTab & "Form2." & descTB.ClientID & ".select();" & "<" & "/script>")
descTB = dgEditResource.Items(e.Item.ItemIndex).Cells(2).FindControl("percent_Edit")
If we press tab or space bar the record comes up as focus is already in the text box.
But I need that row to scroll up or navigate by itself after edit is clicked.
Thanks in advance.
Regards,
Sakshi
<div class="ForumMod">modified on Saturday, January 26, 2008 7:47:32 AM</div>
|
|
|
|
|
How to generate data in dropdownlist using database wizard?
Coding of Database Programming we usually follow the rules. connection,command,adapter and dataset respectively. This is only for coding. What if I will use this using the wizard, I mean no coding will happen, all are in wizard scenario. I tried already but unfortunately it will not populate the data into dropdownlist.
What I did is in the dropdown property, I set datamember, datasource, datatextfield and datavaluefield.
Note all objects are already set in properties.
Is anybody here have done this scenario. Could someone help my problem. Thanks in advance.
jeof
//------------------------------------
//Software is like a sex;
//It's great when it's free. C#Coudou
//------------------------------------
|
|
|
|
|
var doc = new ActiveXObject("Word.Application"); // creates the word object
doc.Documents.Open("C:\\My Documents\\file.doc"); // specify path to document
var txt;
txt = doc.Documents("C:\\users.doc").Content;
alert(txt);
i am getting error automation server cannot create object .
can anyone help me .
|
|
|
|
|
This is because of one of the following issues:
* The client machine (where you are running now) does not have MS Word.
* Internet Security restricts the browser to use that ActiveXObject.
|
|
|
|
|
microsoft word is there on my machine. and for the second one what should be done. is there any other way to read a word file in javascripting.
|
|
|
|
|
For the second one, go to Component Services and find the MS Word component. Then set the permission.
I too had this problem in my company few months before. But this permission issue it not settlement even after setting up the permission. Atlast we used ActiveXObject to do whatever we want.
Google for more inform. All the best.
|
|
|
|
|
Hi All,
I am developing a web site in English language. i need in a certain page to enter for example name in different language with direction left to right where the direction in all textboxes is from right to left. Also i need to change the language. Is that possible? thanks
|
|
|
|
|
Hi
I have a problem with a website. Through my machine and through IE and FF I can view a new piece of text which has been uploaded to the website via a different machine.
However on our other machines in the company you cannot see the new bit of text
can any1 shed some light on this?
cheers
|
|
|
|
|
Hi;
Here is a wild guess.
Could it be a firewall restriction on your company's intranet ?
Try investigating this first.
Good Luck
|
|
|
|
|
hi all
I need validator file upload
only file gif,jpg,png if orther file have messbox error
|
|
|
|
|
Get it
SSK.
Anyone who says sunshine brings happiness has never danced in the rain.
|
|
|
|
|
I am having a dropdownList and when i select different items from the dropDownList with respect to the selected ITem the details are loaded to the GridView and in GridView properties AutoGenerateEditButton="true"
Can someone pls help me what code should be written in rowediting event and rowCancelEdit event
EXAMPLE
LET DROPDOWN LIST HAVING 3 TEXTS
1.RENEWAL INVOICE
2.QUOTATION INVOICE
3.RECEIPT INVOICE
WHEN I SELECT QUOTATION INVOICE THE DETAILS THAT WILL BE DISPLAYED IN GRIDVIEW.
THE GRIDVIEW DISPLAY IS AS FOLLOWS
PLAN TYPE FIRST NAME LAST NAME ID
Edit Delete Premium 1 Year Robin Simon 575003
Edit Delete Individual 2 Year Pradeep Bhojwal 575004
I WANT TO EDIT THE DETAILS IN THE GRID ITSELF WHEN I CLICK THE EDIT BUTTON THERE IN THE GRIDVIEW
WHAT I NEED IS THE CODE THAT IS TO BE WRITTEN IN THE
RowEditing event and
RowCancelingEdit event and
RowUpdating event of the DATAGRID
pls reply as soon as possible
its so urgent
waiting for ur reply
Regards
Robin
|
|
|
|
|
robinsimon_m wrote: WHAT I NEED IS THE CODE THAT IS TO BE WRITTEN IN THE
No one is going to give you the code, simply because you are too lazy/incompentent to write it yourself. If software development is too difficult for you, maybe you should consider switching to a career more befitting to your intellectual capabilities. My local McDonalds is currently hiring - maybe you should give them a ring.
Paul Marfleet
"No, his mind is not for rent
To any God or government"
Tom Sawyer - Rush
|
|
|
|
|
pmarfleet wrote: My local McDonalds is currently hiring - maybe you should give them a ring.
Good one.
"I guess it's what separates the professionals from the drag and drop, girly wirly, namby pamby, wishy washy, can't code for crap types." - Pete O'Hanlon
|
|
|
|
|
|
robinsimon_m wrote: pls reply as soon as possible
its so urgent
No. That is considered very rude here. Demanding someone reply because you are under some kind of deadline. Do your own work.
"I guess it's what separates the professionals from the drag and drop, girly wirly, namby pamby, wishy washy, can't code for crap types." - Pete O'Hanlon
|
|
|
|
|
I am sending mails to group of people at a time .
if some of the mailids are not correct how to find out that id for further processing.
like:
nicevirendra@rediffmail.com is Valid
a@a.asasa is Invalid How i Find This is....!
Never Think That You Have Failed Instead Always Think That u hav Better Chance Next Time...
|
|
|
|
|
Email validation
SSK.
Anyone who says sunshine brings happiness has never danced in the rain.
|
|
|
|
|
You can, at best, perform only syntax level validations. If you really want extremely good impeccable email addresses, you need to send a probing email asking the user to click a link and confirm.
However, you can check out http://www.hexillion.com/[^]. They have something called EmailDossier. That should help you. Again, it depends on SMTP commands like VRFY, EXPN etc which most of the current SMTP servers might disable for spam-control and security reasons.
Vasudevan Deepak Kumar
Personal Homepage Tech Gossips
A pessimist sees only the dark side of the clouds, and mopes; a philosopher sees both sides, and shrugs; an optimist doesn't see the clouds at all - he's walking on them. --Leonard Louis Levinson
|
|
|
|
|
hi there,
i seached on your post. But most of the people using Regex (Regular Expressions) for matching all the Email ID's but how to deal with illegal domain names as you given as a@a.asasa in this after the @ sign one cannot predict which domain is right. As we know there are more than thousand domain names also lots of new domain are existing but we don't know. So, According to me make list of relevant domain names which is relevant to your application.
If you have any problem most welcome.
Thanks & Regards
Dilip Kumar Vishwakarma
|
|
|
|
|
You could use regular expressions.
"I guess it's what separates the professionals from the drag and drop, girly wirly, namby pamby, wishy washy, can't code for crap types." - Pete O'Hanlon
|
|
|
|
|
Use regular expression validator on the page.
e.g.
<regularexpressionvalidator id="emailValidator">
ValidationExpression="^([\w-\.]+)@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.)|(([\w-]+\.)+))([a-zA-Z]{2,4}|[0-9]{1,3})(\]?)$"
ControlToValidate="txtEmail" ErrorMessage="Invalid Email" Display="Dynamic" runat="server">
|
|
|
|
|
Google for more regular expression, you will find bunch of regular expression to validate domain name too.
|
|
|
|