15,896,154 members
Sign in
Sign in
Email
Password
Forgot your password?
Sign in with
home
articles
Browse Topics
>
Latest Articles
Top Articles
Posting/Update Guidelines
Article Help Forum
Submit an article or tip
Import GitHub Project
Import your Blog
quick answers
Q&A
Ask a Question
View Unanswered Questions
View All Questions
View C# questions
View C++ questions
View Javascript questions
View Visual Basic questions
View Python questions
discussions
forums
CodeProject.AI Server
All Message Boards...
Application Lifecycle
>
Running a Business
Sales / Marketing
Collaboration / Beta Testing
Work Issues
Design and Architecture
Artificial Intelligence
ASP.NET
JavaScript
Internet of Things
C / C++ / MFC
>
ATL / WTL / STL
Managed C++/CLI
C#
Free Tools
Objective-C and Swift
Database
Hardware & Devices
>
System Admin
Hosting and Servers
Java
Linux Programming
Python
.NET (Core and Framework)
Android
iOS
Mobile
WPF
Visual Basic
Web Development
Site Bugs / Suggestions
Spam and Abuse Watch
features
features
Competitions
News
The Insider Newsletter
The Daily Build Newsletter
Newsletter archive
Surveys
CodeProject Stuff
community
lounge
Who's Who
Most Valuable Professionals
The Lounge
The CodeProject Blog
Where I Am: Member Photos
The Insider News
The Weird & The Wonderful
help
?
What is 'CodeProject'?
General FAQ
Ask a Question
Bugs and Suggestions
Article Help Forum
About Us
Search within:
Articles
Quick Answers
Messages
Comments by
Pallavi Waikar
(Top 115 by date)
Pallavi Waikar
19-Jul-13 3:24am
View
for that u have to use two update panel one for autocomplete textbox and secound for grid panel and in _dopostback give name of secound update panel<br/>.I have also used one trick of secound textbox that will use to fill gridview
example:
<asp:UpdatePanel ID="UpdatePanel1" UpdateMode="Conditional" runat="server">
<contenttemplate>
<asp:TextBox ID="TextBox1" onkeyup="AssignValues();" runat="server" >
<ajax:AutoCompleteExtender ID="AutoCompleteExtender1" runat="server" TargetControlID="TextBox1"
MinimumPrefixLength="1" EnableCaching="true" CompletionSetCount="1" CompletionInterval="1000" ServiceMethod="GetEmployees" >
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<asp:UpdatePanel ID="UpdatePanel2" UpdateMode="Conditional" runat="server">
<contenttemplate>
<asp:GridView ID="GridView1" runat="server">
<br />
<asp:TextBox ID="TextBox2" runat="server" ontextchanged="TextBox2_TextChanged" style="display:none" AutoPostBack="True" >
<asp:HiddenField ID="HiddenField1" runat="server"
onvaluechanged="HiddenField1_ValueChanged" />
</div>
<script type="text/javascript">
function AssignValues() {
document.getElementById("TextBox2").value=document.getElementById("TextBox1").value;
PanalRefrshOnTextChange();
}
</script>
<script type="text/javascript">
function PanalRefrshOnTextChange() {
__doPostBack('<%= UpdatePanel2.ClientID %>', '');
};
//Code file use textbox2 textchange event
protected void TextBox2_TextChanged(object sender, EventArgs e)
{
string cn=ConfigurationManager.ConnectionStrings["testing"].ConnectionString;
using(SqlConnection connection = new SqlConnection(cn))
{
SqlCommand command = new SqlCommand("select * from country where EmployeeName like(@EmployeeName)", connection);
command.Parameters.AddWithValue("@EmployeeName", TextBox1.Text.Trim()+"%");
connection.Open();
SqlDataAdapter da = new SqlDataAdapter(command);
DataTable dt = new DataTable();
da.Fill(dt);
GridView1.DataSource = dt;
GridView1.DataBind();
connection.Close();
}
Pallavi Waikar
18-Jul-13 9:31am
View
it simple check text box is blank or not it not then do above code or in else bind it to null
example:
if (TextBox1.Text.Trim() != "")
{
//oyur bind code
}
else
{
GridView1.DataSource = null;
GridView1.DataBind();
}
Pallavi Waikar
18-Jul-13 6:44am
View
also use like in select query as i have used. it fill as value entered in textbox
Pallavi Waikar
18-Jul-13 6:42am
View
for that you have to use ajax update panel and trigger check update answer..check updated anser and try to implement in your code.
Pallavi Waikar
15-Jul-13 8:28am
View
I want to tell you this is also one way show confirmation box,i know this article is not for your question but can help u to show second confirm.you can also give one checkbox backup my data.In coding check for it and proceed as per value.
Pallavi Waikar
25-Jun-13 9:03am
View
Your referring this article compare with it http://www.aspdotnet-suresh.com/2011/01/how-to-insert-images-into-database-and.html
Pallavi Waikar
25-Jun-13 8:53am
View
Your <asp:GridView is missing closing tag check it
Pallavi Waikar
25-Jun-13 8:47am
View
As per your question you want to access mdi control toolstrip from your child form and that article is all about that i.e How to Access MdiParent Controls From Child Forms..understand it and implement it in your code.
Pallavi Waikar
4-Jun-13 10:21am
View
i think it is because of css.Refer solution 4 added using css hope it will help
Pallavi Waikar
24-May-13 3:35am
View
best way save lastuploaded imge as lastimage in folder .At every upload delete privous image and save new image with same name
private void StartUpLoad() {
//get the file name of the posted image
string imgName = FileUpload1.FileName;
//sets the image path
string imgPath = "Images/" + imgName;
//get the size in bytes that
int imgSize = FileUpload1.PostedFile.ContentLength;
//validates the posted file before saving
if (FileUpload1.PostedFile != null && FileUpload1.PostedFile.FileName != "")
{
// 10240 KB means 10MB, You can change the value based on your requirement
if (FileUpload1.PostedFile.ContentLength > 10240) {
Page.ClientScript.RegisterClientScriptBlock(typeof(Page), "Alert", "alert('File is too big.')", true);
}
else
{
//then save it to the Folder
if(File.Exists(Server.MapPath("~/images/lastimage.jpg"){
File.Delete(Server.MapPath("Images/lastimage.jpg");
}
FileUpload1.SaveAs(Server.MapPath("Images/lastimage.jpg"));
FileUpload1.SaveAs(Server.MapPath(imgPath));
Image1.ImageUrl = "~/images/" + imgPath;
Page.ClientScript.RegisterClientScriptBlock(typeof(Page), "Alert", "alert('Image saved!')", true);
}
}
}
and in html design add
<img id="img1" runat="server" src='~/Images/lastimage.jpg' alt='' style="height: 100px;
width: 100px;" />
OR u have save it in databse and on page load retrive it by number id top 1 order by id desc
Pallavi Waikar
24-May-13 0:25am
View
try HorizontalScrollBarVisibility="Visible" property of datagrid.
Pallavi Waikar
17-May-13 11:59am
View
ok.then add one temporary image control on page assign that url to image control..if image is displayed on image control then problem is here ShowPhoto.Controls.Add(Img);
Pallavi Waikar
17-May-13 10:42am
View
if postback is ocured then ImgBtn_Click is getting called..hence problem in code u have written in ImgBtn_Click ..check it
Pallavi Waikar
25-Apr-13 7:33am
View
is gui mean's graphical user interface that is windform app. if yes what string ur getting in gui
Pallavi Waikar
24-Apr-13 6:53am
View
i want to say ur id are like 1,2,3,...then ur last added id is 4 and u want to display it at end of grid then when u bind ur gridview at that time in select statement use order by clause.
Pallavi Waikar
24-Apr-13 5:02am
View
ok try onkeypress="return false;" of textbox...
<asp:textbox id="TextBox1" onkeypress="return false;" runat="server" >
<cc1:calendarextender id="CalendarExtender1" runat="server" OnClientDateSelectionChanged="AgeLimitCheck" TargetControlID="TextBox1" >
Pallavi Waikar
24-Apr-13 4:19am
View
is it related solution i have given.if not then past ur code of in reply
Pallavi Waikar
24-Apr-13 4:12am
View
ok..it's part of understanding if ur TagPrefix is cc1 then u have to use cc1 at place of asp for ajax control...try following
<asp:textbox id="TextBox1" runat="server" >
<cc1:calendarextender id="CalendarExtender1" runat="server" OnClientDateSelectionChanged="AgeLimitCheck" TargetControlID="TextBox1" >
i have also update solution
Pallavi Waikar
24-Apr-13 3:22am
View
calendarextender is Ajax control...it mean's u have not added reference of AjaxControlToolkit
Pallavi Waikar
23-Apr-13 10:48am
View
is it working...if not u can point it out ur welcome
Pallavi Waikar
23-Apr-13 10:41am
View
ok u want compulsory one uppercase letter ,one lowercase letter ,one special character letter in your password..and what u have post in ur above comment ur have not reffed my updated answer that's why ur facing problem ..again try below code :)
if (System.Text.RegularExpressions.Regex.IsMatch("^ggggHHHH^^^^", @"^(?=.*[a-z])(?=.*[A-Z])(?=.*[!@#$%^&*])"))
{
return;
}
else
{
label1.Visible = true;
label1.Text = "Enter at least one uppercase and leter in uppercase and lower case & special character";
}
i have checked it and it is allowing only password with all three condition
Pallavi Waikar
22-Apr-13 3:45am
View
i am trying to tell u that when u run this page of gridview all control id of girdview r change ,that's why run page view it's page source get there id and use it...if both textbox are empty then it is showing alert...try once
Pallavi Waikar
22-Apr-13 3:36am
View
Sir it is working on my side..i think he is beginner that's why not able to implement it.This regex is combination of all tree condition..i am still not able understand why he want throw error although he can able to show error in else part.
Pallavi Waikar
21-Apr-13 12:32pm
View
OK..try this code
private void txtpassword(object sender, EventArgs e)
{
try
{
if (System.Text.RegularExpressions.Regex.IsMatch("$#%hg#$Y%#$", @"^(?=.*[a-zA-Z])(?=.*[!@#$%^&*])"))
return;
else
{
label1.Visible = true;
label1.Text = "Enter at least one uppercase and leter in uppercase and lower case & special character";
}
}
catch (Exception ey)
{
label3.Visible = true;
label3.Text = "Enter at least one uppercase and leter in uppercase and lower case & special character";
}
Pallavi Waikar
21-Apr-13 11:48am
View
it's easy only u have to separate (?=.*[a-zA-Z]) into (?=.*[a-z])(?=.*[A-Z]) ...because then after upper and lower letter will checked independently ..check updated answer
Pallavi Waikar
21-Apr-13 8:20am
View
refer this link http://www.codeproject.com/Questions/65550/Access-Gridview-Footer-cell-via-Javascript...when u browse ur page view page source get id of TxtCompanyTagNo and TxtEmployeeTagNo.. and place in below code at place of gvEmp_ctl06_TxtEmployeeTagNo and gvEmp_ctl06_TxtCompanyTagNo
<asp:TextBox ID="TxtCompanyTagNo" runat="server">
<asp:TextBox ID="TxtEmployeeTagNo" runat="server">
<asp:CustomValidator id="CustomValidator1" runat="server"
ErrorMessage="CompanyTagNo or EmployeeTagNo Required"
Display="Dynamic"
ClientValidationFunction="CompanyTagOrEmployeeTag()" />
<script type="text/javascript">
function CompanyTagOrEmployeeTag()
{
var text=document.getElementById("gvEmp_ctl06_TxtEmployeeTagNo");
var text2=document.getElementById("gvEmp_ctl06_TxtCompanyTagNo");
if (text.value =="" && text2.value == "" )
{
alert('CompanyTagNo or EmployeeTagNo Required');
return false;
}
else
{
return true;
}
}
</script>
i think it should work
Pallavi Waikar
18-Apr-13 4:00am
View
click on project add "Microsoft Shell Controls And Automation” reference from com in ur project then do following code..
using Shell32;
private void btnUnzip_Click(object sender, EventArgs e)
{
Shell Sh = new Shell();
Folder SF = Sh.NameSpace(@"D:\gzipDemo\abcd.zip");
Folder DF = Sh.NameSpace(@"D:\gzipDemo");
foreach (FolderItem F in SF.Items()) DF.CopyHere(F, 0);
}
Pallavi Waikar
17-Apr-13 5:59am
View
ok...then try http://www.codeproject.com/Articles/18008/Simple-POP3-Email-Class
and http://www.c-sharpcorner.com/UploadFile/99bb20/getting-gmail-unread-email-through-atom-feed-in-Asp-Net/
Pallavi Waikar
17-Apr-13 5:57am
View
do u want by using "Microsoft Shell Controls And Automation” reference
Pallavi Waikar
17-Apr-13 3:52am
View
yes.... u can access that aspnet_users tabel ...by MembershipUser class..go to ur .cs page and try it...
Pallavi Waikar
13-Apr-13 5:17am
View
if these file name are from database...
then try
while (dr.Read())
{
FileInfo file = new FileInfo(Server.MapPath("deletedemo\\" + dr["filename"].ToString()));
if (file.Exists)
{
File.Delete(Server.MapPath("deletedemo\\" + dr["filename"].ToString()));
}
}
Pallavi Waikar
12-Apr-13 12:45pm
View
check updated answer
Pallavi Waikar
12-Apr-13 10:10am
View
have added EnableEventValidation="false" on page directive and
<Triggers>
<asp:PostBackTrigger ControlID="GridView1" />
</Triggers>
on update panel
Pallavi Waikar
12-Apr-13 4:57am
View
along with file uploader add button of name upload and use answer 2 from link http://stackoverflow.com/questions/11026908/i-am-unable-to-use-file-upload-which-is-in-gridview-in-the-update-panel-have-al...try this example
Pallavi Waikar
10-Apr-13 12:55pm
View
this will also work
string[] arr = @"\Library\Daino Royal - A.jpg,\Library\Abc.jpg,\Library\DEF.jpg,\Library\GHI.jpg,\Library\TIVOLI_GREY_A.jpg,\Library\URBANA_GREY - C.jpg".Replace(",", "").Replace("\\Library\\", ",").Remove(0, 1).Split(',');
foreach (string m in arr)
{
MessageBox.Show(m);
}
Pallavi Waikar
10-Apr-13 12:51pm
View
ok then try this one
MatchCollection matches = Regex.Matches(s, @"((\w*?\s*?-?\s*?){0,}\w*.jpg)");
Pallavi Waikar
10-Apr-13 12:00pm
View
for that use regex as
MatchCollection matches = Regex.Matches(s, @"(\w*?\s*?-?\s*?\w*.jpg)");
Pallavi Waikar
8-Apr-13 9:24am
View
i think ur confuse by seeing ur code in comment
Pallavi Waikar
8-Apr-13 9:09am
View
do one thing browse ur test.aspx page and copy url u see in address bar and past in comment then i will go through it again post new solution by deleting this one
Pallavi Waikar
8-Apr-13 8:44am
View
sorry i am not online for some time...it depends on www.xyz.com/test.aspx which ur sending in url..also check try updated solution..i am messing one important part over her..if ur trying it on localhost then...view test.aspx page in browser and paste that url at the place of www.xyz.com/test.aspx
Pallavi Waikar
8-Apr-13 7:57am
View
yes!!!! that's why we calculating hours difference in it...means if variable.TotalHours > 24 in test.aspx page then user get message time is expired to download and in else part write ur downloading code
if(variable.TotalHours > 24)
Response.Write("Download time is expired now");
else
//your download code
Pallavi Waikar
8-Apr-13 7:27am
View
i want to ask this test.aspx page link is posted in mail to user in which u have added current date time ...when u click on that link in mail...ur going to redirect to test.aspx page then how it is possible that u r going to have null value...
Pallavi Waikar
8-Apr-13 7:23am
View
i have already updated solution to
string myDate = Request.QueryString["period"];
if (!String.IsNullOrEmpty(myDate))
{
myDate=myDate.Replace("!",":");
DateTime dt1 = Convert.ToDateTime(myDate);
DateTime dt2 = DateTime.Now;
Timespan variable = dt2 - dt1;
if(variable.TotalHours > 24)
Response.Write("Download time is expired now");
else
//your download code
}
check it
Pallavi Waikar
8-Apr-13 7:18am
View
if user going to press already attached url witch have date parameter in it..then where is problem of null value...and i have checked code is working fine...i thick u missing something....above code of date in url u have to add in page from where ur sending mail and second part of calculating hours u have add in ur test.aspx page where u r going to do downloading...for that u have to check for if (!String.IsNullOrEmpty(myDate))..i going to update secondly code for it try it again
Pallavi Waikar
8-Apr-13 6:34am
View
try updated solution
Pallavi Waikar
8-Apr-13 6:27am
View
first check what value is coming in Request.QueryString["period"].ToString() by..
Response.Writ(Request.QueryString["period"].ToString());.....and go step by step...for this comment all remaining code...if value is same as u passed then try by string myDate=Request.QueryString["period"].ToString();
DateTime dt1 = Convert.ToDateTime(myDate);
Pallavi Waikar
8-Apr-13 6:17am
View
also take Solution 4 in consideration i have posted only demo...also follow solution 4 it helpful for security purpose
Pallavi Waikar
8-Apr-13 6:15am
View
add debug="true" in page directive see on which line error is present
Pallavi Waikar
8-Apr-13 6:14am
View
have u debug the code...one which line u r getting error?
Pallavi Waikar
6-Apr-13 9:49am
View
check updated solution
Pallavi Waikar
6-Apr-13 8:58am
View
give one example of value u adding in textbox
Pallavi Waikar
5-Apr-13 7:56am
View
try this DropDownList d = (DropDownList)(GridView1.Rows[e.NewEditIndex].FindControl("DropDownList1"));
Pallavi Waikar
5-Apr-13 6:57am
View
i forgot to remove m.pcode,..now edited above comment query try this
string str = string.Format(@"select m.pcode, m.fyyear ,sum(m.salary),sum(m.ta),sum(m.contigency),sum(m.nrc), sum(m.institcharges),sum(m.others),sum(y.yearlyalloc),sum(y.salary) as sal1,sum(y.ta) as ta1,sum(y.contigency) as cont1, sum(y.nrc) as nrc1,sum(y.institcharges) as inst1,sum(y.others) as other1 FROM monthly AS m , yearly as y where m.pcode=y.pcode and m.pcode=('" + DropDownList1.SelectedItem.Value.ToString() + "' ) AND y.fyyear like('" + DropDownList2.SelectedItem.Value.ToString() + "') and m.fyyear= y.fyyear group by m.pcode, m.fyyear", con);
Pallavi Waikar
5-Apr-13 6:52am
View
as i don't know ur database structure ...best way go to sql server and type this query if it working then place in str...do changes as per ur table structure
Pallavi Waikar
5-Apr-13 6:49am
View
for this if u have stored month in month table then check for m.month not in(3,4)
Pallavi Waikar
5-Apr-13 6:29am
View
ry this query
string str = string.Format(@"select m.pcode, m.fyyear ,sum(m.salary),sum(m.ta),sum(m.contigency),sum(m.nrc),
sum(m.institcharges),sum(m.others),sum(y.yearlyalloc),sum(y.salary) as sal1,sum(y.ta) as ta1,sum(y.contigency) as cont1,
sum(y.nrc) as nrc1,sum(y.institcharges) as inst1,sum(y.others) as other1 FROM monthly AS m , yearly as y
where m.pcode=y.pcode and m.pcode=('" + DropDownList1.SelectedItem.Value.ToString() + "' ) AND
y.fyyear like('" + DropDownList2.SelectedItem.Value.ToString() + "') and m.fyyear= y.fyyear
group by m.pcode, m.fyyear", con);
Pallavi Waikar
5-Apr-13 6:17am
View
if want one row use group by include other field related to amount in sum and u will get result....and if ur DropDownList2 contains values like "2012-2013"it will not going to work if y.fyyear value in database in like 2012
Pallavi Waikar
4-Apr-13 10:10am
View
sorry for incomplete solution and late reply i not online that time ...use this msdn article for that... http://msdn.microsoft.com/en-us/library/ff647312.aspx
Pallavi Waikar
4-Apr-13 5:10am
View
try this...first create store procedure that take no records u want that will return that much records
CREATE PROCEDURE dbo.GetQuestions (
@noOfRoas int
)
AS
SELECT * FROM Quiz WHERE Id in (SELECT DISTINCT TOP @noOfRoas id, NewID() as Random FROM Quiz ORDER BY Random)
-----------------
in c# use following code to access it
SqlConnection sqlConnection1 = new SqlConnection("Your Connection String");
SqlCommand cmd = new SqlCommand();
SqlDataReader reader;
int noOfRows=5;
cmd.CommandText = "GetQuestions";
cmd.CommandType = CommandType.StoredProcedure;
cmd.Parameters.Add(new SqlParameter("@noOfRoas", SqlDbType.Int)).Value = noOfRows;
cmd.Connection = sqlConnection1;
sqlConnection1.Open();
reader = cmd.ExecuteReader();
// Data is accessible through the DataReader object here.
sqlConnection1.Close();
Pallavi Waikar
4-Apr-13 3:27am
View
after posting this i saw problem solved that's why i post this sorry
Pallavi Waikar
2-Apr-13 23:43pm
View
if u mean o/p 12345,678,945,63,9484 is list items separated by comma...u want get this messages by separating ^ and store in list array ...then in ur main code there is need to do some changes exa.
string[] array = new string[] { "12", "34", "5^67", "8^945", "^63^", "9484^" };
List<string> myString=new List<string>();
foreach (string message in array)
{
if (message.Contains("^"))
{//remove char ^ process
string message1 = message;
while (message1.Contains("^") || message1!="")
{
int pos = -1;
pos = message1.IndexOf('^');
if (pos != -1)
{
outputString = message1.Substring(0, pos);
message1 = message1.Substring(pos + 1);
if (tempString != "" || outputString != "")
{
outputString = tempString + outputString;
myString.Add(outputString);
tempString = "";
}
}
else
{
tempString = message1;
message1 = "";
}
}
}
else
{
outputString = outputString + message;
tempString = tempString + message;
}
}
textBox1.Text = string.Join(",",myString.ToArray());
i think it will help u.
Pallavi Waikar
2-Apr-13 9:21am
View
then he has to provide one datetimepicker.. and based on it dropdownlist is filled..if date is privious then no need to check hourse or minute and if date==datetime.now() then he has to use above code and if date is greater than today date then no data is inserted in dropdownlist..it is done by using if else statement
Pallavi Waikar
2-Apr-13 8:10am
View
sorry sir.. still i am not worked on it
Pallavi Waikar
2-Apr-13 7:44am
View
ok that was ur problem..now u get reason that is important...
Pallavi Waikar
2-Apr-13 7:05am
View
ok.sorry for late reply i m not online that time..best way when u ger ur final o/p.. u should use replace method and then apply string.Format on it for commas that u want for example. if ur final o/p is finalOpStr then use like this finalOpStr =finalOpStr.Replace("^", ""); finalOpStr = string.Format("9999,999,999,99,9999", finalOpStr).ToString(); also check updated answer
Pallavi Waikar
2-Apr-13 3:57am
View
Thanks sir.
Pallavi Waikar
2-Apr-13 3:57am
View
String.join is used at the place of for loop..they are equivalent in this case for array
Pallavi Waikar
28-Mar-13 9:20am
View
No comment
Pallavi Waikar
28-Mar-13 7:53am
View
check this link for help http://www.codeguru.com/csharp/.net/net_asp/webforms/article.php/c5467/Sending-EMail-with-SystemWebMail.htm...but they are not using server.MapPath...that u have to change
Pallavi Waikar
28-Mar-13 6:40am
View
try for another image..there is no problem in code...check ur image folder present in ur website folder
Pallavi Waikar
28-Mar-13 4:00am
View
in Server.MapPath also add ur site name as updated solution
for example if websitefolder name is myEmailDemo and in that ur image folder is present then u have to use Server.MapPath(@"/myEmailDemo/Images/book-cover.jpg");
Pallavi Waikar
28-Mar-13 3:19am
View
there problem in path provited check exact path of image folder and use it in Server.MapPath...use string path = Server.MapPath(@"/webSiteFolderName/Images/book-cover.jpg");
Pallavi Waikar
28-Mar-13 2:44am
View
then try..
MailAttachment attachment = new MailAttachment(path);
msg.Attachments.Add(attachment);
is it ok now
Pallavi Waikar
28-Mar-13 2:37am
View
first check ur image is present in image folder..check updated solution
Pallavi Waikar
25-Mar-13 5:29am
View
try this code....
<script type="text/javascript">
function zoomings(optionSel)
{
if (navigator.userAgent.indexOf("Firefox")!=-1)
{
var OptionSelected = optionSel.selectedIndex;
var optionT = document.getElementById ("zooming");
var len=optionT.options[OptionSelected].text.length-1;
var val = optionT.options[OptionSelected].text.substring(0,len)/100;
var div = document.getElementById ("searches");
var dd="scale("+ val +")";
div.style.MozTransform = dd;
div.style.MozTransformOrigin = "0 0";
}
else{
var OptionSelected = optionSel.selectedIndex;
var val = optionSel.options[OptionSelected].text;
var div = document.getElementById ("searches");
div.style.zoom = val;
}
}
</script>
<div id="searches">zoom this element</div>
<span>Zoom</span><select id='zooming' önchange="zoomings(this);">
<option value="25%">25%</option>
<option value="50%">50%</option>
<option value="75%">75%</option>
<option value="100%" selected="selected">100%</option>
<option value="150%">150%</option>
<option value="200%">200%</option>
<option value="250%">250%</option>
<option value="300%">300%</option>
</select>
Pallavi Waikar
25-Mar-13 5:04am
View
check updated above comment
Pallavi Waikar
25-Mar-13 4:52am
View
try this for firefox
var optionT = document.getElementById ("zooming");
var len=optionT.options[OptionSelected].text.length-1;
var val = optionT.options[OptionSelected].text.substring(0,len)/100;
var div = document.getElementById ("searches");
var dd="scale("+ val +")";
div.style.MozTransform = dd;
div.style.MozTransformOrigin = "0 0";
now u have check browser if chrome then first code for other use this ...for more search on google for now i can help u up to this only
Pallavi Waikar
25-Mar-13 3:55am
View
also check this links http://stackoverflow.com/questions/7175766/object-style-zoom-property-not-working-in-firefox
and
http://stackoverflow.com/questions/4049342/how-can-i-zoom-a-div-in-firefox-and-opera
Pallavi Waikar
25-Mar-13 3:40am
View
then try this link for jquery http://stackoverflow.com/questions/13931225/how-to-zoom-div-content-using-jquery
Pallavi Waikar
25-Mar-13 3:38am
View
is ur div is like this <div id="searches">zoom content</div>...then it must work
Pallavi Waikar
25-Mar-13 3:33am
View
best way search in select query cmd= "select * from urTablename where emailId= '"+txtenrEmail.Text+"'"
and use if instead of while
dr=cmd..ExecuteReader();
if (dr.Read())
{
if (dr["emailId"].ToString() !=txtenrEmail.Text)
{
string uid=dr["userid"].ToString();
string emailid=dr["emailId"].ToString();
Label1.Text = "User details Inserted successfully";
}
else
{
Label1.Text = "Emailid already exists. Use another EmailId";
}
}
Pallavi Waikar
25-Mar-13 3:19am
View
check updated answer
Pallavi Waikar
25-Mar-13 2:46am
View
i think u r facing this problem becouse u already get all values of dr using while and then ur trying to update...best way store this values in two variable in while and use them for update..i.e string userid =dr["userid"].ToString() ; when get match in while
Pallavi Waikar
13-Mar-13 6:37am
View
don't ask anyone like this send me answer it will affect u by avoiding other to help u...check out updated query...not sure but try...and test for more values.
Pallavi Waikar
12-Mar-13 6:39am
View
good :)
Pallavi Waikar
11-Mar-13 2:01am
View
Deleted
No comment
Pallavi Waikar
11-Mar-13 1:51am
View
check updated answer...to know more about VerifyRenderingInServerForm go through this link http://msdn.microsoft.com/en-us/library/system.web.ui.page.verifyrenderinginserverform.aspx...if u still facing problem then point me out by reply...because it is working for me
Pallavi Waikar
11-Mar-13 0:28am
View
i am not getting ur problem...r u want do insert update record from cs. then simply search on google for "how to insert upadate record in sql server from asp.net c#"
Pallavi Waikar
11-Mar-13 0:25am
View
firstly it is another question...don't post in comment..and in fileupload.PostedFile.FileName .. filename is read only property of fileuploader...we cant change it run time...
Pallavi Waikar
10-Mar-13 10:37am
View
then add two hiddenfield on page after saving image swap values ..then add in arraylist ...and bind that arraylist to datalist...for exampal...try it as demo..change as ur requirement
fileuploadimages.SaveAs(Server.MapPath("~//UploadedFiles//" + filename));
if (HiddenField1.Value != "")
HiddenField2.Value = HiddenField1.Value;
HiddenField1.Value = "UploadedFiles/" + filename;
ArrayList ImageName = new ArrayList();
FileInfo info = new FileInfo(Server.MapPath(HiddenField1.Value));
ImageName.Add(info);
if (HiddenField2.Value != "")
{
FileInfo info2 = new FileInfo(Server.MapPath(HiddenField2.Value));
ImageName.Add(info2);
}
Image2.ImageUrl="~//UploadedFiles//" + filename;
DataList1.DataSource = ImageName;
DataList1.DataBind();
Pallavi Waikar
10-Mar-13 8:35am
View
it is simpal after saving that file u have to show in image control...as given in above code before binding to datalist ....give that file name as imageurl for image.. upBrandImages.SaveAs(Server.MapPath("~//UploadedFiles//" + filename));Image2.ImageUrl="~//UploadedFiles//" + filename; BindDataList();
Pallavi Waikar
10-Mar-13 7:37am
View
ok then use both image control and datalist...newly added image automaticaly displayed in imge box...and all other images will displayed by binding datalist to folder simpal i.e
upBrandImages.SaveAs(Server.MapPath("~//UploadedFiles//" + filename));Image2.ImageUrl="~//UploadedFiles//" + filename;
BindDataList();
Pallavi Waikar
10-Mar-13 7:20am
View
if u want to show only one image then why r using datalist ....
u can simply add one image control and after saving that image only set ImageUrl of image control i.e upBrandImages.SaveAs(Server.MapPath("~//UploadedFiles//" + filename)); Image2.ImageUrl="~//UploadedFiles//" + filename;
Pallavi Waikar
10-Mar-13 6:50am
View
sorry for late reply i am bessy in other task..u have to mix this article with this article http://www.aspdotnet-suresh.com/2011/12/jquery-lightbox-image-slideshow-gallary.html...means use code for load images of first article...and append in second article to disply images...hope u can manage it..he has giving anchor tag to images
Pallavi Waikar
8-Mar-13 10:17am
View
first time it not going to work because u r checking for
if (IsPostBack)
..on second time on page postback will show values..if not then there is might be any problem
Pallavi Waikar
7-Mar-13 22:59pm
View
refer following demo ....hope it will help u
Pallavi Waikar
1-Mar-13 2:40am
View
but he is not using Server.MapPath ..he is only checking file name...but not in folder in which he want to store file...if i am wrong..please tell me reason....i am also trying to learn here
Pallavi Waikar
25-Feb-13 8:19am
View
also check out updated answer
Pallavi Waikar
25-Feb-13 4:11am
View
then why dont u call validate fuction on OnClientClick event of button.
exampal....<asp:Button runat="server" ID="btnSubmit" OnClientClick="return Valiadate()"
onclick="btnSubmit_Click" Text="Submit" />
and use javascript as it is which ur mentioned in ur question
Pallavi Waikar
25-Feb-13 3:38am
View
then ur javascript was not working...this should work..if u want to call $.showprogress(); on true of confirmation then add it in else part...if not then i can help u up to this only...check ur code
Pallavi Waikar
25-Feb-13 3:26am
View
use int result1=Convert.ToInt32(HiddenField1.Value);
Pallavi Waikar
25-Feb-13 2:49am
View
No comment
Pallavi Waikar
19-Feb-13 4:58am
View
my given first answer that was working..where r u facing problem.
Image1.ImageUrl = "~/" + dr["Imagepath"].ToString();
You have to give some trial an error on given solution.
You have to change it as per ur requirement.
Pallavi Waikar
19-Feb-13 2:47am
View
u r not assigning that value to image2..r u very new in programming u must know such small things
Image2.ImageUrl=Server.MapPath("/" + dr["ImagePath"].ToString());
Pallavi Waikar
19-Feb-13 2:33am
View
then this must work...Server.MapPath("~/" + dr["Imagepath"].ToString());
Look we have so many in build method only we have to make them flexible as our reqirement.
for exampal if ur database vlue is "images/304209_498610120191929_148341689_n.jpg"
that's why we no need to give image folder name for mappath.
Pallavi Waikar
19-Feb-13 2:21am
View
past here ur one database value of imagePath.then i will check.
Pallavi Waikar
19-Feb-13 2:05am
View
only u have to remove image from mappath.
that means u have store images in images named folder
u have store path as "images/imagename" in database.
try this
Server.MapPath("/" + dr["Imagepath"].ToString());
hope this time it will work
Pallavi Waikar
19-Feb-13 1:55am
View
u can also try Server.MapPath("/Image/" + dr["Imagepath"].ToString());.
it will also depends on what path u have stored in database.It for imagename from database and map it using MapPath
Pallavi Waikar
17-Feb-13 11:51am
View
have u added reference of that user control on ur page..and also check for runat attribute <myCtr.MyUserControl id="MyUserControl" runat="server"/> in .aspx page...for help check following link. http://msdn.microsoft.com/en-us/library/c0az2h86%28v=vs.100%29.aspx
Pallavi Waikar
2-Feb-13 12:25pm
View
go through following link...it it help you a lot..... http://www.dotnetcurry.com/ShowArticle.aspx?ID=129....compare ur code with this code...
Pallavi Waikar
24-Jan-13 9:18am
View
is this validation is for decimal value...then only u have to do is remove ? from expression...... ? mean's dot is may required or not in i/p...i.e it allow both single and decimal values..use "^[0-9]*\.[0-9]*$" .....in ValidationExpression
Pallavi Waikar
9-Jan-13 5:53am
View
i go through the FileUpload properties there not any such property to which u can set filepath to it.....it is server control that's why on page reload browse filename is not present on control
Pallavi Waikar
8-Jan-13 6:10am
View
is that button is server control i.e
Pallavi Waikar
7-Jan-13 0:57am
View
how should i know his database...i wrote here he has to use joins and have some connection in then..that was an exampal...
Pallavi Waikar
5-Jan-13 9:10am
View
Deleted
as i know..i think we have do same connectivity coding to retrieve data from one or more column from database
exa."select col1,col2,col3 from abc" for multipal and
"select col1 form abc" for one column select col1 for...if not then i really want to know this type of connectivity.
Or cmd.ExecuteScalar() that return only one column value for aggregate function i.e "select max(id) from abc"
Show More