|
I have two textboxes and want this comparevalidator to do a case insensitive comparision.... is there any workaround?
Thanks in advance
|
|
|
|
|
|
while opening below mentioned web link it says that i am not authorized to view this page. could you please copy paste the contents of this page if possible?
thanks a lot
|
|
|
|
|
|
Ok i was able to open that link but its not what i am looking for. That link only shows the working of compare method. i am looking for comparevalidator control to do case-insensitive comparison.
|
|
|
|
|
http://www.nedcomp.nl/support/origdocs/dotnetsdk/cpref/frlrfsystemstringclasscomparetopic5.htm
copy that link and paste into browsers address bar.
|
|
|
|
|
Hello,
I have a Web.sitemap file. I created a SiteMapDataSource.
Every node on my Web.Sitemap have a property named Visible which is set to true or false.
I need my SiteMapDataSource to get only the nodes from Web.Sitemap which has the property Visible="True".
How can I do this?
Thanks,
Miguel
|
|
|
|
|
You could turn on SecurityTrimming so that you can set which roles can see which items in the Sitemap, then set the ones you want invisible to a non existant role.
|
|
|
|
|
Is not any other solution?
Web.sitemap is basically a XML file.
I supose I could go through each item on the SiteMapDataSource ...
Is is just that roles for this doesnt seem the best way to solve this.
Thanks,
Miguel
|
|
|
|
|
Instead of having a sitemap with Visible property
it's easier to have 2 sitemaps:
1. with visible nodes only
2. with all the nodes
This will allow you to bind the menu control to the visible sitemap
and to get other nodes from the other sitemap
you can configure the names of the 2 sitemap providers in web.config
see this msdn article to know how:
http://msdn2.microsoft.com/en-us/library/ms178426.aspx[^]
The first 90% of the code accounts for the first 90% of the development time. The remaining 10% of the code accounts for the other 90% of the development time.
|
|
|
|
|
Hi,
Are you talking about dependent site maps?
I will explain my problem:
My web site uses two different web site maps:
1. The full one which is used in the menu.
2. The most restricted one which is a part of (1) and that is used in footer links.
3. In both cases I need to have everything in two cultures: English and Portuguese.
Could you give me your opinion of how to create this?
Thanks,
Miguel
|
|
|
|
|
I'm not sure if you can create resource files for sitemaps to localize them.
I had a similar problem before and I had to create a different copy of sitemap for each language.
In your case you will need 4 sitemaps (2 for each langauge) and have some code to decide which sitemap that will be used according to the current culture.
The first 90% of the code accounts for the first 90% of the development time. The remaining 10% of the code accounts for the other 90% of the development time.
|
|
|
|
|
After searching the MSDN I found that you can have resouce files for sitemaps to localize them.
check this page:
http://msdn2.microsoft.com/en-us/library/ms178427.aspx[^]
The first 90% of the code accounts for the first 90% of the development time. The remaining 10% of the code accounts for the other 90% of the development time.
|
|
|
|
|
hi i am creating a asp.net form which includes on text fileld for customer id which is to be auto generated. i got a for auto generation code for customer id, but it is written in vb.net.I want the same code to be written in c#.Can any help to write the code in c#. I have tried to write the same code in c# but it is throwing an error.
I am posting the vb.net code for auto generation.Can any one convert the followin code for me in c#.please it is urgent as i required in my project.
Private Sub btnadd_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnadd.Click
' Following is the code for auto generating the costomer id
Dim ctr As Integer
Dim len As Integer
Dim custid As String
Dim custidval As String
dt = Dscust1.Tables("customertracking")
len = (dt.Rows.Count - 1)
dr = dt.Rows(len)
custid = dr("custid")
custidval = Mid(custid, 2, 3)
ctr = CInt(custidval)
If ctr >= 1 And ctr < 9 Then
ctr = ctr + 1
txtcustid.Text = "c00" & ctr
ElseIf ctr >= 9 And ctr < 99 Then
ctr = ctr + 1
txtcustid.Text = "c0" & ctr
ElseIf ctr >= 99 Then
ctr = ctr + 1
txtcustid.Text = "c" & ctr
End If
txtcustid.Enabled = False
End Sub
Pranav Dave
|
|
|
|
|
if customer id is an integer value then why would you want it to create like this.
database can create you an id and have it increased by 1 for each data insertion.
why dont you let the database take care of this
|
|
|
|
|
The following was produced with our Instant C# VB to C# converter:
//TODO: INSTANT C# TODO TASK: Insert the following converted event handlers at the end of the 'InitializeComponent' method for forms or into a constructor for other classes:
btnadd.Click += new System.EventHandler(btnadd_Click);
private void btnadd_Click(object sender, System.EventArgs e)
{
// Following is the code for auto generating the costomer id
int ctr = 0;
int len = 0;
string custid = null;
string custidval = null;
dt = Dscust1.Tables["customertracking"];
len = (dt.Rows.Count - 1);
dr = dt.Rows[len];
custid = dr("custid");
custidval = custid.Substring(1, 3);
ctr = System.Convert.ToInt32(custidval);
if (ctr >= 1 & ctr < 9)
{
ctr = ctr + 1;
txtcustid.Text = "c00" + ctr;
}
else if (ctr >= 9 & ctr < 99)
{
ctr = ctr + 1;
txtcustid.Text = "c0" + ctr;
}
else if (ctr >= 99)
{
ctr = ctr + 1;
txtcustid.Text = "c" + ctr;
}
txtcustid.Enabled = false;
}
David Anton
www.tangiblesoftwaresolutions.com
Instant C#: VB to C# converter
Instant VB: C# to VB converter
Instant C++: C# to C++ converter, VB to C++ converter
Instant Python: VB to Python converter
|
|
|
|
|
hi,
I have a user control for registration of user. Now i need to submit the fields with ajax method in database. When insertion is completed successfully,
need to load other control by a javascript function in the same page with success message.
for e.g.
page1.ascx
function insert()
{
var message = insertdata(); // insertdata is an ajax method.
//load other control on this page with above message displaying on that control with some label control or literal control
}
any help is appreciated,
regards,
max
|
|
|
|
|
System.IO.Ports is not available in asp.net vb.net 1.1 ? if not is there any other that works like that?
|
|
|
|
|
Hello everyone:
Would you be able to give me some practical examples as to where I would need to implement Singleton classes?
For e.g. if you could point out the scenarios where I must or should implement a Singleton class etc. I sure would appreciate your help. Thanks in advance.
Regards,
Robert
|
|
|
|
|
Singelton classes are used when you wan't to have only one instance of a class.
--------------------------------------------------------
My portfolio & development blog
Q:What does the derived class in C# tell to it's parent?
A:All your base are belong to us!
|
|
|
|
|
Dear CWIZO:
Thanks a lot for your reply; I understand the concept of Singleton classes but for some reason I am unable to identify the scenario where I would need just one instance of a class.
In other words 'why' would I need to have just one instance of a class? A practical (real world) example will be highly appreciated . Thanks again.
Regards,
Robert
|
|
|
|
|
Well once could be a class for logging application errors. Since you don't wan't two clases write to the same file at once you make a singelton class.
--------------------------------------------------------
My portfolio & development blog
Q:What does the derived class in C# tell to it's parent?
A:All your base are belong to us!
|
|
|
|
|
Maybe I'm way off base here, but wouldn't you either want multiple instances of this class so different threads don't change property data behind one another? Or maybe a static class so threads that need to log just call methods and pass the relevant data?
|
|
|
|
|
Hi
The website i am working on uses smartnav and has done without a problem for a while. However i recently had troubles with it not letting me debug so got a fresh copy from source safe (into the same directory structure as before) now when i try to add my web reference i get:
There was an error downloading 'http://127.0.0.1/aspnet_client/system_web/1_1_4322/SmartNav.htm'.
The request failed with HTTP status 404: Object Not Found.
I understand why this is happening (smartnav.htm is not in this destination - it is infact in wwwroot - then the above directory structure).
My question is does any one know why my project is looking in the wrong directory or is it the right directory and smartnav actually is not where it should be - if so any chance of a shove in the right direction.
Any help would be much appreciated.
Cheers
Dan.
|
|
|
|
|
I developed a web service on my local workstation in ASP.NET that inserts data into an accounting package (Visual Studio 2005). It uses an API provided by the vendor. I installed the accounting software on my machine and was able to successfully build the web service. Creating the reference to the Accounting software did create 2 interop references.
Now comes the problem
I have to deploy this to a production machine. The accounting software is deployed on this machine as well, but the person that installed it deployed it using a UNC name instead of installing it to a fixed location (ie its installed to \\Fileserver\ACCPAC instead of c:\ACCPAC) - because this app will be shared by multiple users.
My webservice deploys OK, but cannot find and initialize the class it needs to do the work. I keep getting the following error:
*********
Class not registered (Exception from HRESULT: 0x80040154 (REGDB_E_CLASSNOTREG))
StackTrace: at AccpacCOMAPI.AccpacSessionClass.Init(String ObjectHandle, String AppID, String ProgramName, String AppVersion)
*************
I have picked the process apart and the only thing I find different is that the DLLs are registered differently, mine to C:\ACCPAC, and the production servers to \\Filerserver\ACCPAC
Has anyone run into this problem. I am stumped and out of ideas....
Thanks in advance for any assistance
|
|
|
|