You are welcome, hope your problem is fixed:)
robert110
Posts
-
Maximum Attachment Size -
Maximum Attachment SizeYou can do the following: Goto File > Source Control > Exclude "MyFileOrFolderName" from Source Control You can also exclude that folder from your VS2005 project if it is not directly used in the project that will also take care of the VSS problem. Hope that helps:) Robert
-
Maximum Attachment SizeIf file is located on the server then I would first check for common things like for instance if the file is locked or not, read access, other error handling code that might cause an infinite loop etc. Post your code so we can see exactly how you are trying to attach the file. Thanks. HTH Robert
-
Last Accessed Date and Time.If, in your database table, you have a field that stores the Last Access Date and Time then you will just need a select statement for e.g.
SELECT LastAccessDateTime FROM myTable WHERE myRecordID = 'SomeRecordId'
If you don’t have a field that stores that value then you might want to add the field in the table and use Triggers to update that field or you could also do it programmatically. HTH Robert
-
Maximum Attachment SizeNot sure if you are trying to attach the file from a web interface or if the file is located on the server. If you are having the user upload the file as attachment then you might have to override the httpRuntime's maxRequestLength value in the web.config file. By default ASP.NET only allows files with size 4MB [4096 KB] or less to be uploaded but you can change it like this:
<httpRuntime maxRequestLength="8192" />
-
What does "Clean Solution" do?In Visual Studio 2005 if you go to Build menu you'll see an option for "Clean Solution". What exactly does this command do for us and also when should we use it? Thanks. Robert
-
Type conversionHello everyone: What is the difference b/w
int x = (int)MyValue;
andint x = System.Convert.ToInt32(MyValue);
which should be used when and why? Thanks. We are using an automated tool for standard validation and its fussing about (int) way of type conversion, can someone plz explain the difference b/w the two. Thanks. Robert -
When to use Server.Transfer?Can someone explain when would be a good time to user Server.Transfer? Thanks. - Robert
-
Connection Strings for Class Library ProjectI have a solution that has 3 projects. One of them is serving as Class Library project (technically its a ASP.NET Web Application Project but it only contain classes). Where would be the best place to store all the connection strings? 1- GCL.config file? I could use ConfigurationManager class to access the connection strings or 2- Global.resource file? I could reference it directly GlobalResources.MyConnectionString.ToString(); Just trying to find out the best practice:) Thanks. Regards, Robert
-
How can I get the % CPU usageThanks a lot :)
-
How can I get the % CPU usageI am needing to find out the current CPU usage to determine if I need to run a service or not. If the computer is currently busy then I would like to pause my win-services for x-amount of time and then run it again so users don’t feel the repercussions of my programming and vice versa. In the Task Manager (at the bottom status bar) we can see the # of processes, CPU Usage etc. How I can get/calculate that? Are there any classes available? Thanks in advance.
-
User authentication ASP -> ASP.NET pageHello all: We have an application that is written in Classic ASP which requires users to login (same as forms authentication in .NET). We need to add some more pages to this application which will be written in ASP.NET 2.0 When a user logs in, he/she uses the classic ASP interface to use their user IDs and passwords which verifies them. Any ideas as to how I can take care of the authentication and still be able to use ASP.NET 2.0 classes to verify that the user has been authenticated? Will I need extend any of these classes? Any help will be appreciated. Thanks. Robert
-
Environment Independent Connection StringsI am not sure if that would work because when we will publish the website the development copy of web.config will be promoted to production:( Or am I missing something? Thanks for your help.
-
Environment Independent Connection StringsHow can I dynamically determine which environment my code is running in? For instance I would like for my apps to dynamically determine if they need to use the DEV connection strings or Production connection strings (within my DAL). By doing so I would avoid having to manually edit connection strings every time I make changes to my app. Appreciate your help.
-
Top News Headlines with C#I need to add a "news headlines" (perheps CNN news headlines) section in my project, any ideas or suggestions? Thanks.
-
Dynamically adding webpart propertiesI have a webpart that displays departmental news. Every department have different news section for instance Admin dept have three news section: 1- Admin 2- HR 3- General Sales dept have four: 1- Company Sales News 2- Stock News 3- Global Market News 4- Sales Forecast Now, I want to expose these sections as properties of my WebPart so if a Sales user is logged in; when he will enter Edit Mode; he sees all four sections in Sales Dept and from which he can choose what all it is that he wants to see on the webpart. I can hardcode something like this:
protected bool _CompanySales = true; [ Personalizable(PersonalizationScope.User), WebBrowsable, WebDisplayName("Company's Sales News"), WebDescription("Use this property to show/hide Company's Sales news")] public bool CompanySales { get { return _CompanySales ; } set { _CompanySales = value; } } protected bool _StockNews= true; [ Personalizable(PersonalizationScope.User), WebBrowsable, WebDisplayName("Stock News"), WebDescription("Use this property to show/hide Stock News")] public bool StockNews{ get { return _StockNews; } set { _StockNews= value; } } protected bool _GlobalMarketNews= true; [ Personalizable(PersonalizationScope.User), WebBrowsable, WebDisplayName("Global Market News"), WebDescription("Use this property to show/hide Global Market News")] public bool GlobalMarketNews{ get { return _GlobalMarketNews; } set { _GlobalMarketNews= value; } } // ... // ETC
But I wouldn't have any knowldge of these sections because they are stored in the database. So I guess my question is; how can I dynamically define properties of a webpart by pulling the data from a datasource? Thanks in advance.
-
Calling UserControl Method from WebFormI have a user control that takes user input and when you click the 'calculate' button; it does some calculation with JavaScript and save the value to a hidden input box. I want to call the 'calculate' button's logic from my WebForm so that it can do its calculation using JavaScript and save the value to the hidden input textbox; which i can reach using myUserControl.FindControl method. How can I do that? Alternatively I would like to know how I can access a UserControl method (that returns a string value) from WebForm? Thanks for your help.
-
How to add parameter for 'In' clauseMy Sql statement looks like this:
SELECT * FROM TBL_MyTable WHERE ID in (1,5,9,10,5248)
I want to use parameterized SQL command, how can I add the parameter value to it? This is what I have so far:
cmd.CommandText = "SELECT * FROM TBL_MyTable WHERE ID in @ID"
cmd.Parameters.Add("@ID", SqlDbType.Int.Int).Vlaue = "(1,5,9,10,5248)";but its not working, any suggestions? Thanks.
-
locking the record in vb.netNot sure what exactly you are looking for but you might want to look into sql transactions. On the other hand if you are using DataSets you might want to check into "UserOptimisticConcurency". HTH
-
Windows applications and use of RDBMSOk this might sound like a very dumb questions to many ppl but I have got to understand it so ignore the dumbness of the question:). Anyways, in windows applications (for e.g. Quicken, QuickBooks, MS Money or any other data-extensive application) how and where do they store the data? Do they use a database? if they use a database then why don't they ask us to install a database engine (which should be a prerquisite - MSDE for instance)? If they don't use database then how in the heck do they keep up with the relational data?:confused: Your help will be appreciated:). Thanks in advance.