I have the config file below.
Is there anyway for the value of MachineName to be populated,
automatically, with the IP address that the application is running on?
So, I would say something like machineName=@IP Address or some such thing...
<?xml version="1.0" encoding="utf-8" ?>
<configuratio n>
<system.runtime .remoting>
<application>
<client>
<wellknown
type="ChatCente r, ChatCenter"
url="http://192.168.1.59:80 80/Chat"
/>
</client>
<channels>
<!-- The "0" port is declared to allow remoting to choose -->
<!-- the most appropriate channel. You must specify a
channel -->
<!-- here, however; if you do not do so, your ChatClient -->
<!-- will not be listening for the call back from the -->
<!-- ChatCoordinator object. -->
<channel
ref="http"
port="0"
machineName="19 2.168.1.172">
<clientProvider s>
<formatter ref="binary"/>
</clientProviders >
<serverProvider s>
<formatter ref="binary" typeFilterLevel ="Full"/>
</serverProviders >
</channel>
</channels>
</application>
</system.runtime. remoting>
</configuration> 1 2283
You can extract the hotname and the IP dynamically so you dont need to add
it to config. http://www.codeproject.com/csharp/Ho...in_Network.asp
--
Regards
John Timney
ASP.NET MVP
Microsoft Regional Director
<ja*****@texeme .com> wrote in message
news:_r******** ************@sp eakeasy.net... I have the config file below.
Is there anyway for the value of MachineName to be populated, automatically, with the IP address that the application is running on?
So, I would say something like machineName=@IP Address or some such thing...
<?xml version="1.0" encoding="utf-8" ?> <configuratio n> <system.runtime .remoting> <application> <client> <wellknown type="ChatCente r, ChatCenter" url="http://192.168.1.59:80 80/Chat" /> </client> <channels> <!-- The "0" port is declared to allow remoting to choose --> <!-- the most appropriate channel. You must specify a channel --> <!-- here, however; if you do not do so, your ChatClient --> <!-- will not be listening for the call back from the --> <!-- ChatCoordinator object. --> <channel ref="http" port="0" machineName="19 2.168.1.172"> <clientProvider s> <formatter ref="binary"/> </clientProviders > <serverProvider s> <formatter ref="binary" typeFilterLevel ="Full"/> </serverProviders > </channel> </channels> </application> </system.runtime. remoting> </configuration> This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics |
by: Billy Jacobs |
last post by:
I am having a problem with my session variable being set
to Null for no apparent reason.
I am declaring it like the following when the user logs in.
dim objUserInfo as new clsUserInfo
'Set some properties
objUserInfo.UserName = txtUserName.text.trim
objUserInfo...
|
by: Paul D.Smith |
last post by:
Can Python create a variable "on-the-fly". For example I would like
something like...
make_variable('OSCAR', 'the grouch');
print OSCAR;
....to output...
the grouch
|
by: Not Available |
last post by:
On the host server:
namespace JCart.Common
public class JCartConfiguration : IConfigurationSectionHandler
private static String dbConnectionString;
public static String ConnectionString
{
get
{
return dbConnectionString;
|
by: Mike L |
last post by:
This is for a Win form.
Currently I have several connection strings that are identical through out
my application. Is a global variable the best choice for this situation? If
so, what is the code to make a global string variable, and where do I put it,
(before the namespace, of just under it)?????
|
by: Greg Collins [MVP] |
last post by:
Hi, I couldn't find what I was looking for by searching the newsgroup, but perhaps these have already been discussed somewhere. This is a bit long with a lot of interrelated questions.
What I've got is a decodeImage.aspx page that gets called to decode base64 encoded images and return them as displayable images to a Web page. The ASPX page is passed two parameters, "file" and "img". The "file" parameter specifies and XML file on the Web...
| |
by: Miguel Dias Moura |
last post by:
Hello,
I am working on an ASP.NET / VB page and I created a variable "query":
Sub Page_Load(sender As Object, e As System.EventArgs)
Dim query as String = String.Empty
...
query = String.Format("SELECT * FROM dbo.documents WHERE ") & query
End Sub
|
by: simon |
last post by:
hello,
what i'm looking to do is store the path of the app on a the server
for reuse in the site.
my thoughts so far are...
-make a key in the web.config file
-retrieve the value in globals.asax in application startup
-store it in a variable that can be reference from all pages
-use that variable on many pages
my questions
1) what is the syntax of the lines in global.asax page to put this
|
by: Brad Pears |
last post by:
We have several applications that use the ".exe.config" .xml file to get
the connection string to our SQL server db. Each user of the application has
their own .xml file because we have some user specific settings in there...
My question is this... We are looking at setting up a backup SQL server. I
would like to modify the .xml config files so that they read the connection
string from a network share instead. That way, we can easily...
|
by: Chris Allen |
last post by:
Hello fellow pythoneers. I'm stumped on something, and I was hoping
maybe someone in here would have an elegant solution to my problem.
This is the first time I've played around with packages, so I'm
probably misunderstanding something here...
Here's what I'd like to do in my package. I want my package to use a
configuration file, and what I'd like is for the config file to appear
magically in each module so I can just grab values from...
|
by: Connolly |
last post by:
Hey there, new Python user here.
Currently, I'm working on a project in Python for my college work, I chose
to use Python since I heard of its great advantages, now for designing GUI's
I'm using the wxPython package.
What I'm trying to do at the moment is the following;
A file directory browser is created using self.dialong.ShowModal, when the
user chooses the folder they want to use for this program, then
self.dialong.GetPath is...
|
by: Oralloy |
last post by:
Hello folks,
I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>".
The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed.
This is as boiled down as I can make it.
Here is my compilation command:
g++-12 -std=c++20 -Wnarrowing bit_field.cpp
Here is the code in...
| |
by: jinu1996 |
last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth.
The Art of Business Website Design
Your website is...
|
by: Hystou |
last post by:
Overview:
Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
|
by: tracyyun |
last post by:
Dear forum friends,
With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
|
by: agi2029 |
last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own....
Now, this would greatly impact the work of software developers. The idea...
|
by: isladogs |
last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM).
In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules.
He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms.
Adolph will...
|
by: TSSRALBI |
last post by:
Hello
I'm a network technician in training and I need your help.
I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs.
The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols.
I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
| |
by: adsilva |
last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
|
by: muto222 |
last post by:
How can i add a mobile payment intergratation into php mysql website.
| |