|
Check this[^]
and also
this.[^]
I Love T-SQL
"Don't torture yourself,let the life to do it for you."
If my post helps you kindly save my time by voting my post.
www.aktualiteti.com
|
|
|
|
|
Hello,
I'm looking for a web picture lupe (for a detailed view), but I can not find.
Is there someone an idea??
Benny
|
|
|
|
|
Try these[^]
Manas Bhardwaj
Please remember to rate helpful or unhelpful answers, it lets us and people reading the forums know if our answers are any good.
|
|
|
|
|
Hi everyone! I have a sitemap.xml that contains my links to the various sub pages. What I would like to do is have the system change the color of some of the titles so they stick out when new content is released. I've tried simply adding <code><span style="font-color:red">(new!)</span></code> in the xml file but that always bombs out. Can this be done? The only other way I could think of pulling it off would be dynamically checking all of the sitemap nodes for "(new!)" somewhere in the title and then adding the span block while the page is loading.
Thanks!
Knowledge is not power, however, the acquisition and appropriate application of knowledge can make you a very powerful individual.
|
|
|
|
|
If anyone runs into this, I figured out how to pull it off using the ItemDataBound event.
protected void Menu1_MenuItemDataBound(object sender, MenuEventArgs e)
{
if (e.Item.Text.Contains("(NEW!)"))
{
e.Item.Text = e.Item.Text.Replace("(NEW!)","<span style=\"color:red\">(NEW!)</span>");
}
}
Knowledge is not power, however, the acquisition and appropriate application of knowledge can make you a very powerful individual.
|
|
|
|
|
Hi guys,
I have a small problem, hope u could help me !
I'm tryin to use a custom validator on a Textbox !
Look :
<asp:textbox id="TextBox2" runat="server" visible="True" validationgroup="Test_Custom">
<asp:customvalidator id="first_CV" runat="server" onservervalidate="first_CV_ServerValidate" controltovalidate="TextBox2" errormessage="Complete this field" validationgroup="Test_Custom">*
The code behind now
protected void first_CV_ServerValidate(object source, ServerValidateEventArgs args)
{
if (TextBox2.Text == "")
{
args.IsValid = false;
}
else
{
args.IsValid = true;
}
}
Nothing changes if I set the ValidateEmptyText property of the CustomValidator CustomValidator to true.
Basically, I hoped to see a message when the Textbox is empty!
But nothin happen when Click on my submit button
Please help me
|
|
|
|
|
Why not use the RequiredFieldValidator [^]instead.
Manas Bhardwaj
Please remember to rate helpful or unhelpful answers, it lets us and people reading the forums know if our answers are any good.
|
|
|
|
|
REquiredFieldValidator is not appropriated cuze I try use the control on a TextBox with a visible mode is False in this case the RequiredFieldValidator doesn't work.
Help me about the custom validator, I think it's the only solution.
|
|
|
|
|
Why do you want a custom validator even?
You can just check the value of textbox before your processing begins and if its empty just display error message (whatever you want).
For example on button click event you can check the value of textbox and avoid further action if its empty.
HTH
|
|
|
|
|
I've run into this issue before as well where I had a textbox hidden and the requiredfield validator would mess the form up. I'm not sure what it is exactly you are attempting to pull off, but I've found it easier in some cases to just build the controls instead of hiding. For example, if you are hiding a textbox until someone clicks a button and then showing it, try this instead and then attach the required field validator to it....
TextBox tb1 = new TextBox();
RequiredFieldValidator re1 = new RequiredFieldValidator();
re1.ControltoValidate = tb1.ID;
divControl.Controls.add(tb1);
The above code needs some tweaking..but should give you the idea. The validator won't screw up the form because the textbox doesn't even exist until you place it as a new control.
That, or I've personally become quite fond of using javascript to validate forms...
var namebox = document.getElementById('<%= Name_textbox.ClientID %>');
if (namebox.value == ''){
var message = "We seem to be missing some information. Please correct the following items before submitting:\n\n";
if (namebox.value == '') {
message += "Name box cannot be blank.\n";
namebox.style.backgroundColor = 'yellow';
}
hopefully this helps! good luck
Knowledge is not power, however, the acquisition and appropriate application of knowledge can make you a very powerful individual.
|
|
|
|
|
Thanks compninja25 for helping,
Can u even tell me which language U R using here, is dat ...?
|
|
|
|
|
Oh sorry. The top part is c#, and the bottom code block is javascript.
Knowledge is not power, however, the acquisition and appropriate application of knowledge can make you a very powerful individual.
|
|
|
|
|
I have a listview that works fine but I would like to improve the appearance. Using codebehind, I insert textboxes into each listview cell. The cells are different colors. The space between the cells has gaps in the colors. Although the cells are grey, the space between two cells is white. I have tried tweaking borderstyle and bordercolor of the textbox but nothing changes.
I believe that my problem is caused by css. I took my html and browsed without the css file and things look different, so I will try to figure out what puts the gaps in.
But I would still like an answer for my amount fields.
I would also like a way to right align the currency fields within these textboxes. I can't get this to work well either.
Here is a portion of my code. I have bitmap image of the app but I can't insert this into my post.
Dim txtBox As New System.Web.UI.WebControls.TextBox
With txtBox
.BorderStyle = BorderStyle.None
.ReadOnly = True
.Text = " "
.BackColor = Drawing.Color.LightGray
.BorderColor = Drawing.Color.LightGray
End With
oRow.Cells(iCol).Control = txtBox
oRow.Cells(iCol).Control.Width = Unit.Percentage(100)
oRow.Cells(0).Control.BorderStyle = BorderStyle.None
The answer was found in this site.
.Style("TEXT-ALIGN") = TextAlign.Right.ToString()
I am not sure why there is a need for TEXT-ALIGN as well as ALIGN but my pages look much better now. The thing that I forgot is that webform controls are merely an aid to creating HTML. I need to understand the underlying HTML to make my site pleasing to the eye.
I appreciate any help on these issues.
modified on Monday, August 31, 2009 11:35 AM
|
|
|
|
|
i've set the property of edit in data gridview control..but why it is not working???The fields in my data gridview are databound....Any particular property i am missing?????????
|
|
|
|
|
How it is possible to find what you have missed without your coding
|
|
|
|
|
I dnt knw what code is to be written inside the row editing event...i had read in sme other article that just enabling the row_editing event will be sufficient....
Here my datasource is datatable..and the gridview rows are databound..is it needed to convert those rows to some controls like textbox to enable edit property?
|
|
|
|
|
For that Edit Property To Work .U need to use data source i.e. sqldatasource ,then it will work .Otherwise if u r binding data source programmatically then u need to use code and templates to databind u can the following link to do programmatically
GridView all in one[^]
|
|
|
|
|
There is a external css file with some classes and elements provided. I link it in the master page head section as from MSDN web sites templates:
<link href="themes/default/styles.css" rel="stylesheet" type="text/css" />
After I set in some button controls CssStyle to some of the css classes, in VS design view the style is changed but when the page is run, they are displayed without any styles applied.
How to link that stylesheet properly? or what is the problem
Чесноков
modified on Friday, August 28, 2009 8:42 AM
|
|
|
|
|
Style sheet design cant be seen in your design page . It will be applied only when the page gets executed. I don't know how to have seen the design of style sheet in your design view. Nothing wrong in your registration with the master page. Post more codes to get clarification.
|
|
|
|
|
In VS2008 there is addition of design view of your web page as it looks from the source, along with split, where you can watch both source code and the page look.
"Project.Master file"
<%@ Master Language="C#" AutoEventWireup="true" CodeBehind="GenderAge.master.cs" Inherits="GenderAge.GenderAge" %>
<html xmlns="http://www.w3.org/1999/xhtml" >
<head runat="server">
<asp:ContentPlaceHolder ID="head" runat="server">
</asp:ContentPlaceHolder>
<link href="themes/default/styles.css" rel="stylesheet" type="text/css" />
</head>
<body>
<form id="form1" runat="server">
<asp:ContentPlaceHolder ID="ContentPlaceHolder1" runat="server">
</asp:ContentPlaceHolder>
</form>
</body>
</html>
"Page.aspx file"
<%@ Page Title="" Language="C#" MasterPageFile="~/Project.Master" AutoEventWireup="true" CodeBehind="Page.aspx.cs" Inherits="Page.Main" %>
<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" runat="server">
<asp:Button ID="buttonFileUpload" runat="server"
Text="Upload" CssClass="buttons" />
</asp:Content>
Чесноков
|
|
|
|
|
What does the output HTML look like?
What are you putting in the head place holder? Is the / missing from the end of <asp:content id="Content1" contentplaceholderid="head" runat="server"> due to a cut and paste issue or is it missing from your page as well?
|
|
|
|
|
yes, it misses in the paste operation here.
I do not put anything in the head place holder Content1. Should I?
After I created the App_Themes folder and put there css file the styles become visible after the page is started.
However there is difference between VS2008 design view and the actual page, e.g. marging and padding does not work in some div controls???
Чесноков
|
|
|
|
|
hi all,
i have html table with some data.......now i want collect the data from this html table and then send the all data to the server-side through page method.
My logic is that in for-loop collect all data from html table and put in hashtable and then add this hashtable in an arraylist and then send this arraylist to server side.
Can anybody solve my problem?
|
|
|
|
|
Hello every one i want to upload an image by file uploader and want to store path of the image in database .please guide me.how can i do this
|
|
|
|
|
Did you tried FileUpload control??
It will help you upload the file and then also give you its path, you can then save the path in database.
|
|
|
|