Start Index Cannot Be Less Than Zero?
Feb 9, 2011
i am getting "start index cannot be less than zero".
email = email.Remove(email.IndexOf(EmployeeDataset.Tables[0].Rows[i][
"EmailId"].ToString()),
Convert.ToInt32(EmployeeDataset.Tables[0].Rows[i]["EmailId"
].ToString().Length + 1));
in this line i am getting error.
View 3 Replies
Similar Messages:
Oct 28, 2010
What is the right approach when users (authenticated domain admins) should be able to start batch jobs (usually exe files) from an IIS (7.x) aspx (c#) page? This is an intranet site. The batch jobs have to run on the web server as Domain Admins. The website pool is executed by network service or some similar restricted account in AD.
Approaches I can think of (and their disadvantages):
1. Start exe file with System.Diagnostics.Process.Start with another account. This feature is disabled in IIS 7.x, how do I allow it?
2. Create a sheduled task and call scheduled task-api. This unmanaged dll is giving VS compiler warnings because it's unsafe to call from managed code.
3. I suppose there's a better approach, because the previous suggestions doesn't appear safe or robust.
View 2 Replies
Jan 26, 2011
I am trying to register the route collection in .net based on each session. The code I have works fine, you goto website/username and it loads the correct sub pages, but you have to restart the application to goto website/username2 to load those sub pages. But when the application is restarted the second one works, but then not the first one. Is there some way to create a different route collection per session not per application using system.web.routing.
View 3 Replies
Jun 8, 2010
I would like to start a System.Threading.Timer in my application when it launches (maybe deploy is the correct word). I have seen that you can use Application_Start() but this is only fired once the first request comes to the application. I need the timer to start as soon as the application is running so that it can check for work to process even if a user is not interacting with the site. How can I get the application to start the timer once it is up and running?
View 4 Replies
May 14, 2010
I'm working on a project where we're using Windows Desktop Search (WDS) to index files on a web share and then later allow the user to search via a website for documents in the share.
These documents are transferred to the share via FTP, however it would seem that either the computer never goes idle to index or at some point the indexing stops. Is there a way from the command line or within the program itself to force this to happen without having to re-invent the wheel? Using .NET 3.5 and C#.
View 1 Replies
Jan 11, 2011
I am running Visual Studio 2010 (as Admin), IIS 7 on Windows 7 x64. I am able to run the ASP.NET web site in IIS 7 without debugging just fine, but when I press F5 to debug it, I get: Unable to start debugging on the web server. Could not start ASP.NET debugging. More information may be available by starting the project without debugging. Unfortunately the help link is not helping me much and leads down a heck of a large tree of things. I checked the following:
Security requirements — I don't recall having to do anything special before. The worker process in IIS7 is w3wp.exe. It says that if it's running as ASPNET or NETWORK SERVICE I must have Administrator privileges to debug it. How do I find out if I need to change something here? Web site Property Pages > Start Options > Debuggers > ASP.NET is checked. Use custom server is set to the URL of the site (which works fine without debugging). Debugging is enabled in web.config. Application is using ASP.NET 3.5 (I want to move to 4.0 eventually but I have some migration to deal with). Application pool: Classing .NET AppPool (also tried DefaultAppPool). Surely it shouldn't be that hard to install IIS, VS, create a web site, and start testing it?
View 2 Replies
Feb 25, 2011
In our ASP.NET application we perform some initializations upon the Application Start event.When the application is started in visual Studio 2010 with 'Debug->Start new instance' the ASP.NET Development server does not start new, and my Application's Start event is not fired.My workaround is to manually stop the development server - is there a setting to force this automatically?
View 1 Replies
Feb 26, 2010
Here is my code in SQL
[Code]....
Error i am facing is :
Msg 8668, Level 16, State 0, Line 2
Cannot create the clustered index 'RateViewIndex' on view 'NoteToPass.dbo.RateView' because the select list of the view contains an expression on result of aggregate function or grouping column. Consider removing expression on result of aggregate function or grouping column from select list.
View 1 Replies
Feb 2, 2010
what is difference in cluster index and noncluster index?
which is faster?how many cluster index and non cluster index per table?
what is composite primary key?on how many columns we can create composite key?
hao many maximum composite key's we can create on one table?
View 2 Replies
Jan 25, 2011
I have two control page in my aspx page. first one left side "tree view",second one right side " form design".Form design will change based on tree view selected index changed.i have 4 level child node(site, master , slave, space). I have seperate forms to each level of node.
cannot update tree node when update the forms. so i reload tree view.
now i need how to auto selected index change to tree node.
ex.
1 parent node
1.1 child node
1.2 child node
i have update "1.2 child node" rename to "1.3 child node"
and reload treeview so it will chage...
how set tree node.selected index = 1.3 child node....
View 3 Replies
Jan 3, 2011
gvOff.DataSource = o.ViewData(dCity.SelectedValue);
gvOff.DataBind();
gvOff.Columns[0].HeaderText = "ZZZZZZZZ";
gvOff.Columns[1].HeaderText = "YYYYYYYY";
gvOff.Columns[2].HeaderText = "XXXXXXXX";
Header count is correct.
AutoGenerateColumns: Flase/True ( i tried both)
If i remove the gvOff.Columns[index].HeaderText portions, GridView works fine, but when i put the gvOff.Columns[0].HeaderText, i get the exceptional error.
, i couldn't solve it. If you need further info, inform me.
EDITED:
Hold on! I commented the HeaderText portion and tested
int i = gvOffer.Columns.Count;
I found count is 0 eventhough the columns print out with DataBind()... Why?
NOTE: AutoColumn in this case is set to true. I guess i will have to edit the column
names from DataTable.
View 1 Replies
Apr 10, 2010
where should we use clustered index and non clustered index.i mean in day to day use which on e to choice and how to make decision.
View 8 Replies
Nov 3, 2010
How to change cluster index to non cluster index, if it is primary key?
View 2 Replies
Oct 29, 2010
I've done quite some research on which ASP .NET Facebook SDK to use. Acording to this post [URL] old FacebookToolkit should not be used for new projects but instead we should use the all new and shiny Facebook C# SDK.
But he problem is that it lacks documentation, especially beginners examples for creating Facebook applications with Facebook SDK and WebForms:
How to start Basic authentication examples More examples... Where did Facebook.Web.CanvasIFrameMasterPage go from Toolkit ?
View 1 Replies
Jan 3, 2011
I've got a solution consisting of two projects: an ASP.NET Web Application project and a WCF Service Application project.
When running the solution from within the VS 2010 IDE, two browser windows are started. One browser displays the ASP.NET form page, and the other browser showing a directory listing very much like this:
Directory Listing -- /
Saturday, December 18, 2010 10:40 PM <dir> App_Data
Monday, December 20, 2010 10:10 PM <dir> bin
Saturday, December 18, 2010 10:53 PM 111 ChatService.svc
Thursday, December 30, 2010 10:41 PM 455 ChatService.svc.cs
Friday, December 31, 2010 03:27 PM <dir> DataLayer
Monday, December 20, 2010 11:32 PM 265 IChatService.cs
Saturday, December 18, 2010 10:40 PM <dir> obj
Saturday, December 18, 2010 10:40 PM <dir> Properties
Friday, December 31, 2010 03:33 PM 4,609 Services.csproj
Friday, December 31, 2010 03:33 PM 1,086 Services.csproj.user
Sunday, December 19, 2010 08:35 AM 58 Services.Publish.xml
Monday, December 20, 2010 02:09 PM 959 Web.config
Saturday, December 18, 2010 10:40 PM 247 Web.Debug.config
Saturday, December 18, 2010 10:40 PM 343 Web.Release.config
Version Information: ASP.NET Development Server 10.0.0.0
The second browser window (with the directory listing) is obviously the WCF service. Now, is there a way to suppress the WCF service browser window, or is this the expected behavior since the WCF Service Application project is self-hosted?
Also, I've got the solution properties set to multiple startup projects.
View 2 Replies
Aug 18, 2010
When I run my project and I'm looking at a View, the project runs that start-up page specified in my HomeController class, which is great. But if I'm looking at a class or a model, and I run the app, then it tries to make that class the start-up page and gives me the error "A project with and Output Type of Class cannot be started directly". So I have to close the error box, open up a random view, and then run the app. Is there a way around this? It shouldn't matter that I'm working on a class file when I run my app.
View 3 Replies
Feb 25, 2011
I have a brand new computer installed with .net Framework 4. I have a 80004005 error that says something like "aspnet_wp.net can't be started because you have the wrong credentials" (sorry, the error message is in another language than english).I tried adding userName="SYSTEM" in the section of the machine.config but it didn't work.I'm desperate, I don't know what to try and I'm normally a Linux
View 2 Replies
Jul 21, 2010
I'm going to precompile an asp.net application in my custom c# form. How do i retrieve the process logs and check whether it is a successful process or not?
Here's my code
string msPath = "c:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\";
string msCompiler = "aspnet_compiler.exe";
string fullCompilerPath = Path.Combine(msPath, msCompiler);
msPath.ThrowIfDirectoryMissing();
fullCompilerPath.ThrowIfFileIsMissing();
ProcessStartInfo process = new ProcessStartInfo
{
CreateNoWindow = false,
UseShellExecute = false,
WorkingDirectory = msPath,
FileName = msCompiler,
Arguments = "-p {0} -v / {1}"
.StrFormat(
CurrentSetting.CodeSource,
CurrentSetting.CompileTarget)
};
Process.Start(process);
View 2 Replies
Feb 15, 2011
Can any one tell me how to start using Redis DB with asp.net .What I should install and what I should download.I'm using VS2008 with C#.
View 2 Replies
Feb 14, 2011
How to get the last time the current ASP.NET app was initiated?
View 2 Replies
Jul 19, 2010
I want to start creating ajax enabled websites.When i used .Net framework 2.0;then i used to install the "Microsoft ASP.NET 2.0 AJAX Extensions 1.0" after installing the Visual Studio 2005.Then i used to download the AjaxControlToolkit.zip.But now i am using the .Net Framework 3.5;hence i cant understand what should i download(instead of "Microsoft ASP.NET 2.0 AJAX Extensions 1.0") and install to get started with creating ajax enabled websites after installing the Visual Studio 2008?I gave a google search but in vain.Also i dont know which is the version to use here.Please give me a link wherefrom i can download so that i can start creating ajax enabled websites in Visual Studio 2008.
View 6 Replies
Jun 11, 2010
if anyhow my session have ended then how can i start the session again in the code.
View 3 Replies
Apr 16, 2010
I m making an application in asp.net 3.5. I have added .edmx file in my appliaction and create all the instances of datatable in the edmx file. now i want to know how to start querying with this edm like inserting updating and selecting etc. from database.
View 7 Replies
May 25, 2010
start learning ASP.NET Help getting started in programming? I am new to programming.How can I best start to learn?
View 6 Replies
Mar 22, 2010
I am trying to have a time clock on my page, I want it to start from 0:00 and then start going up, my plan was to have an AJAX timer and a updatepanel with a label inside of it which would refresh every minute and update the time, how can I get the code in VB.NET to start from 0:00 and increase by 1 minute?
View 6 Replies