ADO.NET :: Creating A Public Arraylist Which References A Sqldatasource?
Feb 28, 2011I'm trying to create a public arraylist that references a single field inside an sql table.
View 4 RepliesI'm trying to create a public arraylist that references a single field inside an sql table.
View 4 RepliesI need to create a public bool that checks a string for items in an arraylist.
Here is a vague sample of what I'm talking about..
[Code]....
I'm not experienced enough with the foreach statement to quite figure out what I'm doing wrong here.
how to create a bar chart from the values in the arraylist?
View 3 RepliesI am using Reporting Services to render a report directly to PDF. It requires that I use two web references: ReportExecution2005.asmx and ReportService2005.asmx. The performance on web references seems really poor. Since my web server (IIS7) and my SQL Server (2008) are on the same box, is there a way I can reference them directly? If not is there any way I can explicitly cache them or something. First load is really really slow, second load is perfectly acceptable.
View 2 Repliesi want to create a arraylist which will able to store user info like (username,machineIP,port ) for each user in the list & retrive this data when needed . any one tell me how i can do it or any alternative way without database or xml file.
View 6 RepliesI can access a module from code behind but not from the aspx page in inline VB code <% ... %>.
I know its got to be something simple but I can't seem to find the answer anywhere.
How do declare a public variable .aspx web page that can be used in all the pages within my web application? And/or create a Public Sub?
View 3 RepliesI'm trying to include script and style references that will not break on deployment, however I can not even get the references to work locally. I have tried using Url.Content() and MVCContrib's <%=Html.ScriptInclude("")%>.
My scripts are in a Scripts folder on the root of the site; my styles are in the usual Content/css/ folder.
The scripts render like this:
<script type="text/javascript" src="/Scripts/MicrosoftAjax.debug.js" ></script>
This will not work in a view page in the Views folder. What am I doing wrong and what is the best way to handle this?
I would have thought Url.Content() would at least work for styles but used in my master page, the link rendered
<link href="/Content/css/Site.css rel="stylesheet" type="text/css" />
This does not work, because the Master Page is in a Shared folder, so what is really the way forward with this?
I have a question about C Sharp ASP.NET:Is there a difference (in code speed, resources) between:public static variable declared in public static class MyGlobals in a 'Code File' template;and the variable declared in a normal 'Class File' template;I use this variable in 2 different Class Files and also in _Default Page codebehind cs file.In fact in my case I need about 20 global variables of type List<string>.
View 9 RepliesI am trying to tie a sqlDatasource to a Stored Procedure. The stored procedure looks like...
[Code]........
I looked at Ajax 4, but on my XP box I had errors I couldn't work with. So I uninstalled Ajax 4 and installed Ajax 3.5, then copied the DLL files to all the Bin directories of the web sites on the development box. I thought everything was fine, but after several hours of development, I again started getting the error:AjaxControlToolkit requires ASP.NET Ajax 4.0 scripts. Ensure the correct version of the scripts are referenced. If you are using an ASP.NET ScriptManager, switch to the ToolkitScriptManager in AjaxControlToolkit.dll.
View 1 RepliesI am starting a new website based on an existing one that I already have up and working. I copied the old website files into a new folder but it will not run. The error suggets that I need to add a reference. So my question is . . . how can I identify the references that are included in the original site?
View 3 RepliesI was comparing SharpArch to Spring.NET earlier, and had some thoughts.Both contain Core, Data and Web namespaces (as well as others). While SharpArch maintains them all in one assembly, Spring.NET does so in separate assemblies.Initially, I liked this concept, because one could reference the Core without indirectly referencing something they didn't need, like System.Web.However, it later occurred to me that whether or not things were combined, they still operated within the .NET space and have equal access to the GAC.So why not put things in one assembly, as long as individual elements in their namespaces do not make use of certain things?Of course, I'm talking about a base-line assembly, not an actual business solution.
View 1 RepliesIf have a folder (say "binaries") and place all the 3rd party dll's you are going to use in there. When you reference the dll in your project, what is the use of setting "Copy Local"?If you dont set Copy Local, does your code reference the dll in that folder and the folder have to be deployed with your application?
I just had another "something new" and that was a dll just have to be present apparently in the web project's bin folder.The "easy way" suggested was adding a post build like this:
Quote:xcopy "$(SolutionDir)binaries/*.dll" "$(ProjectDir)bin" /y
xcopy "$(SolutionDir)hibernate.cfg.xml" "$(ProjectDir)bin" /y
xcopy "$(SolutionDir)Log4Net.config" "$(ProjectDir)bin" /y
all that dll's get copied over, and I dont even know what is really required.Btw, I noticed with the above script that say "NHibernate.dll" get copied over, but "NHibernate.Caches.SysCache.dll" not.
I have dlls in bin directory. I can't see where they are referenced in either solution or web.config files. So where are the references stored ?
View 3 Replies in one of my project I have to add System.ServiceModel.Web namespace. I try to add reference in this way:
(1). Right click on references in the project solution explorer
(2). search for System.ServiceModel.Web name space.
But it is not here. How can I add this name space to my project and .net pannel?
I need to format references. My customer wants the reference to be left aligned, with all the lines after the first one indented. Like this:
This is a reference. This reference can be several lines long, and all the lines after the first one need to be undented like this.
Assume this is taking up the width of the screen, I'm trying to not have to type more than I really need to. The width is dynamic, so there is no fixed width. Otherwise this would not be a problem.
ASP.NET 3.5 Classes throughout our solution referenced ConfigurationManater.AppSettings[""] to get appSettings (from web.config).
We decided we weren't happy with that. Folks were mistyping appSetting key names in code (which compiled fine), and it was cumbersome to track usages. And then there's the duplicated strings throughout the codebase as you reference the same appSettings all over the place.
So, we decided that only one class would be allowed to reference the ConfigurationManager, and the rest of the solution would reference that class when it needed the value of a certain appSetting. ConfigurationManater.AppSettings[""] was static, so we exposed a bunch of static read-only properties off of our single Settings class.
[Code].....
And now we're injecting the ISettings instance as a dependency of the objects which use settings values (the class/interface are in a project that everyone can reference without problems).
In places where we can't inject an existing instance (e.g. Global.asax), we construct a new instance into a static field.
Given all of that, what would you recommend we change, and why?
i had generated a Service Contract interface by using wsdl.exe (VS2010 command prompt). After that i create a WCF method which inherit from the interface class which was created by the wsdl.exe. And then i host the web service to local IIS.
When i use the simulator provided by vendor, the method is working fine.
But when i created my own project and add service reference (by key in the url), and using the code below:
[Code]....
when i type client. , i cant found the method inside the intellisence box. Which supposely got 2 methods inside this service references.
I am developing job portal, i have one
1)tbl_jobseeker
columns
---jobseeker_id
---fname
--lname
-----
--refrences
in this table i am stroring job seeker information i strucked where i want to store 3 refrences for one jobseeker in each refrence i have refernce_Name, refrence_Mobile like while jobseeker registration he can enter 3 refrences forhim eg: jobseejer form look like this
FirstName: sachin
Last : Kumar
refrences : refrenceName referMobile
xyx +9198888
abc +91988555
dfd +915858855
Save Cancel
im creating a class library, and adding all the necessary references for the source files contained in it.
Now, off the bat, there were over 300 compiler errors complaining about missing namespaces.
The library will now compile after i just added all of the System.* references, however this is obviously not the best way.
I.e. if a classes needs using System.Web.Script;, there is no System.Web.Script reference, how would i find out which one of these references contained it? System.Web didnt.
I have a function called populateList(). I want it to take a reference to a Checkboxlist or a Dropdownlist, query the DB and fill the referenced list with values.Is it possible to generalize the function to take a Checkboxlist or a Dropdownlist depending on what you pass?Or, do I have to write two different functions, one for the Checkboxlist and one for the Dropdownlist?I guess the my question is if theres a common object that covers both, like populateList(ref GeneralList list)
View 2 RepliesI added my wsdl web reference to the project and have it there. Good to go. I created a new default.aspx page. How do I use the web reference and process a soap request with it? I'm finding a lot of examples out there for C#, but little or nothing for .net ....
View 11 RepliesI am looping through a dataset and I would like to have the following in this array list
name, from, to, price
john, 40, 50, 39.99
mike, 20, 50, 49.99
etc.
Once I do that, or if it is possible to do it using the dataset that will work with me. But I want to do...
If john's price between from and to...
So in my code I wanted to make it easy for me and instead of memorizing the row #, I would just do.. arraylist.row("john").item("from")
I have a solution containing 4 class library projects and one "web site" project. The web site project contains references to the 3 class library projects, whenever I make changes in any of the class library projects, the only option I see is to rebuild the web site which takes a lot of time. Is there any option that I can only update the dll references and the changes are reflected in the web site project?
View 1 Replies