Search Results

Search found 1117 results on 45 pages for 'angularjs directive'.

Page 30/45 | < Previous Page | 26 27 28 29 30 31 32 33 34 35 36 37  | Next Page >

  • Problem with Models on Master Page View.

    - by user342514
    Have a problem with master page views and models. In the first image, I have a simple view in which I am trying to access the Model properties. None of the model properties are available at this time (this is the problem). If I use a <%= Model.blah % then you can see that the model properties are available. Second photo. In the last photo you will now see that I can access the Model properties that I was trying to access in the first photo. An error will be thrown if viewing this page if you don't first do <%= with the model. CS1061: 'object' does not contain a definition for 'User' and no extension method 'User' accepting a first argument of type 'object' could be found (are you missing a using directive or an assembly reference?) http://yfrog.com/8b43656447p So why is this happening?

    Read the article

  • Using C# Type as generic

    - by I Clark
    I'm trying to create a generic list from a specific Type that is retrieved from elsewhere: Type listType; // Passed in to function, could be anything var list = _service.GetAll<listType>(); However I get a build error of: The type or namespace name 'listType' could not be found (are you missing a using directive or an assembly reference?) Is this even possible or am I setting foot onto C# 4 Dynamic territory? As a background: I want to automatically load all lists with data from the repository. The code below get's passed a Form Model whose properties are iterated for any IEnum (where T inherits from DomainEntity). I want to fill the list with objects of the Type the list made of from the repository. public void LoadLists(object model) { foreach (var property in model.GetType() .GetProperties(BindingFlags.Public | BindingFlags.Instance | BindingFlags.SetProperty)) { if (IsEnumerableOfNssEntities(property.PropertyType)) { var listType = property.PropertyType.GetGenericArguments()[0]; var list = _repository.Query<listType>().ToList(); property.SetValue(model, list, null); } } }

    Read the article

  • Please help, now I have a matrix, I want use Combination algorithm to generate a array for length 6

    - by user313429
    The first thanks a lot for your help , the following is my matrix, I want to implement combination algorithm between multiple arrays in LINQ for this matrix. int[,] cj = { { 10, 23, 16, 20 }, { 22, 13, 1, 33 }, { 7, 19, 31, 12 }, { 30, 14, 21, 4 }, { 2, 29, 32, 6 }, { 18, 26, 17, 8 }, { 25, 11, 5, 28 }, { 24, 3, 15, 27 } }; other: public static IEnumerable<IEnumerable<T>> Combinations<T>(this IEnumerable<T> elements, int k) { return k == 0 ? new[] { new T[0] } : elements.SelectMany((e, i) => elements.Skip(i + 1).**Combinations**(k - 1).Select(c => (new[] { e }).Concat(c))); } The above method has a error in my project, System.Collections.Generic.IEnumerable' does not contain a definition for 'Combinations' and no extension method 'Combinations' accepting a first argument of type 'System.Collections.Generic.IEnumerable' could be found (are you missing a using directive or an assembly reference? I use .Net Framework3.5, what is the reason it?

    Read the article

  • error message: clientside validation

    - by user281180
    What is the meaning of the following error message?How can I use the EnableClienTValidation()? Error 3 'System.Web.Mvc.HtmlHelper' does not contain a definition for 'EnableClientValidation' and no extension method 'EnableClientValidation' accepting a first argument of type 'System.Web.Mvc.HtmlHelper' could be found (are you missing a using directive or an assembly reference?) c:\Dev\DEV\test3\Code\MvcUI\Views\Customer\Create.aspx 11 13 MvcUI I have reference the following:`" type="text/javascript" <script src="<%=Url.Content("~/Scripts/jquery.validate.js")%>" type="text/javascript"></script> <script src="<%= Url.Content("~/Scripts/MicrosoftAjax.js")%>" type="text/javascript"></script> <script src="<%= Url.Content("~/Scripts/MicrosoftMvcAjax.js")%>" type="text/javascript"></script> <script src="<%= Url.Content("~/Scripts/MicrosoftMvcJQueryValidation.js" )%>" type="text/javascript"></script> `

    Read the article

  • Simple neon optimization in Android

    - by Peter
    In my Android application, I use a bunch of open source libraries such as libyuv, libvpx, libcrypto, libssl, etc. Some of them come with Android.mk. For others, I hand-crafted Android.mk. The code is built only for arm for now. Here is my Application.mk: APP_ABI := armeabi-v7a APP_OPTIM := release APP_STL := gnustl_static APP_CPPFLAGS := -frtti I am looking for way to generate binaries that are optimized for neon. Browsing the net, I found the following setting that someone is using in his Android.mk: LOCAL_CFLAGS += -mfloat-abi=softfp -mfpu=neon -march=armv7 I wonder if I simply put this setting in Application.mk, will it automatically get applied across all the libraries? A step before each library is built is the following: include $(CLEAR_VARS) Is it better to include LOCAL_CFLAGS directive after this line (instead of including it in Application.mk)? Finally, why doesn't ndk-build automatically optimize for neon when it sees armabi in Application.mk? Regards.

    Read the article

  • Is it possible to modify ASP.NET to no longer require runat="server"?

    - by sean2078
    I know why runat="server" is currently required (ASP.NET why runat="server"), but the consensus is that it should not be required if you incorporate a simple default into the design (I agree of course). Would it be possible to modify, extend, decompile and recreate, intercept or otherwise change the behavior of how ASP.NET parses ASPX and ASCX files so that runat="server" would no longer be required? For instance, I assume that a version of Mono could be branched to accomplish this goal. In case specific requirements are helpful, the following highlights one design: During parsing, when configured namespace tags are encountered (such as "asp"), default the element's runat property to "server" During parsing, when configured namespace tags are encountered (such as "asp"), if the element's runat property value is available, then that value should be used in place of the default New page-level setting introduced (can be set in the page directive or web.config) that specifies the default runat value for a specific namespace tag

    Read the article

  • J2EE: Default values for custom tag attributes

    - by Nick
    So according to Sun's J2EE documentation (http://docs.sun.com/app/docs/doc/819-3669/bnani?l=en&a=view), "If a tag attribute is not required, a tag handler should provide a default value." My question is how in the hell do I define a default value as per the documentation's description. Here's the code: <%@ attribute name="visible" required="false" type="java.lang.Boolean" %> <c:if test="${visible}"> My Tag Contents Here </c:if> Obviously, this tag won't compile because it's lacking the tag directive and the core library import. My point is that I want the "visible" property to default to TRUE. The "tag attribute is not required," so the "tag handler should provide a default value." I want to provide a default value, so what am I missing? Any help is greatly appreciated.

    Read the article

  • LINQ and paging with a DataTable - can't get Skip working?

    - by Kit Menke
    Ok so this might be a dumb question, but I can't seem to figure it out. I thought I'd try out LINQ against a DataTable. I got my query working and now I'm trying to implement some simple paging. DataTable dataTable = null; dataTable = GetAllDataTables(); var query = from r in dataTable.AsEnumerable() orderby r.Field<string>(Constants.fileName) select r; query.Skip(WPP_PAGE_SIZE * pageIndex).Take(WPP_PAGE_SIZE); My problem is that I get an error at query.Skip(...). Error 1 'System.Data.OrderedEnumerableRowCollection' does not contain a definition for 'Skip' and no extension method 'Skip' accepting a first argument of type 'System.Data.OrderedEnumerableRowCollection' could be found (are you missing a using directive or an assembly reference?) References I have: Microsoft.SharePoint System System.Core System.Data System.Data.DataSetExtensions System.Web System.Xml What am I missing?

    Read the article

  • What are CFI directives in Gnu Assembler (GAS) used for?

    - by claws
    There seem to be a .CFI directive after every line and also there are wide varities of these ex.,.cfi_startproc , .cfi_endproc etc.. more here. .file "temp.c" .text .globl main .type main, @function main: .LFB0: .cfi_startproc pushq %rbp .cfi_def_cfa_offset 16 movq %rsp, %rbp .cfi_offset 6, -16 .cfi_def_cfa_register 6 movl $0, %eax leave ret .cfi_endproc .LFE0: .size main, .-main .globl func .type func, @function func: .LFB1: .cfi_startproc pushq %rbp .cfi_def_cfa_offset 16 movq %rsp, %rbp .cfi_offset 6, -16 .cfi_def_cfa_register 6 movl %edi, -4(%rbp) movl %esi, %eax movb %al, -8(%rbp) leave ret .cfi_endproc .LFE1: .size func, .-func .ident "GCC: (Ubuntu 4.4.1-4ubuntu9) 4.4.1" .section .note.GNU-stack,"",@progbits I didn't get the purpose of these.

    Read the article

  • Odd C interview question

    - by Brennan Vincent
    Hi guys. I found this problem on a site full of interview questions, and was stumped by it. Is there some preprocessor directive that allows one to read from standard input during compilation? Write a small C program, which while compiling takes another program from input terminal, and on running gives the result for the second program. (NOTE: The key is, think UNIX). Suppose, the program is 1.c Then, while compiling $ cc -o 1 1.c int main() { printf("Hello World\n"); } ^D $ ./1 Hello World

    Read the article

  • Selectedindex in listview, throwing up an error!

    - by Luke
    Hey guys, the following code shows what i am trying to do. private void btnEdit_Click(object sender, EventArgs e) { iDeliverySelected = lstDeliveryDetails.SelectedIndex; bool addEdit = false; } The selectedindex is throwing up the following error.. 'System.Windows.Forms.ListView' does not contain a definition for 'SelectedIndex' and no extension method 'SelectedIndex' accepting a first argument of type 'System.Windows.Forms.ListView' could be found (are you missing a using directive or an assembly reference?) Any ideas why? First time I have tried to use SelectedIndex, not sure if i am using it correctly?

    Read the article

  • SSI not producing output, not giving error either.

    - by bstullkid
    in the html file: <!--#exec cgi="/cgi-bin/test.pl"--> the perl script: #!/usr/bin/perl print "Content-Type: text/html\n\n"; print "<input type=\"hidden\" name=\"aname\" value=\"avalue\">\n"; print "<img src=\"/cgi-bin/script.pl\" />"; This does not give me an 'error processing directive' error, nor does it output my HTML inplace of the tag. I'll also add that the ssi tag gets replaced with nothing.

    Read the article

  • What is my problem with ASP.NET pubslishing?

    - by Shankarooni
    I am done testing my site and I want to upload it to a site like this http://www.university.edu/mydepartment/myname the admin told me the server runs on .NET 3.5. So i used Linq ... now i tried to upload the site by two ways: when i just copy everything (with modification of web.config database settings) i get an error: CS0246: The type or namespace name 'DataClassesDataContext' could not be found (are you missing a using directive or an assembly reference?) Version Information: Microsoft .NET Framework Version:2.0.50727.3082; ASP.NET Version:2.0.50727.3082 Note here it says version 2.0 did he just lie to me? or its my configuration mistake? anyway, i added the reference, nothing changes. I tried also publishing (Build, publish) with option to keep the pre-comiled site updatable, and I get one line saying: this is a makefile and should be deleted! what is going on?

    Read the article

  • Type or namespace name could not be found

    - by Pandiya Chendur
    I use this: public IQueryable<MaterialsView> FindAllMaterials() { var materials = from m in db.Materials join Mt in db.MeasurementTypes on m.MeasurementTypeId equals Mt.Id select new MaterialsView { MatId = m.Mat_Name, MesName = Mt.Name, MesType = m.Mat_Type }; return materials; } It gives me the following errors: The type or namespace name MaterialsView could not be found (are you missing a using directive or an assembly reference?) Cannot implicitly convert type System.Collections.Generic.IEnumerable<MaterialsView> to System.Linq.IQueryable<MaterialsView>. An explicit conversion exists (are you missing a cast?) The type arguments for method System.Linq.Enumerable.ToList<TSource>(System.Collections.Generic.IEnumerable<TSource>) cannot be inferred from the usage. Try specifying the type arguments explicitly. I have googled it and found this SO question but it doesn't help. What's wrong?

    Read the article

  • Wordpress Custom Themes > How to script Categories, Tags and Excerpt options to appear on "page" edi

    - by Scott B
    I'm using custom WordPress categories for some probably unintended functions, I will admit (things like marking a post no/index just by adding it to my custom "no-index" category, etc). But it sucks that WordPress does not enable pages with all the little extras you get with posts. For example, while the post editor gives you convenient access to Tags, Categories, and a Post excerpt field, pages get left out in the cold. I'd like to know if its possible to add the These items to the Post editor via add_action() directive from a custom theme.

    Read the article

  • PHP and Apache environment variables

    - by Simon
    Hello, I want to pass an environment variable in linux to apache on start up. export MYVAR=5 --I define my environment variable on the command line PassEnv MYVAR --set apache to import the variable in apache config file apachectl restart --when I restart apache I don't get an error message. However I have noticed that if I do not create the environment variable in my first step, I get a warning message, so must be working here echo $_SERVER['MYVAR'] --i try to access the environment variable within PHP but it is not defined I've observed that if I try to PassEnv an environment variable that already exits (one that I havn't created myself) it works fine. The SetEnv directive also works fine. I'd really like to pass an environment variable to apache on the fly without writing it in a file. Help much appreciated. I'm using CentOS, PHP5 and Apache2. Thanks.

    Read the article

  • Installed Redmine on Ubuntu; But i have no clue how to use it to create Users/Projects/Roles/Tracking etc.....

    - by Ronnie
    Hi all, Im new to Redmine. I installed redmine(with mysql) on Ubuntu 10.04. The following were the installation steps i did: $ sudo apt-get install redmine redmine-mysql subversion $ ln -s /usr/share/redmine/public /var/www/redmine In /etc/apache2/mods-available/passenger.conf, added a PassengerDefaultUser www-data directive. Configured the /var/www/redmine location in /etc/apache2/sites-available/default: RailsBaseURI /redmine PassengerResolveSymlinksInDocumentRoot on $ sudo a2enmod passenger I then restarted the apache2 server. Thats it. Now i typed http://localhost/redmine/ in my browser and accessed my redmine instance. So from here on, how do i create different users with with different privileges, create different projects, also update the issues and other project management related stuff..... I know this sounds silly, but i couldnt find anythin to proceed....

    Read the article

  • Linq Query Giving Error

    - by user275561
    I am getting this error when I use the Linq expression of var emp = _testModel.Where(m => m.Date == DateTime.Now).Select(m=>m); 'System.Collections.Generic.IEnumerable' does not contain a definition for 'System' and no extension method 'System' accepting a first argument of type 'System.Collections.Generic.IEnumerable' could be found (are you missing a using directive or an assembly reference?). I have google'd and looked everywhere by I have no idea what it is talking about? It doesn't throw an exception. The only way I found out about this was stepping through the expression.

    Read the article

  • Generic List .First not working LINQ

    - by Hurricanepkt
    var stuff = ctx.spReport(); var StuffAssembled = new List<ReportCLS>(); var val = new List<ReportCLS>(); foreach (var item in stuff) { StuffAssembled.Add(new ReportCLS(item)); } val.Add(StuffAssembled.First()); Keeps throwing System.Collections.Generic.List' does not contain a definition for 'First' and no extension method 'First' accepting a first argument of type 'System.Collections.Generic.List' could be found (are you missing a using directive or an assembly reference?) what is going wrong ? moreover how do i fix it? Thanks

    Read the article

  • Nginx redirect if cookie present

    - by Joseph Silvashy
    I've seen some limited resources on checking for cookies with Nginx, but I couldn't really find the answer I was looking for, hopefully some of you Nginx masters can give me a hand. Essentially I have a vhost that I'd like to redirect to a different domain unless the user has a cookie, here is what I've created: server { listen 80; server_name rerecipe.com; if ($http_cookie ~* "ngl_beta_pass" ) { # set $beta off; root /home/deploy/apps/rerecipe/current/public; passenger_enabled on; rack_env production; break; } rewrite ^/(.*) http://beta.rerecipe.com/$1 permanent; } But it doesn't seem to work, I get the error: [emerg]: "root" directive is not allowed here in /opt/nginx/conf/nginx.conf:45 I'm not sure how to proceed here, any ideas guys?

    Read the article

  • Compile MvcContrib Portable Area with aspnet_compiler

    - by isuruceanu
    Hi I have a .net mvc 2 web application. I deployed this application using aspnet_compiler and a nant build file like <target name="deploy.advance.application"> <exec program="${aspnet.compiler}" commandline='-f -u -c -p ${dir.website.advance.application} -v temp ${dir.publish.advance.application}' /> <mkdir dir="${dir.publish.advance.application}\App_Data" /> </target> Now I started to implment PortableArea, at least LoginArea with all pages embedded, required by the MvcContrib PA. On my local machine works fine, but on testing environment (when I deploy the application with aspnet_compiler) the application could not found Login.aspx view. So the question is how to deploy such applications? There is a directive from aspnet_compiler to tell the compiler that there are some embedded resources? Thanks

    Read the article

  • Any way to chunk gzip with Apache and PHP

    - by donatJ
    I have a web application on a site that takes a while (~10 seconds) to complete a portion of the page near the bottom - it has been as optimized as it can be, and caching is not an option. We have compression enabled on the server via an .htaccess directive SetOutputFilter DEFLATE the problem is this causes the whole page to be held until completion before it starts outputting to the user, this is not optimal as the user sees nothing until the page completes. I have also tried it via the php ob_start("ob_gzhandler"); method. Currently I have a <FilesMatch > in my .htaccess restricting this specific script from being compressed. Basically my question is this - Is there a way to say chunk gzip or deflate so that the user gets it in pieces, so they can see that the page has begun loading?

    Read the article

  • ValidateRequest = False but in action it's still True and ignored that?

    - by Sadegh
    hi guy's, i want disable RequestValidation on particular view in ASP.NET MVC 2.0 RTM. so i added some necessary to view Page directive section as below: <%@ Page ValidateRequest="false" Language="C#" MasterPageFile="Path" Inherits="System.Web.Mvc.ViewPage<Path>" %> but RequestValidation isn't Disabled! i also added RequestValidation Attribute to related action in controller as below: [System.Web.Mvc.ValidateInput(false)] public System.Web.Mvc.ActionResult Create(Model instance) { //Do here something } :') but RequestValidation isn't Disabled too! in last try i set RequestValidation to false in Web.config file as below: <pages validateRequest="false" /> RequestValidation still isn't turned off! Why? thank's in advance ;)

    Read the article

  • Losing scope for DataContex using LINQToSQL intermediately

    - by greektreat
    I am having a weird Situation with my DataConext. All My code is in C# I have a DLL project for my data access layer and business Layer which and Winforms project for my UI layer. My Data access Layer's Namespace is xxx.Data this is where have my xxx.dbml I also have xxx.Data.BusinessObjects name space of course for my business object in that project In my UI Layer I have these namespaces xxxApp(for Forms), xxxApp.Controls (For Controls) I have lost scope of the DataContext, it was accessible now when I do a Rebuild Solution I sometimes get compile errors saying for example: Error 34 'xxx.Data.xxxDataContext' does not contain a definition for 'SubmitChanges' and no extension method 'SubmitChanges' accepting a first argument of type 'xxx.Data.xxxDataContext' could be found (are you missing a using directive or an assembly reference?) Also intelisense doesn't recognize the methods and table classes from my xxxDataContext anymore I can access all object fine when I am in the DLL project but now in the Winforms project this is very strange. If anyone can help me out I would be extremely grateful!

    Read the article

  • Seperate compilation in C++

    - by Pat Murray
    Suppose you are creating a class with multiple .cpp files (which each contain the implementation of a member function) and have the class' declaration in a .h file. Also, each .cpp file includes the .h file via the include directive. I was told that if you change the implementation of any of the member functions (.cpp files) that you will have to recompile every .cpp file in order to run the program. That is, if I had 5 member functions (each implemented in a .cpp file) and I changed the implementation of 1 of the .cpp files I would have to compile the 1 .cpp file I changed AND the 4 other .cpp files I didn't change in order to correctly run my program. My question, if the previous statement is true, is why is the statement is true? Any insight on this concept would be helpful.

    Read the article

< Previous Page | 26 27 28 29 30 31 32 33 34 35 36 37  | Next Page >