|
Malayil alex wrote: i want to show the path of the pages like "home>addClient"
i tried it but seriously getting errors like some xml is missing
SiteMapPath control uses a XML file, which should be placed on site's root. It's extension will be web.sitemap. Make sure that you have done all these
|
|
|
|
|
Hi
I have put a dropdownlist inside the datalist.On selected index changed
event i need ddlist selected value. I am find control using find control
method but when i am selected the item from dropdownlist itemcommand
event dose not get fired? Why the event dose not get fired. My code is
as follow.
Public Sub DtLreply_head_ItemCommand(ByVal source As System.Object, ByVal e As System.Web.UI.WebControls.DataListCommandEventArgs) Handles DtLreply_head.ItemCommand<br />
Dim msginfo_selfcreate As DbProvider = New DbProvider<br />
Dim dtr3, profile_rd As SqlDataReader<br />
<br />
Dim item As DataListItem<br />
Dim ddlist As DropDownList<br />
ddlist = e.Item.FindControl("ddstatus")<br />
Dim val As String = ddlist.SelectedValue<br />
<br />
<br />
End Sub<br />
Please tell me what i should do?
Rahul
|
|
|
|
|
Do you want to get selected Datalist rows values on SelectedChanged event of dropDownList?
Where is selectedChanged Event of dropDownlist?
FInd dropdownlist control on ItemCreated event of datalist and Create EventHandler event to fire SelectedChanged Event
bEST rEGARD
pATHAN
please don't forget to vote on the post that helped you.
|
|
|
|
|
Hi Imaran
I have to find dropdownlist control on itemcreated or on itemcommand
event of datalist. As i mentioned in code i am trying to find ddlist
on itemcommand event i need dropdownlist selected value (solved,open).
But then event dose not get fired.
my dropdownlist html is as follow.
<asp: dropdownlist="" id="ddlist" runat="server">
<asp:listitem>solved
<asp:listitem>Open .
Why the event is not get fired?
df
|
|
|
|
|
Debug that event.Is that fire or not?
bEST rEGARD
pATHAN
please don't forget to vote on the post that helped you.
|
|
|
|
|
I debug it but the event dose not get fired.
Rahul
|
|
|
|
|
May be possible that you are binding Datalist on Every postback.
Check out
<br />
if(!Ispostback)<br />
{<br />
}
bEST rEGARD
pATHAN
please don't forget to vote on the post that helped you.
|
|
|
|
|
Hi
Thanks for u r reply i solved that.
Rahul
|
|
|
|
|
Hi All,
How to disable all controls of the aspx page, when some condition occus?
I have done this thing manually. Like taking each and every control of page and setting it's propery as true.
<br />
if(status>=1)<br />
{<br />
txt_apply_for.Enabled = false;<br />
input_type_repayment.Enabled = false;<br />
input_loan_package.Enabled = false;<br />
input_first_home_buyer.Enabled = false;<br />
input_company_application.Enabled = false;<br />
input_interest_rate.Enabled = false;<br />
}<br />
else<br />
{<br />
txt_apply_for.Enabled = true;<br />
input_type_repayment.Enabled = true;<br />
input_loan_package.Enabled = true;<br />
input_first_home_buyer.Enabled = true;<br />
input_company_application.Enabled = true;<br />
input_interest_rate.Enabled = true;<br />
}<br />
But it is very tough when controls are more. Is there any other way or solution for this? Thank You
Keep Smiling...........
|
|
|
|
|
Please follow up Christian Graus and JON post
Parwej Ahamad
g.parwez@gmail.com
|
|
|
|
|
Thnak you very much Mr. Parwej Ahamad
Keep Smiling.......
|
|
|
|
|
Read my reply, his code won't really work. You need a recursive function, and you definately do not need to do all that ugly casting.
Christian Graus - Microsoft MVP - C++
"I am working on a project that will convert a FORTRAN code to corresponding C++ code.I am not aware of FORTRAN syntax" ( spotted in the C++/CLI forum )
|
|
|
|
|
Wow.
You're on the right track, and yet so far from it. The base class, Control, has the enabled property. The casting you're doing is totally superfluous, and makes the code messy.
Also, don't use 'is' and then cast. Use 'as' and use the result.
finally, the method needs to be recursive for it to work across the page.
Christian Graus - Microsoft MVP - C++
"I am working on a project that will convert a FORTRAN code to corresponding C++ code.I am not aware of FORTRAN syntax" ( spotted in the C++/CLI forum )
|
|
|
|
|
Something Like this...
Private Sub DisableControls(ByVal c As Control)
If TypeOf c Is WebControl Then
CType(c, WebControl).Enabled = False
End If
For Each child As Control In c.Controls
DisableControls(child)
Next
End Sub
Regards J O H N
"Even eagles need a push." David McNally
|
|
|
|
|
Thanks Christian Graus
i agree with you.
Parwej Ahamad
g.parwez@gmail.com
|
|
|
|
|
Hello Mr. Christian Graus,
Thanks for kind help. Can u plz give me code for the recursive function?
Keep Smiling..........
|
|
|
|
|
Put all the controls inside a container control(panel) and pass the Container Control as a parameter to this function. This will Disable all the server controls that is inside the Container Control.
Private Sub DisableControls(ByVal c As Control, ByVal status As Boolean)
For Each child As Control In c.Controls
If TypeOf c Is WebControl Then
CType(c, WebControl).Enabled = status
End If
Next
End Sub
Regards J O H N
"Even eagles need a push." David McNally
|
|
|
|
|
While I'm Creating an Object to a class using javascript in asp.net..Im getting this error..
Automation server can't create object
I' using this is my statement
var obj =new ActivexObject("Sample.clsSample")
|
|
|
|
|
What on earth is your problem ? You've asked this four times now, and you have got more than four answers. If you're incapable of understanding the answers, reply to the people who have answered you. What you're doing is plain rude. The answers will not change, no matter how often you ask.
Christian Graus - Microsoft MVP - C++
"I am working on a project that will convert a FORTRAN code to corresponding C++ code.I am not aware of FORTRAN syntax" ( spotted in the C++/CLI forum )
|
|
|
|
|
hi friend
soposed that i have tree node
root
parent1
child
parent2
child
i want if any body want to add child in child node then its not possible. or i want to restrict add any new node in child node how it's possible. please help me
Piyush Vardhan Singh
Senior Software Engineer
TAS NewDelhi
India
|
|
|
|
|
Tell me one thing paren1 and parent2 are predefine node or it create dynamically
When you add any node then check parent node of the node: if it is Root node then allow to add other deny.
Like:
Root
parent1
child1
parent2
suppose if user want to add node in child1 then check parent node of the child1 that is parent1 not it Root. so it will deny it.
if user want to add node in parent1 then check parent node of parent1 is Root that is Root so it will be allow.
Parwej Ahamad
g.parwez@gmail.com
|
|
|
|
|
create dynamically
Piyush Vardhan Singh
Senior Software Engineer
TAS NewDelhi
India
|
|
|
|
|
When you add any node then check parent node of the node: if it is Root node then allow to add other deny.
Like:
Root
parent1
child1
parent2
suppose if user want to add node in child1 then check parent node of the child1 that is parent1 not it Root. so it will deny it.
if user want to add node in parent1 then check parent node of parent1 is Root that is Root so it will be allow.
Parwej Ahamad
g.parwez@gmail.com
|
|
|
|
|
ok thanku i have done this
Piyush Vardhan Singh
Senior Software Engineer
TAS NewDelhi
India
|
|
|
|
|
I want to create an Object to a class which is in DLL using..
objSamp = new ActiveXObject("Sample.clsSample");
I'm using this statement in Javascript in ASPX page...
but I'm getting error in aspx page
error is "Automation Server Can't create Object"
How can I resolve this error..?
Please Help me.....
|
|
|
|