|
Or use ImageButton . set imagerul property .
|
|
|
|
|
Use ImageButton Control .
sepel
|
|
|
|
|
You can make a button with an image background. You can also make an image that acts as a button-
<img src='test.png' onClick="buttonFunction()">
This can enact a Javascript function or what have you.
Ranjit Viswakumar
Professional Services Specialist
http://hostmysite.com/?utm_source=bb
|
|
|
|
|
hi all ,
I am developing advertising Website-Registering Impression,click etc..here problem is whenever user registering Impression that we are loss the 40% impression and here we doing geolocation also.I attached following code also..Plz reply me if u know...Thanks
using System;
using System.Data;
using System.Data.SqlClient;
using dataacesslayer;
using System.Web;
public partial class Admin_getbase : System.Web.UI.Page
{
string Crid = "";
SqlConnection conn = null;
SqlCommand cmdinsert = null;
protected void Page_Load(object sender, EventArgs e)
{
Response.Cache.SetCacheability(HttpCacheability.NoCache);
SqlParameter paramvalue;
conn = new SqlConnection("Data Source=dddd;Initial Catalog=new;User ID=fg;Password=hg");
if (Request.QueryString["Crid"] != null)
{
Crid = Request.QueryString["Crid"].ToString();
}
try
{
cmdinsert = new SqlCommand("sd_Basreg", conn);
cmdinsert.CommandType = CommandType.StoredProcedure;
paramvalue = new SqlParameter("@Crid", SqlDbType.Int);
paramvalue.Direction = ParameterDirection.Input;
paramvalue.Value = Crid;
cmdinsert.Parameters.Add(paramvalue);
paramvalue = new SqlParameter("@IpNum", SqlDbType.BigInt);
paramvalue.Direction = ParameterDirection.Input;
paramvalue.Value = IpAddress();
cmdinsert.Parameters.Add(paramvalue);
conn.Open();
cmdinsert.ExecuteNonQuery();
Response.ContentType = "text/plain"; Response.Write("&imp=registered&");
}
catch (Exception ex)
{
cmdinsert = new SqlCommand("sd_Basreg", conn);
cmdinsert.CommandType = CommandType.StoredProcedure;
paramvalue = new SqlParameter("@Crid", SqlDbType.Int);
paramvalue.Direction = ParameterDirection.Input;
paramvalue.Value = Crid;
cmdinsert.Parameters.Add(paramvalue);
paramvalue = new SqlParameter("@IpNum", SqlDbType.BigInt, 50);
paramvalue.Direction = ParameterDirection.Input;
paramvalue.Value = "0";
cmdinsert.Parameters.Add(paramvalue);
conn.Open();
cmdinsert.ExecuteNonQuery();
Response.ContentType = "text/plain"; Response.Write("&imp=registered&");
}
finally
{
cmdinsert.Dispose();
conn.Close();
if (conn.State == ConnectionState.Open)
{
conn.Close();
conn.Dispose();
}
}
}
private string IpAddress()
{
string IPCity = "";
string strIpAddress;
strIpAddress = Request.ServerVariables["HTTP_X_FORWARDED_FOR"];
string IpAddress = strIpAddress;
Array IpPart = IpAddress.Split('.');
Int64 IpNum = 16777 * Convert.ToInt64(IpPart.GetValue(0)) + 636 * Convert.ToInt64(IpPart.GetValue(1)) + 26 * Convert.ToInt64(IpPart.GetValue(2)) + Convert.ToInt64(IpPart.GetValue(3));
return IpNum.ToString();
}
}
Create PROCEDURE [dbo].[sd_Basreg]
@Crid int,@IpNum varchar(50)
AS
begin
Insert into S_Base(CrId,IpNum) values(@Crid,@IpNum);
end
Please reply me ...if any optimizing code for this
Raaj
|
|
|
|
|
Raj,
I am sure no one will read the entire code and come up with a solution. You will get good replies if you post only relevant code and explain the issues clearly.
|
|
|
|
|
concept is whenever getting the impression we are insert +1 to database with creative ID,Already Inserted means we are Updating...the problem is In clientSide(Company Client) server is showing impression more than Our Application(we handling other server)....Both server sholud be display same...
that means we are lossing the impression..
Plz help me in this
Raaj
|
|
|
|
|
hi everyone,
I got a System.Web.UI.HtmlControls.HtmlInputPassword control in a page i try to intialize it but no value was shown.
protected global::System.Web.UI.HtmlControls.HtmlInputPassword Password1;
this.Password1.Value = "TOTO";
How can i show init password Control.
thank you for help!!
|
|
|
|
|
Hi,
I've given my img in master page. I can see the img at design time in master page itself. I'm using this master page in my Login.aspx. I've given the proper path for image also. But I could not get this image at run time and design time of my login page. What the problem, which I did? Anybody help me.
this is my master page code
<html>
<body>
<div id = "div1" runat ="server" >
<table width=100% height=4 bgcolor=eeeeee>
<tr valign ="middle"><td width = "20%" height ="15%">
<img src="../Images/Currency2.jpg" border="0"/></td>
<%--<asp:Image runat="server" ImageUrl ="~/Images/Currency2.jpg" BorderStyle = "None" />--%>
<td width = "80%" align ="center"><I><B>BULLET - Receipt And Payment Module</B></I></td>
</tr>
</table>
</div>
Balasubramanian K.
|
|
|
|
|
Try
<img src="~/Images/Currency2.jpg" border="0" runat="server"/>
|
|
|
|
|
Already I'd tried with this symbol. If I use this, I could not see at design time also. Anyother soln. Thanks
Balasubramanian K.
|
|
|
|
|
BalasubramanianK wrote: Already I'd tried with this symbol.
Made it runat=server ? It will work only if runat=server is set.
Could you post your directory structure? Where is this Login page resides? If you come out of the directory where login page exists, can you see the images directory? Problem is the image path. ../Images/Currency2.jpg not found from the login page.
|
|
|
|
|
In my solution, I've two folders such as Images and MasterPages. Currency2.jpg contains in Images folder. Common.master conains in MasterPages folder. My page name is login.aspx, which does not contained in any folder.
I've given my runat = server at my division itself. If I move my image from image folder to masterPage folder, It is working properly. I could not find the problem of path of the image. Because, I never typed the path directly. Using the pick up in visual studio, option I selected the file name.
Balasubramanian K.
|
|
|
|
|
BalasubramanianK wrote: My page name is login.aspx, which does not contained in any folder.
Then the image path should be Images/Currency2.jpg . Try that.
|
|
|
|
|
If I remove ../ I cld not see at design time itself of the master page. So, basically it will not come at run time. I think that ../ should be there. I think that ../ takes me to come back one step to my project folder from the currency2.jpg.
Balasubramanian K.
|
|
|
|
|
|
Can a code work in the Textbox Keypress event. I want action perfomed when a key is pressed in a text box. It worked in C#/VB.net but not in ASP. HOW? VALIDATION
|
|
|
|
|
onyang2 wrote: Can a code work in the Textbox Keypress event.
Yes. What code are you talking about? A server side code? You need to enable AutoPostback for that.
|
|
|
|
|
Web Is so different from Win.
You must use JavaScript to handle key event.
sepel
|
|
|
|
|
Web applications are little different because you have server-side and client-side processing. Getting the page to validate on the fly can be done by AutoPostBack but this can get resource consuming for every keystroke. These types of changes are better fielded by the browser using Javascript-
http://w3schools.com/jsref/jsref_onchange.asp[^]
The onChange event can be used to enact form validation. If you really need some VB or C# in play here, you might try to enact some AJAX with the onChange event. Good luck.
Ranjit Viswakumar
Professional Services Specialist
http://hostmysite.com/?utm_source=bb
|
|
|
|
|
actually i used file upload control for saving file of article. now i want to show article and i have given a link foe file loading a file . then pls help me where this file will save . and from where i pick it loading time.in database only file name saved.
|
|
|
|
|
Your question is not clear. Don't you know where you saved the file on server ?
|
|
|
|
|
means how to store file in server when name stored in database and how to pick it when user want to load it
|
|
|
|
|
Do you have any ideas for so kind of chart?
|
|
|
|
|
use XML based RDLC Reports to create Charts....
Its good.
Abhishek Sur
|
|
|
|
|
Use the one comes with Crystal Report. Or use Google charts.
|
|
|
|