|
I tried same way as u said even with your code and I created a new project as well. It is really strange. I am using following statement. It works perfectly in IE6 and IE7 as well but unfortunately not in Firefox which I really need. Also tell me how can I get value from that specific xml tag but this is next step.
function processRequest()
{
if (req.readyState == 4)
{
if (req.status == 200)
{
var message = req.responseXML; //Result in XML.
alert(message.xml);
}
}
}
|
|
|
|
|
OH, Brother It is working now in Firefox as well. This is great. Let me have some more tests tomorrow with my webservice then I will post final in the forum. Meanwhile If I have poblem I will come to you again please don't mind. In the end, I just want to say U a lot of THANKS for your time and nice replys. You don't know how much you help me. GOD ALWAYS BLESS U and KEEP U HAPPY.
See U Tomorrow then, Have a nice Evening.
Bye
Abubakar
|
|
|
|
|
Sorry Brother I got little bit more excited. I am having this error message when I tried to use my code.
"Problem:Internal Server Error"
Do u know what could be reason? My webservice exists at following address and I am calling this from the same location. Here is code.
<input type="button" value="Call .NET Web Service!" onclick="CallWebService('http://192.114.169.164/customers/nl/Hotmale/PPMService.asmx/testWebService','testVar=SUCCESS')" />
Any Idea? Please suggest.
Thanks.
Abubakar
|
|
|
|
|
Abubakarsb wrote: http://192.114.169.164/customers/nl/Hotmale/PPMService.asmx/testWebService','testVar=SUCCESS')"
The HTML file (or aspx) and Webservice are in same domain?? I mean, if your web service is in http://192.114.169.164 then the HTML or aspx which invoke the webservice should be in http://192.114.169.164 too.. Thats mean you should be able to access like http://192.114.169.164/customers/nl/Hotmale/PPMService.asmx/testWebService and http://192.114.169.164/myAjaxPage.aspx.
Because it is not allowed to invode the Cross-sites by using XMLHttpRequest object..
(I have a problem in explaining things to other people. I don't know how to say/write clearly. )
So, put the test file in same place where your web service is stored and try to test againn...
btw, Have you tested your web service thought "web reference" dialog (as I mentioned in last thread)? I hope your webservice is working fine.
Good Luck.
Thanks and Regards,
Michael Sync ( Blog: http://michaelsync.net)
If you want to thank me for my help, please vote my message by clicking one of numbers beside "Rate this message". Why vote? Plz Read it here. Thank you.
|
|
|
|
|
Friend,
I put the project online. I put the same code in it which you sent me. You can also check urself, it is not returning right status. It is behaving dramatically different in IE and Firefox. In IE it is returning status value 500 while 411 in Firefox. I request you to check it in both IE and Firefox. In following file I am calling websevice by name only without full URL as both files (Webservice and .aspx file) exist in same folder.
http://192.114.169.164/Customers/NL/testWebservice/Default.aspx[^]
And in the following page I am calling webservice through full URL path with IP etc.
http://192.114.169.164/Customers/NL/testWebservice/testWebService.aspx[^]
One thing more both these files work perfectly on local computer but not on internet. Please check both links and tell me where I am doing wrong. Plz.
|
|
|
|
|
I have checked your webservice file.
http://192.114.169.164/Customers/NL/testWebservice/WebService.asmx
Your web service file is not working properly. It is giving me the errors. So, I suggest you to check your web service to make error clean.
When we are accessing the webservice url, it should give the list of functions available in that service... now, your webservice file is returning the error.... so, Please fix this webservice file first..
Thanks and Regards,
Michael Sync ( Blog: http://michaelsync.net)
If you want to thank me for my help, please vote my message by clicking one of numbers beside "Rate this message". Why vote? Plz Read it here. Thank you.
|
|
|
|
|
Hi,
I used a new webservice now
http://192.114.169.164/customers/nl/Hotmale/PPMService.asmx[^]
and this is working really good in all the browsers. Today at night I will implement my real code and I hope it will work there as well. If not I will bother u again (Don't mind). If it works I will post its soution in the forums as well. Thanks a lot for your consistent help. GOD BLESS U.
Bye
|
|
|
|
|
I'm glad to hear that your problem is solved.
If my post is helpful for you, don't forget to vote it. Thanks.
Abubakarsb wrote: If not I will bother u again (Don't mind).
Yeah. sure. We all here are trying to help as much as we can..
All the best!!
Thanks and Regards,
Michael Sync ( Blog: http://michaelsync.net)
If you want to thank me for my help, please vote my message by clicking one of numbers beside "Rate this message". Why vote? Plz Read it here. Thank you.
|
|
|
|
|
seem like someone hate me about this post... cuz i got vote 1...
Thanks and Regards,
Michael Sync ( Blog: http://michaelsync.net)
If you want to thank me for my help, please vote my message by clicking one of numbers beside "Rate this message". Why vote? Plz Read it here. Thank you.
|
|
|
|
|
Thanks for code. So far It is great there in no javascript error in IE6 and Firefox as well. Only thing which I am missing is that I couln't find any code to receive value from webservice and use here in Javascript.
Please tell me how can I catch value returned by webservice? I also tried this but in vain.
function processRequest() {
if (req.readyState == 4) {
if (req.status == 200) {
var message = req.responseXML; //Result in XML.
alert(message);
}
}
}
|
|
|
|
|
My project is not so big, I just need to call some webservices and return their data to javascript. That's all. I think it could be best solution which we are trying because It is almost done.
|
|
|
|
|
Hi all...
I have the expression in RegularExpressionValidator using the
ValidationExpression="\w+([-+.]\w+)*@\w+([-.]\w+)*\.\w+([-.]\w+)*"
checking the email. I have a java script which adds enter text... if the user has entered nothing in the text box. But when i submit the form the regular expression validator comes into action and tells the user that
"enter text..." is invalid as given.
Can anyone tell me a way to modify the above validation expression so as it will accept a valid email or the string "enter text...".
Please Note this is a requirement and this requirement cannot be modified.
Waiting in anticipation.
Bye
|
|
|
|
|
U have to use javascript for both valid email or the string "enter text...".
Check If Text is "enter text..." return true else validate email
Best Regard
Pathan
---------------------------------------------------
|
|
|
|
|
hi friends ihave project in c#.net but one of my clss is in vb (Vb.net)
i am trying to acess function of that class but i am not getting object of vb.net class in my c#project pls help me
thanks in advance
|
|
|
|
|
But add that VB.NET Class to VB.NET project (Class Library Template). then, reference it from C# project.. then, it will okay to access that function of VB.NET class from C#.
Thanks and Regards,
Michael Sync ( Blog: http://michaelsync.net)
If you want to thank me for my help, please vote my message by clicking one of numbers beside "Rate this message". Why vote? Plz Read it here. Thank you.
|
|
|
|
|
i was trying to add the vb classs file in the c# project.after clicking the add new item, i am given only c# files to add.y it is so?
Sonia Gupta
Soniagupta1@yahoo.co.in
Yahoo messengerId-soniagupta1
Love is Friendship and Friendship is Love....
|
|
|
|
|
Sonia Gupta wrote: i was trying to add the vb classs file in the c# project.
You should NOT add VB Class to C# Project.
Instead, you should create new class project by using VB.NET Class Library Template. (HOWTO: Open "File\New Project". Choose "VB". Select "Class Library")
And add your VB class to this VB.NET Class Library project.
Then, right-click on Solution File in Solution Explorer. Add the existing C# project.
Then, Add reference VB project from C# project..
then, you can call like ClassLibrary1.VBClass.Foo();
Thanks and Regards,
Michael Sync ( Blog: http://michaelsync.net)
If you want to thank me for my help, please vote my message by clicking one of numbers beside "Rate this message". Why vote? Plz Read it here. Thank you.
|
|
|
|
|
You can add .vb class in C# project.
To access that classes u have to
Add all .vb classes in "VB" folder in App_code and code in web.config file
<compilation debug="true">
<codeSubDirectories>
<add directoryName="VB"/>
</codeSubDirectories>
...............
..............
U can access.vb classes from .cs class
Best Regard
Pathan
---------------------------------------------------
|
|
|
|
|
I was thinking of implementing the cashing concepts in a program.Now the point where i got stuck is that operating System has it's feature to cashe the page (When i open the page (the page which has already been opened)) and we do the cashing programically as well .If the operating system can do the cashing , then what's the need to do cashing programatically.
Sonia Gupta
Soniagupta1@yahoo.co.in
Yahoo messengerId-soniagupta1
Love is Friendship and Friendship is Love....
|
|
|
|
|
Its not Cashing it is caching.
Pronounced cash, a special high-speed storage mechanism. It can be either a reserved section of main memory or an independent high-speed storage device. Two types of caching are commonly used in personal computers: memory caching and disk caching.
A memory cache, sometimes called a cache store or RAM cache, is a portion of memory made of high-speed static RAM (SRAM) instead of the slower and cheaper dynamic RAM (DRAM) used for main memory. Memory caching is effective because most programs access the same data or instructions over and over. By keeping as much of this information as possible in SRAM, the computer avoids accessing the slower DRAM.
Caching
SSK.
|
|
|
|
|
Operating system can cache the complete page.But that is not why caching used for.Caching can be used to store values of an object or complete objects.
ex.you can store a list<customer> in a cache. i.e all the objects stored in the list can be stored in the cache.
after doing operation on the List<customer> you can again store that list in the cache.
satyaki mishra
|
|
|
|
|
Hi,
how to bind image present in sql server to image tool.
Chaitra N
|
|
|
|
|
take the binary of the image from database.
make a stream.
write that stream into a blank Web User Control. as Response.Write
and then assign it to your image control as
ImageURL="myPic.ascx"
I hope you understand what I mean.
Regards,
Ather Ali
Ather Ali Shaikh
Project Manager
Micromedia Computer
shaikhather@gmail.com
|
|
|
|
|
Hi Ather Ali,
I understood what you are telling but not getting how to do it. I have the following code. Picture is getting displayed. It is ok. But not in the image control. suppose if I have a imagecontrol Image1 how can i do this?
Dim ImageID As Integer = Convert.ToInt32(Request.QueryString("ImageID"))
'Connect to the database and bring back the image contents & MIME type for the specified picture
Const SQL As String = "SELECT [MIMEType], [Image] FROM [Pictures] WHERE [ImageID] = @ImageID"
Dim myCommand As New SqlCommand(SQL, myconnection)
myCommand.Parameters.AddWithValue("@ImageID", 1)
myconnection.Open()
Dim myReader As SqlDataReader = myCommand.ExecuteReader
If myReader.Read Then
Response.ContentType = myReader("MIMEType").ToString()
Response.BinaryWrite(myReader("Image"))
End If
myReader.Close()
myconnection.Close()
Chaitra N
|
|
|
|
|
This Code is OK.
Put this code in a ASCX control and take the ImageID from QueryString. and there should not be any thing in HTML side.
Whereever you want to put this image on any page.
place a image control on that page and as source refere to this control
like <asp:image id="myimage" runat="server" imageurl="~/Controls/MyImage.ascx?ImageID=" <%#="" myimageid="" %="">
I hope it will sove your problem.
I have already did it in my one of the application.
Regards,
Ather Ali
Ather Ali Shaikh
Project Manager
Micromedia Computer
shaikhather@gmail.com
|
|
|
|