|
hi,
i have useing asp.net 2.0 and ajax extension.
i have pass 3 value to popup window...if update some values in child(popup) window. its automatically refresh particular (update panel or) gridview in parent page.
i have code for refresh parent window. but i dont have code for refresh particular window.Yours,
KaNNaN
-----------------------------------------------------------------
"Success is When Ur Signature Becomes An Autograph"
|
|
|
|
|
are you using that popup from same page or open popup from another page?
|
|
|
|
|
(New) another page Yours,
KaNNaN
-----------------------------------------------------------------
"Success is When Ur Signature Becomes An Autograph"
|
|
|
|
|
Dear all,
I was doing a calculation on the total of costs using datagrid. There are only two row in my data. I use the following to insert the summary to the footer but is not success which is as below:
For RawCount = 0 To ItemCount - 1
Quantity(RawCount) = Me.dtGrid.Items(RawCount).Cells(2).Text
Price(RawCount) = Me.dtGrid.Items(RawCount).Cells(5).Text
Costs(RawCount) = Quantity(RawCount) * Price(RawCount)
Me.dtGrid.Items(RawCount).Cells(6).Text = Costs(RawCount)
TotalQuantity = Quantity(RawCount) + TotalQuantity
TotalCost = TotalCost + Costs(RawCount)
If Me.dtGrid.Items(RawCount).ItemType = ListItemType.Footer Then
Me.dtGrid.Items(RawCount).Cells(2).Text = TotalQuantity
End If
Could anyone please help me check what is the problem and why the data is not display in my footer raw?
Thank you so much for the help!
|
|
|
|
|
Please refer from Here[^]
|
|
|
|
|
Hi all,
Use the google graph API if you need any graph requirement in your application, its really good
See the example:
<html>
<head>
<script type="text/javascript" src="http://www.google.com/jsapi"></script>
<script type="text/javascript">
google.load("visualization", "1", {packages:["piechart"]});
google.setOnLoadCallback(drawPieChart);
// google.load("visualization", "1", {packages:["barchart"]});
// google.setOnLoadCallback(drawBarChart);
function drawBarChart() {
// Create and populate the data table.
var data = new google.visualization.DataTable();
data.addColumn('string', 'Year');
data.addColumn('number', 'Sales');
data.addColumn('number', 'Expenses');
data.addColumn('number', 'Expenses1');
data.addColumn('number', 'Expenses2');
data.addColumn('number', 'Expenses3');
data.addColumn('number', 'Expenses4');
data.addColumn('number', 'Expenses5');
data.addColumn('number', 'Expenses6');
data.addColumn('number', 'Expenses7');
data.addColumn('number', 'Expenses8');
data.addColumn('number', 'Expenses9');
data.addRows(1);
data.setValue(0, 0, '');
data.setValue(0, 1, 1000);
data.setValue(0, 2, 400);
data.setValue(0, 3, 700);
data.setValue(0, 4, 40);
data.setValue(0, 5, 90);
data.setValue(0, 6, 480);
data.setValue(0, 7, 120);
data.setValue(0, 8, 100);
data.setValue(0, 9, 400);
data.setValue(0, 10, 200);
data.setValue(0, 11, 100);
new google.visualization.BarChart(document.getElementById('chart_div')).
draw(data, {width: 600, height: 440, is3D: true});
}
function drawPieChart() {
var data = new google.visualization.DataTable();
data.addColumn('string', 'Expense Item');
data.addColumn('number', 'Expense');
data.addRows(8);
data.setValue(0, 0, 'Food');
data.setValue(0, 1, 11);
data.setValue(1, 0, 'Drinks');
data.setValue(1, 1, 2);
data.setValue(2, 0, 'Cinima');
data.setValue(2, 1, 2);
data.setValue(3, 0, 'party');
data.setValue(3, 1, 2);
data.setValue(4, 0, 'smoke');
data.setValue(4, 1, 7);
data.setValue(5, 0, 'smoke2');
data.setValue(5, 1, 7);
data.setValue(6, 0, 'smoke3');
data.setValue(6, 1, 7);
new google.visualization.PieChart(document.getElementById('chart_div')).
draw(data,{width: 600, height: 440, is3D: true});
}
</script>
</head>
<body>
<div id="chart_div"></div>
</body>
</html>dhdh
|
|
|
|
|
Hey its nice. thank you. But can you give any URL for this. Naina
|
|
|
|
|
|
|
Hi,
I want "Enter" Key press count fro .doc file. I am using ASCII value of "Enter" Key . But How can I find using stramreader while reading file.
Or any other Solution for that?
Thanks,
sjs
|
|
|
|
|
Well, it doesn't seems to be related to Asp.net.
I think C# forum will be more suitable for this question.
Anyways, streamReader may not work for this.
Read your word file text using Microsoft Word Object library,
and get the text in the string. After that you can easily find
"\r\n" characters in your text.
|
|
|
|
|
Hi,
on pressing enter button to submit the login details it is working in IE but it is not working in Firefox could anyone help iam using the javascript function
function doClick(buttonName,e)
{
//the purpose of this function is to allow the enter key to
//point to the correct button to click.
var key ;
if(window.event)
key = window.event.keyCode; //IE
else
key = e.which; //firefox
if (key == 13)
{
//Get the button the user wants to have clicked
var btn = document.getElementById(buttonName);
if (btn != null)
{ //If we find the button click it
btn.click();
event.keyCode = 0
}
}
}
Thanks & Regards,
Nath
|
|
|
|
|
I am newbie to webservices
I am trying to learn about them, but got struck in the first place itself. Please help me out.
My service.cs in the web service.
--------------------------------
using System;<br />
using System.Web;<br />
using System.Web.Services;<br />
using System.Web.Services.Protocols;<br />
<br />
[WebService(Namespace = "http://localhost:1458/forumservices/")]<br />
[WebServiceBinding(ConformsTo = WsiProfiles.BasicProfile1_1)]<br />
public class Service : System.Web.Services.WebService<br />
{<br />
public Service () {<br />
<br />
}<br />
<br />
<br />
[WebMethod]<br />
public string welcome(string name)<br />
{<br />
return "Welcome " + name;<br />
}<br />
<br />
}
now on a button click from another web page
protected void Button1_Click(object sender, EventArgs e)<br />
{<br />
<br />
try<br />
{<br />
soapMessage =<br />
@"<br />
<?xml version=""1.0"" encoding=""utf-8""?><br />
<soap12:Envelope xmlns:xsi=""http://www.w3.org/2001/XMLSchema-instance"" xmlns:xsd=""http://www.w3.org/2001/XMLSchema"" xmlns:soap12=""http://www.w3.org/2003/05/soap-envelope""><br />
<soap12:Body><br />
<welcome xmlns=""http://localhost:1458/forumservices/""><br />
<name>Rajas</name><br />
</welcome><br />
</soap12:Body><br />
</soap12:Envelope>";<br />
<br />
WebClient mClient = new WebClient();<br />
<br />
<br />
<br />
Response.Write(System.Text.Encoding.ASCII.GetString(mClient.UploadData("http://localhost:1458/forumservices/Service.asmx", "POST", System.Text.Encoding.ASCII.GetBytes(soapMessage))));<br />
}<br />
catch (System.Net.WebException ex)<br />
{<br />
if (ex.Response != null)<br />
{<br />
Stream strm = ex.Response.GetResponseStream();<br />
StreamReader sr = new StreamReader(strm);<br />
Response.Write(sr.ReadToEnd());<br />
}<br />
else<br />
{<br />
Response.Write(ex.InnerException.ToString());<br />
}<br />
}<br />
<br />
}
The compilation is fine, but i keep getting some errors as below
"The remote server returned an error: (500) Internal Server Error."
Please help me outJack Sparrow
--------------------------------------
Defeat is not the worst of failures. Not to have tried is the true failure.
|
|
|
|
|
According to me to consume webservice in you application you need to add webreferace of webservice in you application
than to call web service you need to create objct of that and than you can call webservice.
Check on following link which give you idea about how to consume website.
<a href="http://it.toolbox.com/wiki/index.php/Calling_a_web_service_from_Asp.net">http://it.toolbox.com/wiki/index.php/Calling_a_web_service_from_Asp.net</a>[<a href="http://it.toolbox.com/wiki/index.php/Calling_a_web_service_from_Asp.net" target="_blank" title="New Window">^</a>]
|
|
|
|
|
|
Sashi,
When I call it using web reference it is working fine.
But I have to manually call the web service using xml+soap. got any ideasJack Sparrow
--------------------------------------
Defeat is not the worst of failures. Not to have tried is the true failure.
|
|
|
|
|
No Brother..!
LatestArticle :Log4Net
Why Do Some People Forget To Mark as Answer .If It Helps.
|
|
|
|
|
Hi all,
in my website i need to concatenate some memory streams and export like
response.binarywrite(memorystream.toarray())
in the memory stream i need to concatenate some more memory streams also,
how to do this, is it possible by means of changing by bytes or something like that??
please help me
|
|
|
|
|
Do you mean something like this?
MemoryStream MS1 = new MemoryStream(new byte[] { 0x01, 0x02, 0x03 });
MemoryStream MS2 = new MemoryStream(new byte[] { 0x04, 0x05, 0x06 });
MemoryStream MS3 = new MemoryStream();
MS3.SetLength(MS1.Length + MS2.Length);
MS3.Write(MS1.ToArray(), 0, (int)MS1.Length);
MS3.Write(MS2.ToArray(), 0, (int)MS2.Length);
Byte[] Result = MS3.ToArray();
foreach (Byte B in Result)
Response.Write(B.ToString() + " ");
Steve Wellens
|
|
|
|
|
thanks for your response,
i tried this code,
but in your code the second line MS3.write will over write(replace) the MS1.
that is my problem here as i am unable to write over, can you tell me more please
|
|
|
|
|
Really?
I included test output and it looked like this:
1 2 3 4 5 6
Nothing was overwritten.Steve Wellens
|
|
|
|
|
DataTable dt = new DataTable();
dt = _dal.ExecuteQuery_Out("select * from table1");
ReportDocument[] rd = new ReportDocument[2];
rd[0] = new ReportDocument();
rd[0].Load(Server.MapPath("ResultReport.rpt"));
rd[0].SetDataSource(dt);
dt = new DataTable();
dt = _dal.ExecuteQuery_Out("select * from table2");
rd[1] = new ReportDocument();
rd[1].Load(Server.MapPath("ResultReport.rpt"));
rd[1].SetDataSource(dt);
MemoryStream Parent1 = new MemoryStream();
MemoryStream[] Parentar = new MemoryStream[2];
byte[] parent = new byte[2];
//MemoryStream Mem;
//Mem = (MemoryStream)rd1.ExportToStream(CrystalDecisions.Shared.ExportFormatType.PortableDocFormat);
//byte[] bytearray = Mem.ToArray();
int h = 1;
for (int i = 0; i < rd.Length; i++)
{
Parentar[i] = (MemoryStream)rd[i].ExportToStream(CrystalDecisions.Shared.ExportFormatType.PortableDocFormat);
//Array.Copy(Mem.ToArray(), parent, h);
//h++;
//((byte[])Mem.ToArray()).CopyTo(parent, h);
//h = ((byte[])Mem.ToArray()).Length + 1;
}
long length = 0;
for (int i = 0; i < Parentar.Length; i++)
{
length += Parentar[i].Length;
Parentar[i].Close();
}
Parent1.SetLength(length);
for (int i = 0; i < Parentar.Length; i++)
{
/* your code*/
Parent1.Write(Parentar[i].ToArray())
/* my code*/
byte[] b = Parentar[i].ToArray();
foreach (byte b1 in b)
Parent1.WriteByte(b1);
}
Parent1.Close();
Response.Buffer = true;
Response.ContentType = "application/pdf";
Response.BinaryWrite(Parent1.ToArray());
here i should get both the report documents result in the pdf,
am i correct..
actually simulatenously i was working and i did some codes though here..
but am getting the last things in the out put..am i not dealing with the streams correctly like closing at appropriate place?
even in the debug mode the Parent1 current postiion is increasing while looping the second one..but am not getting
|
|
|
|
|
Concatenating memory streams is available only in .Net version 4. Means there is no option of doing that in previous versions.
you have to implement programming logic to achieve this.
|
|
|
|
|
i Tried with programing though ..
but the problem is i am getting the latest thing which is written and am not getting all?
|
|
|
|
|
Hi, I had set up a pdf maker script using ASPpdf and it had been working fine for several months. Now, when the user trys to create a pdf, they get an Invalid Registration Key error. I looked in regedit for the key as directed in the original instructions and it is there. I don't work with asp.net everyday and haven't done any asp coding in about a year. We had some trouble with the server and our network guys did some work rebuilding. there is a run command showing in the run dropdown that I guess one of the network guys ran. regsvr32 d:\Inetpub\wwwroot\bin\ASPPDFLib.dll
I'm at a loss at what to do.
the line generating the error is below, in C#.
IPdfDocument objDoc = objPdf.CreateDocument( Missing.Value );
Thanks for any help you might provide.
|
|
|
|
|