|
|
Thank you.
will surely look into that.
Thanks
|
|
|
|
|
hi,
I have made a composite control in asp.net 2.0
i have a textbox in that composite control.
when i use that composite control in the page. i need to put a javascript where i can get the 'value' of the textbox, but i am getting undefined in javascript
pleas help
thanks
deepak
|
|
|
|
|
Because the textbox is inside of a container control you need to reference it with the name of that control also. If you look at the rendered output of your page you should see the textbox with an ID something like UserControl1_MyTextbox.
only two letters away from being an asset
|
|
|
|
|
My apologies for very very basic question. I am going through with SOAP messaging and found
“Nor SOAP is tied to any particular operating system or programming language so theoretically the clients and servers in these dialogues can be running on any platform and written in any language as long as they can formulate and understand SOAP messages”
How internally it make difference? I mean SOAP is nothing except massaged XML with SOAP headers, envelope and body. I really interesting to find difference between SOAP message and plain XML message without SOAP..
Amit
|
|
|
|
|
http://www.w3schools.com/soap/default.asp[^]
The difference is the standard defines what each tag means (Envelope, Header, etc) and what it should contain. Plain XML could do the same but it would be up to each sender and receiver to agree upon the format and meaning.
only two letters away from being an asset
|
|
|
|
|
Thanks for your reply. I need other help from your side. Thanks in advance for your inputs.
I have two probelems
a) I am getting error "The remote server returned an error: (500) Internal Server Error." whenever i tried to call web service.
b) I need to pass my web method name as runtime paramter. As web service can contain multiple web methods.....I am trying to pass as SOAPACTION but i am not sure syntax or infact is it correct way or not....
FYR i am sharing source code as below
Client Code:
'Create a new HttpWebRequest to the mentioned URL.
'hard code for time being
httpRequest = WebRequest.Create("http://localhost/XYZWS/XYZCustomerService/XYZCustomerService.asmx")
' Set Request information (Header, ContentLength, ContentType, etc)
'hard code for time being. Passing sxml here.
Dim bodyData As Byte() = Encoding.UTF8.GetBytes(sXML)
httpRequest.ContentLength = bodyData.Length
httpRequest.ContentType = "text/xml; charset=utf-8"
'hard code for time being in future it will be thru parameter
httpRequest.Headers.Add("SOAPAction", "SaveCustomerService")
httpRequest.Method = "POST"
' Set 'Preauthenticate' property to true. Credentials will be sent with 'the request.
httpRequest.PreAuthenticate = True
' Create a New 'NetworkCredential' object.
Dim networkCredentials As NetworkCredential = New NetworkCredential("A", "b")
' Associate the 'NetworkCredential' object with the 'HttpWebRequest' object.
httpRequest.Credentials = networkCredentials
' Create a new RequestStream to POST info (Synchronous call)
requestStream = httpRequest.GetRequestStream()
requestWriter = New StreamWriter(requestStream)
'Write Soap message into RequestStream
requestWriter.Write(sXML)
' Cleanup
requestWriter.Close()
requestStream.Close()
' Create a new HttpWebResponse (Synchronous call)
'HttpWebResponse response = httpRequest . GetResponse ( ) as HttpWebResponse
'Dim httpResponse As System.net.HttpWebResponse
'httpResponse = httpRequest.GetResponse()
Dim httpResponse As HttpWebResponse
httpResponse = CType(httpRequest.GetResponse(), HttpWebResponse)
' Extract normal SOAP response.
responseStream = httpResponse.GetResponseStream()
responseReader = New StreamReader(responseStream)
'Fetch the XML.
Dim httpResult As String = responseReader.ReadToEnd()
' Cleanup
responseReader.Close()
responseStream.Close()
' Return XML.
'Return httpResult
Catch myerr As WebException
' Populate the table with the exception details.
ErrorTable.Rows.Add(BuildNewRow("Source", myerr.Source))
ErrorTable.Rows.Add(BuildNewRow("Error Message", myerr.Message))
ErrorTable.Rows.Add(BuildNewRow("Status", myerr.Status))
'ErrorTable.Rows.Add(BuildNewRow("Response", myerr.Response))
ErrorTable.Rows.Add(BuildNewRow("Detail", myerr.StackTrace))
Return
Catch myerr As SoapException
' Populate the table with the exception details.
ErrorTable.Rows.Add(BuildNewRow("Fault Code Namespace", myerr.Code.Namespace))
ErrorTable.Rows.Add(BuildNewRow("Fault Code Name", myerr.Code.Name))
ErrorTable.Rows.Add(BuildNewRow("SOAP Actor that threw Exception", myerr.Actor))
ErrorTable.Rows.Add(BuildNewRow("Error Message", myerr.Message))
ErrorTable.Rows.Add(BuildNewRow("Detail", HttpUtility.HtmlEncode(myerr.Detail.OuterXml)))
Return
End Try
</code>
Now here is web service code and GetXMlValue is custom function to read xml node value
<WebMethod(MessageName:="SaveCustomerService")> _
Public Function SaveCustomerService(ByVal CustomerService As String) As String
Try
Dim sUserName, sEmail, sCategory, sSubject, sMessage As String
sUserName = GetXmlValue(CustomerService, "username")
sEmail = GetXmlValue(CustomerService, "email")
sCategory = GetXmlValue(CustomerService, "category")
sSubject = GetXmlValue(CustomerService, "subject")
sMessage = GetXmlValue(CustomerService, "message")
SaveCustomerService(sUserName, sEmail, sCategory, sSubject, sMessage)
Catch ex As Exception
Dim a As New ThrowSoapException
a.myThrow()
End Try
FYI
For probelm one i added below line of code in web.config of web service also
<webServices>
<protocols>
<add name="HttpPost" />
</protocols>
</webServices>
Thanks in advance....
Amit
|
|
|
|
|
|
Thanks for your reply. But because of certain design pattern we are developing adaptors and we need to create request on fly. Web service url, method name all will be avaibale on runtime.....
Please suggest.
Thanks
Amit
Amit
|
|
|
|
|
SOAP Message uses specific namespace which make it different. If you create an xml document with same format like enevelope and message without namespace, it will be considered as an xml doc rather than SOAP.
Neeraj
|
|
|
|
|
how can we efficinetly program for memory management,
can any one provide article and code sample (easy and descriptive) links
Thanks,
harsh
|
|
|
|
|
Far more , Instance of the ojects can be blamed for taking lots of memory,
use Singleton design pattern where ever possible , if you really dont want to use losts of dispose of the obejcts
|
|
|
|
|
Hi Developers
I have been using VS 2003 from 1 year, now thinking to switch to VS 2005. Wud u please send me some references, from where can learn VS 2005 in a proper way.
Thanks in advance
Lets work it Out.........!
|
|
|
|
|
|
Is there a way to retrive Outlook Calenders using ASP.NET 2.0 for IntrAnet applications?
Are there any classes that allows you to query outlook / exchange database?
Thanks in advance.
|
|
|
|
|
Sir,
Can u please tell me what is View State of TextBox.
Thanks
|
|
|
|
|
Please explain ur question so that any one can answer
Lets work it Out.........!
|
|
|
|
|
I was asked in the interview that what's the view state of textbox.
|
|
|
|
|
Sounds like you need to work through a book or two before your next interview
Christian Graus - Microsoft MVP - C++
Metal Musings - Rex and my new metal blog
|
|
|
|
|
After postback when the textbox retains its property or state :- this is call viewstate
|
|
|
|
|
|
I just download the Express Editions and found myself loving the new framework. There are somethings that I am still a little foggy about and hopefully someone can help.
1. When you are setting up users/roles.... is there a way to import that kind of information into another DB. The reason I am asking is because I already have a Members tables set up with most of the same data. I would like to take some of the fields from my Members table and some of fields from the default table and combine them. Anyone run into this issue. I know my connetion string in the web.config is set to the DB with my Members tables in it. My biggest reason why I have to do this is because my host company only allows one sql Db per accounts (stupid).
2. WHen you are using the createnewsuerWizard. Is it possible to change it so you don't have to have special characters as a password. I know this is great for security but like I said early I already have a ton of records in my Members tables and don't want to make everyone reregister.
|
|
|
|
|
1. As you know that the built-in providers like Membership ... use their own schemas, and you can install these tables into your current DB. However, the better option is that you can develop your custom provider to target your own table schema. The link[^] can get you started.
2. With the CreateUserWizard control, you can use the PasswordRegularExpression property to set a regular expression for validating the password. In addition, you may also use the
passwordStrengthRegularExpression<br /> attribute when you config the membership settings in the web.config file.
|
|
|
|
|
Hello guys,
I have a particular scenario to display hierarchial information in grid. Consider the following table structure and the sample data.
Table structure
----------------
ObjectId - Primarykey
Parentid
description
Sample data
objectid parentid description
-------- -------- -----------
1 null Parent 1
2 1 child for p1
3 1 child for p1
4 null Parent 2
5 4 child for p4
6 5 child for c5
7 6 child for c6
So, from the above data, objects 1 and 4 have parentid as null. So, they are the base parent objects to be displayed in the grid. Objects 2,3 are child for parent object 1. So object 2 and 3 should be nested within object 2. Similarly object 5 should be nested within parent object 4. Object 6 has the parentid as 5. So it should be nested within the child object 5. Also object 7 should be within object 6. So the nesting can be n levels and all this nesting should be visible inside the grid. The grid row holding the parent object should have a + sign and on click of that + sign, the immediate child objects should be visible, using javascript.
The grid should appear like this
objectid description
+ 1 parent 1
objectid description
2 child for p1
3 child for p1
+ 4 parent 2
+ objectid description
5 child for p4
+ objectid description
6 child for c5
+ objectid description
7 child for c6
Please provide a solution. I am working with asp.net 2005,c# and oracle 10g.
Please help me ... its very urgent...
|
|
|
|
|
You can do it in TreeView control with the same look and with proper js.
You can also do it in datagrid but will have some limitations.
Let me know so accordingly I can give you the code.
"Walking on water and developing Software on a specification is easy, if
both are frozen..."
|
|
|
|