|
anyways i figured it out.. i put this line of code in the rowcommand of thr gridview..
<br />
If (e.CommandName = "Select") Then<br />
Dim row As GridViewRow<br />
<br />
row = gvList.Rows(Convert.ToInt32(e.CommandArgument))<br />
<br />
msClientCode = row.Cells(1).Text<br />
msClientName = row.Cells(2).Text<br />
msClientType = row.Cells(3).Text<br />
<br />
End If<br />
|
|
|
|
|
Hi... Good day.
I have a question, in my page bottom part, it have 5 buttons with different function. One of the button is use for print. I use window.print() function for printing the page.
My question is, when i click the print button to print the page, i want all of the 5 buttons hide from the page and after i finish print the page or close the print window, i want those 5 buttons appear back in the page. Anyone have idea how to do this? Thanks...
Best Regards,
Pei Sun
|
|
|
|
|
Hi,
In the event handler for print button write code like this ---
button1.Visible = false
button2.Visible = false
button3.Visible = false
button4.Visible = false
// your printing code goes here
button1.Visible = true
button2.Visible = true
button3.Visible = true
button4.Visible = true
If you are using some panel or something like that to hold the buttons then you can iterate through the controls collection to set this property. It would be a better programming practice. You can also write a function for this, with 2 args, parent control ( like panel ) and child control to be set visible false. ( just an example )
<marquee>"A good programmer is someone who looks both ways before crossing a one-way street." -- Doug Linder
Anant Y. Kulkarni
|
|
|
|
|
|
Thanks for your reply. I'm not familiar with css. Can you explain further about the link uyou recommend me to read? I'm not so sure how it works. Thanks..
Best Regards,
Pei Sun
|
|
|
|
|
|
Hi Friends,
I want to add controls dynamically to the form at any position as i wish.For that i want to identify the location on the form(page).How to do it in asp.net 2.0 . I know that so many talented people are here to help us.Please post a better solution for this as soon as possible.
Thankyou to one and all,
Regds,
Hari.
|
|
|
|
|
Hi Friends,
This is HariBabu, I want to drag items from one listbox and drop it in another listbox. I want code for this fuctionality in asp.net with c#. i know so many talented guys are here to help me.
Thankyou Guys(Also Ladies)
Regds,
Hari.
HariBabu Kuricheti
|
|
|
|
|
|
Hi Naveed Kamboh,
Thanks for giving response and i saw the examples which you send to me ,it is some what helpful for me, but is there any perfect code for that type of functionality in webapplications(Asp.net 2.0 c#).If any Please send to me .
Anyway Thanks for your contribution.
Regds,
Hari.
|
|
|
|
|
I have a column which is an edit button in datagrid , i want it invisible when the page load , and when i press another click button, the edit button inside the datagrid become visible ? I need to code it in HTML more better ,not in code-behind, thanks you very much.
Best regards,
Chee ken
|
|
|
|
|
using property a column can be make invisible.
<asp:EditCommandColumn Visible="False" ButtonType="PushButton" UpdateText="Update" HeaderText="Edit" CancelText="Cancel" EditText="Edit"></asp:EditCommandColumn>
=postmaster
www.programmingknowledge.com
-- modified at 23:43 Thursday 24th August, 2006
|
|
|
|
|
I Got it !!
Thanks..
Best regards,
Chee ken
|
|
|
|
|
Hello,
I am trying to add a javascript block to a page in runtime.
I am getting an error because I not setting the type but I don't know how to do it.
My code is:
Dim urchinTracker As String = "<script type='text/javascript'>" & _
"_uacct = 'UA-XXXXX';" & _
"urchinTracker();" & _
"</script>"
If (Not ClientScript.IsClientScriptBlockRegistered("UrchinTracker")) Then
Page.ClientScript.RegisterClientScriptBlock("UrchinTracker", urchinTracker) >> Problem is here
End If
Basically, I am adding the code for Google Analytics.
Thanks,
Miguel
|
|
|
|
|
You can choose a specific type such as the Page type to pass in to the method.
|
|
|
|
|
How do I set focus after a button is clicked to go directly into a textbox. Or even if its on load have the cursor right on the textbox automaticall
Thanks
|
|
|
|
|
|
Create a module level function:
Module Module1<br />
Public Function SetFocus(ByVal FocusControl As Control) As String<br />
'Setting focus to supplied control<br />
Dim Script As New System.Text.StringBuilder<br />
Dim ClientID As String = FocusControl.ClientID<br />
<br />
'Building java script<br />
With Script<br />
.Append("<script language='javascript'>")<br />
.Append("document.getElementById('")<br />
.Append(ClientID)<br />
.Append("').focus();")<br />
.Append("</script>")<br />
End With<br />
<br />
Return Script.ToString()<br />
End Function<br />
End Module
call the function above in button click event
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click<br />
'set focus <br />
RegisterStartupScript("setFocus", Module1.SetFocus(TextBox1))<br />
End Sub
=postmaster
http://www.programmingknowledge.com/[^]
|
|
|
|
|
In the Page_Load Event, Type in:-
Page.RegisterStartupScript("ss", "document.getElementById('" & TextBox1.ClientID & "').focus();")
Thanks & regards,
Suresh Dayma
|
|
|
|
|
I have a GridView in my Web page. For one of the columns i set visible = false.
I looped through the rows in the GridView and tried to get the value for the column
for which the visible property is false and i got an empty string. When i set the
visible property to true i was able to retrieve the value. Is this the normal behaviour
of the GridView or am i doing any thing wrong here.
Is there a way to get the value for a particular cell even though the visible property is false
Thanks
Kal
|
|
|
|
|
AFAIK, this behaviour is by design, and you have a couple of options to work around:
+ Don't use Visible property, use stylesheet to hide the column.
+ Save the value of the insivible column somewhere else like the DataKeys collection of the GridView.
|
|
|
|
|
Hi Dear,
If you use RowDataBound event of gridveiw
i=0,1,2.... [column number]
if (e.Row.RowType==DataControlRowType.Header ||e.Row.RowType==DataControlRowType.DataRow)
e.Row.Cells[2].Visible = false;
it will hide the column and you can use column value in your project there wont be any problem.
if you need further help just email me.
thanks
Naveed Kamboh
|
|
|
|
|
Hi,
In the web service context,HTTP is used to transport SOAP messages i.e SOAP over HTTP.
Then What is the difference between HTTP Protocal and SOAP Protocal?
Thanks in advance.
-- modified at 16:16 Thursday 24th August, 2006
|
|
|
|
|
The protocols are layered on top of each other. A bit simplified it works like this:
SOAP - handles messages in XML form, using HTTP request and responses
HTTP - handles requests and responses, using TCP streams
TCP - handles transport of data streams, using IP packages
IP - handles tre transport of packages
...and then some lower level networking
---
b { font-weight: normal; }
|
|
|
|
|
Hi,
Iam learning Web sevices.So idon't know these simple things.
I created a web service.And iam using Visual C# Express Edition.In the Client application I added the web reference to the service i created.It generates the Reference.map,service.disco,service.wsdl.
When we click on ADD WEB REFERENCE button one proxy class is generated.I think in that proxy class we have namespace and class name and methods .Using that namespace and classname we call out web service in the client.
But in C# Express Edition How to see the proxy class contents.
Please help me.
Thanks in advance.
|
|
|
|