|
Where should I put it?
Because I have define it(I used static on for testing) inside
Page_Load(.....)
{
Session["Username"] = "lll";
}
But it does not show the Gridview.
|
|
|
|
|
Put it before you bind GridView.
Session["Username"]="lll";<br />
.<br />
.<br />
.<br />
GridView1.DataBind();
I Love T-SQL
|
|
|
|
|
If you want to hardcode the parameter in the query, dont use a session parameter, just switch to sourcemode in the form designer (Shift + F7) and find the sql query, and add the where clause
Or why are you using a sessionparameter?
Alexei Rodriguez
|
|
|
|
|
I have created a form using a panel. The form contains several textboxes and labels (name of the fields) and also three buttons (first one: Insert, second one: Reset, third one: Cancel). I have also added one RequiredFieldValidator on one of the textboxes which is the primary key. When I write something on the textboxes except required filed (that has RequiredFieldValidator) then I pressed Reset it gives shows me the message of RequiredFieldValidator or even when I pressed Cancel it gives me the same thing. How can I handle this (means when pressing Reset it will reset all the fields without showing the message and when pressing Cancel it will reset all the fields and make the panel invisible)?
Thanks in advance for your help.
Best regards,
|
|
|
|
|
For the cancel and Reset button u can set the cause validation property to false so that when u click these button the required field validator will not be checked.By default cause validation property for all buttons will be set to true. So we have to change it.
And for insert button the only way is you have to alternatively visible true or false, for the required field validator.
VanithaVasu
|
|
|
|
|
Hi All,
I have a gridview
it contains : Empid, Code, Status and status column is a item template and it bind data fom databse.
let say if my status is active if i click on it i wants to popup (confirm msg by java script)are u sure inactive this employee then after clicking yes , it should display it code in 2nd popup using java script.
My code given below:
==========For binding data in link button=================
<itemtemplate>
<asp:LinkButton ID="lnkDelete" runat="server" CommandArgument='<%# Eval("Action") %>'
CommandName="Select" onClientClick="ok()" Text='<%# Bind("Action") %>' >Action</asp:LinkButton>
</itemtemplate>
==============================
<script language="javascript" type="text/javascript">
function ok()
{
var action = "<grid action="" column="" value="">";
var code ="grid code column value";
if (confirm("Are you sure ?") == false)
{
window.event.returnValue = false;
return false;
}
alert (code);
}
</script>
==============================
I have to store action as data displaying in gridview and code from gridview.
Thanks,
sampad...
|
|
|
|
|
hi,
I've a problem figuring out how to design my website's interface.
I have a menu control that's horizontal..it takes the whole width of the screen and right under it I have datagrid that also takes the whole width of the screen, so my problem is that new items are added in the menu regularly so that means the menu will be too wide for the screen..so I was thinking of converting it to a vertical menu but my problem is that the grid also takes the whole screen so I don't know where exactly to put it so this means it's gonna take part of the width that the grid takes?
So I can't imagine where to put it exactly...any suggestions..maybe some links to websites as examples..
thanks
|
|
|
|
|
My Firefox turns the textbox bkcolor to yellow by default. If I'm changing it programtically, it doesn't work. All server controls. Any clue?
|
|
|
|
|
Smith# wrote: bkcolor to yellow
Is there a Google Toolbar that is installed?
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
|
|
|
|
|
my table td is like below
i want to make visible at run time
<td class="blackText" id="cct1" style="visibility: hidden">;
i have tryed with below,its not works
str = "<script language=javascript>"
str = str + "function PopWindow()"
str = str + "{"
str = str + "document.getElementById(cct1).style.visibility='visible';"
str = str + "document.getElementById(cct2).style.visibility='visible';"
str = str + "}"
str = str + ""
Page.RegisterStartupScript("str", str.ToString())
please help me for this situation
parthiban
|
|
|
|
|
|
i want with push a button i can print a html page. do anybody know how can i do this?
|
|
|
|
|
|
Hi masters!
I'm very beginner in ASP.NET and newly have installed IIS on my computer.
After that I wrote the following in IE address bar:
http://127.0.0.1/iisstart.asp also http://127.0.0.1/localstart.asp
But nothing downloaded and I saw:
The page cannot be displayed
Please help me
|
|
|
|
|
register IIS from command prompt
set location to
C:\WINDOWS\Microsoft.NET\Framework\version\
and then execute this command aspnet_regiis -i
for more information check here...[^]
I Love T-SQL
|
|
|
|
|
Hey guys how can i display some message and links on a splash screen before my home page got loaded.
Just like silverlight splash screen on msdn page.
Thank you.
deepa.
|
|
|
|
|
you can use ajax control lib
There you'll get message boxes,unique progress bars,and some certain popus
also.
Or try some java scripts also..
like about error or title ..like that
or check dreamweaver ,expression web or simply try silverlight..
go to www.ASP.net for more help..
or to MSDN.....
Hope you are happy
Minor things some times bids major values
BYE
|
|
|
|
|
Hey,
i will explain my problem more clearly. I got a home page. when a person logged in . i have to display his contact number as a splash screen making the home page blurred. if the contact number is correct he will click ok( link )then i will let him go to home page, other wise he should be directed to update contact page(another link on splash screen).
could you please help me with more clearly how cani do this.
thanks,
deepa
|
|
|
|
|
Dear Friend
Actualy i know your prob.Ok let it be so light.If you want to make any popups or a splash screen infront of your home page,yes do what i reccomended in previous message.Programms like Hover Menu in AJAX , help you regarding this.I really don't know how to code that,b'coz i never used that sort of culture.Indeed to get a message box or a hover OR an upcoming menu i use a page that look like a popup.By the way thats tough to make.Well the code in that must be like, if the USER.ISIN ROLE is an authorized user ,THEN must get to the HOMEPAGE.Otherwise (if he is a nonauthenticated user) he shall go to UPDATE PANEL PAGE or as u said UPDATE PAGE.And this authentication ,you can do that with WEB ADMIN TOOL.
Then from there you can check a person,if is authenticated through your "contact details".
Hope you'll ask many..I'm so happy to share my knowledge
Thank u
|
|
|
|
|
i think i can use modal pop up window which makes every thing easier for me. It is in Ajax tool kit.
Any idea how to use it.
|
|
|
|
|
Dear deepu
As you said AJAX Modal popup control is the best to show your Popup to the user.
As your wish it will show an YES or NO sequence to user before he gets in to the Home page.
But there are some things to note
1: if the browser does not support JavaScript, the pop-up will not work .So the user's web browser
should compatible with javaScript.
2:Ajax is not a programming language,it's just an extension,rather a javascripted extension
3:The user might have pop-up killers running that close the window the moment it’s opened
You can cover all that probs
with your page's source
<a href>
|
|
|
|
|
i have a web application,in that i used javascript for disabling the control;.it is working fine in IE.but when i run my application with Firefox,its is not working.
what i have to do.
can any one solve my problem.
|
|
|
|
|
|
Hi all,
I have created a sample web application and while clicking on it, a MSI file has to be downloaded. It is downloading but adding one more byte to it and corrupts the applciation.
Can any one help in this regard?
Best Regards,
M. J. Jaya Chitra
|
|
|
|
|
Which browser are you using to view the website?
Also, can you please post the code for download file.
Best Regards,
Sam Xavier
www.componentone.com
|
|
|
|