|
I am using message queues for connectin a Wcf Service and Wcf Client,i am able to implement simplex communication between the service and the client,i want to implement Full Duplex communication between the service and the client using message Queues,Do any one have any code for that ,if yes send me ,it's urgent
Glenn D'souza
Software Engineer
Quest Informatics
|
|
|
|
|
The stuff I have done with MSMQ it seems to make the most sense to use multiple queues for back and forth communcation. So you know which queue is incoming to the service and with queue is incoming to the client. I have some code for that where the service starts up based off an item coming into the queue.
Ben
|
|
|
|
|
Hi Kubben,
I had a problem with MSMQ. want to take input from the client side and perform operation on the server side and give the result back to the client.(C#)
eg.To add 2 numbers
I a writing a service for this in the server using operationcontract and then the client makes a request for this service if suppose the server is down the client request is stored in a queue when the server is on it then process the message and viceversa.....(both ways)
Please give a solution Kubben for this...
Thanks and regards
Glenn
Glenn D'souza
Software Engineer
Quest Informatics
|
|
|
|
|
My use of the MSMQ is for inter- windows service communication and web service to window service communication. Still, the biggest issues will probably have to do with can your client app access your server that the MSMQ exists on. So you need to answer some questions like. Will all the client apps be on your network? If they are then the solution is a lot easier. If they are not, then it is harder.
If you are using a sql server database or any database for that matter, you can do a similar queueing process with some sql tables. I guess you may want to think about how much work you want to do and what the benifit is of using MSMQ. I am pretty sure you are not just trying to add two numbers together.
Ben
|
|
|
|
|
Hi Kubben
Yes all my client applications are on the network.
i have to take input from the client process eg enter two numbers a and b and perform the callculation on the serverside and return back the result to the client .
if suppose the server is down then the client stores the message in a queue which is then retrived by the server and vice versa.
please provide me a sample code for this solution
Thanks
Glenn
Glenn D'souza
Software Engineer
Quest Informatics
|
|
|
|
|
Well, first with the MSMQ stuff I have done the MSMQ is on the server, so if the server is down so would the MSMQ. Now if you are taking about a process that is running on the server is down that is different. You don't want to put the MSMQ on the client since you could have different PCs. I believe there is a way to hook up multiple MSMQ together, but I have not done that.
First you need to set up the MSMQ on your server. If MSMQ is not installed you will need to add it. It is not installed by default. If you go into Add/remove programs then click on add/remove windows components
Select Application Server and then click details. Check the MSMQ check box click ok and then next and go through the wizard till it finishs.
Now that MSMQ is installed you need to create your private queue. I suggest using a namespace of the project. Something like companyname.project.module.inbound What ever server process that will be reading this queue, that user that runs that process needs to have full rights to the queue. So if you are writing a windows service, the user in the login for that windows service needs rights. Right click on the private queue and select security. Add the user and give the user full rights.
Now that your MSMQ is set up you just need to access it.
Let me know when you have the queue set up and then I will give you the code to read and write messages to the queue.
Ben
|
|
|
|
|
hi
am trying to do display the items from database to label.when i click the NEXT button ineed to display the second record to the label .
how its posssible
|
|
|
|
|
Get the items in a datatable. Maintain a counter variable to count the previous and next clicks. According to the counter variable display values from datatable. Keep datatable in one session or cache.
|
|
|
|
|
Suppose you have the required records in a datatable dt, you only need to iterate the row index keeping the column index constant.
The rows index value needs to be stored into a hidden field after each iteration. Below is the C# code for the default.aspx for displaying the records.
<br />
using System;<br />
using System.Data;<br />
using System.Web;<br />
using System.Web.UI;<br />
using System.Web.UI.WebControls;<br />
<br />
public partial class _Default : System.Web.UI.Page <br />
{<br />
Cls_DBtier Cls_DBtierobj = new Cls_DBtier();<br />
int i = 0;<br />
DataTable dt;<br />
protected void Page_Load(object sender, EventArgs e)<br />
{<br />
<br />
Cls_DBtierobj.mvar_DBConnectionstring = Application["Connection_String"].ToString();<br />
Cls_DBtierobj.OpenConnection();<br />
dt = Cls_DBtierobj.getNames();<br />
i = dt.Rows.Count;<br />
Cls_DBtierobj.CloseConnection();<br />
LblNames.Text = dt.Rows[0][0].ToString();<br />
<br />
}<br />
protected void BtnNxt_Click(object sender, EventArgs e)<br />
{<br />
int index = Convert.ToInt32(HidIndex.Value);<br />
if (index < i-1)<br />
{<br />
index = index + 1;<br />
HidIndex.Value = index.ToString();<br />
LblNames.Text = dt.Rows[index][0].ToString();<br />
}<br />
}<br />
}<br />
HidIndex is the hidden field, LblNames is the label for displaying the records. And BtnNxt is the button display the next record.
Cls_DBtier is class file. Below is the code for it.
<br />
using System;<br />
using System.Data;<br />
using System.Data.SqlClient;<br />
using System.Web;<br />
using System.Web.UI;<br />
using System.Web.UI.WebControls;<br />
using System.Web.UI.WebControls.WebParts;<br />
<br />
public class Cls_DBtier<br />
{<br />
public string mvar_DBConnectionstring;<br />
SqlConnection conn;<br />
public void OpenConnection()<br />
{<br />
conn = new SqlConnection(mvar_DBConnectionstring);<br />
}<br />
public void CloseConnection()<br />
{<br />
conn.Close();<br />
}<br />
public SqlCommand ReturnSqlCommand(string sqlStmt)<br />
{<br />
SqlCommand Cmd;<br />
try<br />
{<br />
Cmd = new SqlCommand();<br />
Cmd.Connection = conn;<br />
Cmd.CommandType = CommandType.Text;<br />
Cmd.CommandText = sqlStmt;<br />
return Cmd;<br />
}<br />
finally<br />
{<br />
Cmd = null;<br />
}<br />
}<br />
public DataTable getNames()<br />
{<br />
string stt = "SELECT ename FROM employee";<br />
SqlDataAdapter SAdaptor;<br />
SqlCommand Cmd;<br />
DataSet ds=new DataSet();<br />
DataTable dt;<br />
try<br />
{<br />
Cmd=ReturnSqlCommand(stt);<br />
SAdaptor = new SqlDataAdapter(Cmd);<br />
SAdaptor.Fill(ds);<br />
dt = ds.Tables[0];<br />
return dt;<br />
}<br />
finally<br />
{<br />
stt = null;<br />
SAdaptor = null;<br />
Cmd = null;<br />
ds = null;<br />
dt = null;<br />
}<br />
}<br />
}<br />
|
|
|
|
|
Hi,
Myself Smruti pursuing mca
n facing problem while doing my project the data access from table to dropdown list
can anyone solve my problem by sending me the code
smruti
|
|
|
|
|
Smruti,
Did you populate the required data from the database to a datasource i.e. dataset, datareader, datatable etc...
assuming you used a dataset with the data then you have to give the following code for filling the dropdownlist
dropdownlistid.datasource = datasetname;
dropdownlistid.datatextfiled = datasetname.tables[0].Columns["ColumnName"]
dropdownlistid.datavaluefield = datasetname.tables[0].Columns["ColumnName"]
Doing so the drop down list would be populated with text and respective values.
Gautham
|
|
|
|
|
use this in code behind
I am taking All the districts in a DataSet and binding to a drop down list
DataSet result = null;<br />
<br />
<br />
result = userBll.GetKommunes();<br />
<br />
cbKommune.Items.Clear();<br />
cbKommune.DataSource = result;<br />
cbKommune.DataTextField = "KOMMUNE_NAVN";<br />
cbKommune.DataValueField = "KOMMUNE_NR";<br />
cbKommune.DataBind();<br />
cbKommune.Items.Insert(0,new ListItem(captions.GetString("PleaseSelectKommune"),"0"));
Regards,
Sylvester G
sylvester_g_m@yahoo.com
|
|
|
|
|
Hi,
I'm using a gridview control. It has a checkbox template field with an OnCheckedChanged event. How do I access row number in gridview
inside OnCheckedChanged event of my checkbox?
Thanks!!!
-- modified at 6:55 Wednesday 16th May, 2007
Gerri
|
|
|
|
|
Hi
Are you calling a Javascript method from code behind for the event OnCheckedChangedEvent? So you might have attached the event in run time.. Right ???
Pass ClientID of the field Checkbox as a parameter to the calling method. Then using that parameter you can easily locate a row of GridView
Hope this helps.
Harini
|
|
|
|
|
|
Hi All,
I am using ASP.NET 2.0. I am using iFrame in my project which has 4 parts and one of them contains tree view and others are header, footer and view dynamic pages on tree view node click. All I need to hidden treeview to view my dynamic page in full screen.
Please help me...
Thanks in advance.
|
|
|
|
|
I am new for ASP.NET
I had developed an leave application, for a company.
Now i have to deploy it, so i made a installer with setup wizard, but i dont know how to specify the URL to call the application at the server once installed.
Can any one tell me how to do it? (OR)
Is there any other way to deploy the application(Simple or Complex)
-------------------------------
And what are the requirements at the server to install the application. I had installed .NET framework and IIS 6.0
Is there any thing else and Should i have to configure any thing at the server.
Can any one plese help me with the process.
Plz.... Help
Jats
|
|
|
|
|
Once you install the application via set make sure that you have a web share created for that folder. Once that is done you can use the share name to launch the application
You can very well do an XCopy create a web share and launch the application from that sharename.
|
|
|
|
|
Can you tell me how can i create a web share for it.
I have no idea.
Jats
|
|
|
|
|
Select the folder right click go to sharing and do the required ...
|
|
|
|
|
After installing the application.
How can i call it in my browser(Client browser).
Jats
|
|
|
|
|
Hi Friends,
How to integrate Limelight Server with ASP.NET. Limelight Server is a Server which stores multimedia contents such as Video and Audio files
Can anyone give me suitable link or advice on Limelight Server and its integration with ASP.NET application.
|
|
|
|
|
Hello;
how can I filter filediolog to show only Images for example..
using asp.net
tkml123
|
|
|
|
|
I never find an option to do this in web
|
|
|
|
|
me tooo ,anybody who how to do that,,,
or saw in any website
tkml123
|
|
|
|