|
am adding the link button in the code behind as a local or member variable and tried to subscribe to click or command event and it is not breaking there.
Like say my requirement is out of 10 rows in a grid i want to know which grid i clicked onto and the value of the clicked item.
|
|
|
|
|
Can you show us your code used to create the dynamic link buttons and bind them? It can help...
I'm not questioning your powers of observation; I'm merely remarking upon the paradox of asking a masked man who he is. (V)
|
|
|
|
|
Make sure that you are dynamically adding the controls in the Page_Init() event and not in Page_Load. If you do it in Page_Load then when it posts back the event is registered but the control does not exist yet and will not fire.
Beyond that, we'd have to see your code to know for sure.
There are only 10 types of people in the world, those who understand binary and those who don't.
|
|
|
|
|
use ajax for dynamic adding link button like for commenting purpose
|
|
|
|
|
Hi,
so I have a radiobuttonlist with 2 options: look for a certain object by 2 categories of criteria.
If I change the category, I have an autopostback to change the filterexpression of an objectdatasource and do a databind on the gridview connected to the objectdatasource. However, this results into an empty list. If the user clicks on a button after the postback that does another databind, the list is filled again. I'm hoping to remove the need for the second postback just so I can view my results.
I have 3 controlparameters:
1 parameter connected to the first criteria, 2 parameters connected to the second criteria. Both criteria work just fine, it's the transition from onee category to the other one that is giving me problems as described above.
I added an eventhandler to check if the filterexpression was changed when the filtering is happening, and it had indeed changed to the new filterexpression.
Can someone help me out here? Don't want to bother the visitor with 2 postbacks for making 1 choice.
|
|
|
|
|
Could you help me generate regular expression for the following patern:
some text_11111-1214
11111- should be only 6 char
1214-only 4 char
|
|
|
|
|
|
I need regular experession for this pattern: some more text_11111-1234
I need to check for _ following 6 number
- following 4 number
Dim rgx As New System.Text.RegularExpressions.Regex("^[a-zA-Z0-9](-\d{4}){1}") ????
If (rgx.IsMatch("some text_11111-1234")) = True .....
|
|
|
|
|
Hello,
Try ([a-zA-Z\s]*)_(\d{5,6})\-(\d{4}) it matched following
some more text_11111-1234
Prasad Khandekar_435363-9353
Another Pattern_777777-8783
Regards,
Prasad P. Khandekar
Knowledge exists, man only discovers it.
|
|
|
|
|
Great. its working... thanks
|
|
|
|
|
+5
There are only 10 types of people in the world, those who understand binary and those who don't.
|
|
|
|
|
Thanks Ryan.
Prasad P. Khandekar
Knowledge exists, man only discovers it.
|
|
|
|
|
I want to add the multiple dropdownlist to my tool box...can u help me??????
Ashshu
|
|
|
|
|
What is the problem you are having?
There are only 10 types of people in the world, those who understand binary and those who don't.
|
|
|
|
|
|
<pre lang="text">
<asp:DropDownList ID="drd1" runat="server" >
<asp:ListItem>select the value</asp:ListItem>
<asp:ListItem>sample</asp:ListItem>
<asp:ListItem>Anothersample</asp:ListItem>
<asp:ListItem>one more sample</asp:ListItem>
<asp:ListItem>none</asp:ListItem>
</asp:DropDownList
>
Ashshu
|
|
|
|
|
What is your question?
There are only 10 types of people in the world, those who understand binary and those who don't.
|
|
|
|
|
At first your question was not clear. But after adding few characters I got it. Always post your question clearly.
You should customize the control. Check this article(and you could fine bunch more in Codeproject)
DropDown and MultiselectDropDown Controls for ASP.NET[^]
Or alternatively you could use ListBox[^]
|
|
|
|
|
How can i see if Ok or cancel is pressed?
Code:
Private Sub GridView1_RowCommand(sender As Object, e As GridViewCommandEventArgs) Handles GridView1.RowCommand
If (e.CommandName = "DelUser") Then
Dim index As Integer = Convert.ToInt32(e.CommandArgument)
Dim row As GridViewRow = GridView1.Rows(index)
Dim cmd As SqlCommand = New SqlCommand("DELETE [dbo].[MOVIuser] " & _
"WHERE ID = @U_ID ", conn)
cmd.Parameters.Add("@U_ID", SqlDbType.Int)
Dim message As String = "Möchten Sie den Benutzer " & _
CStr(row.Cells(3).Text) & ", " & CStr(row.Cells(4).Text) & " wirklich löschen?"
Dim sb As New System.Text.StringBuilder()
sb.Append("<script type = 'text/javascript'>")
sb.Append("window.onload=function(){")
sb.Append("return confirm('")
sb.Append(message)
sb.Append("')};")
sb.Append("</script>")
ClientScript.RegisterClientScriptBlock(Me.GetType(), "alert", sb.ToString())
/* Which Button is pressed? */
Try
conn.Open()
cmd.Parameters("@U_ID").Value = CInt(row.Cells(1).Text)
Catch ex As Exception
Finally
conn.Close()
End Try
End If
End Sub
|
|
|
|
|
Did you look at the sender object that calls the sub?
Oh, your talking about the Javascript.
You can't do it that way.
More like
Button calls JavaScript first by using a click event assigned to the button. if true is returned then the called function runs and deletes the user.
ASP.Net Button Code
OnClientClick="return deleteUser();"
Javascript Code
function deleteUser() {
if Confirm("Delete User") {
return true;
}
}
|
|
|
|
|
+5
There are only 10 types of people in the world, those who understand binary and those who don't.
|
|
|
|
|
Aslam O Alaikum Every Body
I have Confusion How I Deploye an Desktop Application Exe File On Local Server
|
|
|
|
|
Alaikum Salam Bhai,
You just compile the program in "Release" mode, then copy the entire content of "Release" folder, put it on the deploy machine.
Hope this helps!
Thanks!
- Francis S
|
|
|
|
|
desktop application(.exe) is installed and not deployed.
|
|
|
|
|
If you want to go with installer, Please try the below link:
CodeProject URL
Hope this helps!
|
|
|
|