Estoy siguiendo el tutorial de MVC Music Store, pero me he quedado un poco atascado con Html Helper en la parte 5: Part 5.Los tipos estáticos no se pueden usar como parámetros
que parecen haber seguido correctamente hasta el momento (por favor, corríjanme si me equivoco :)) ... Sin embargo, estoy consiguiendo el error siguiente:
'musicStoreMVC.Helpers.HtmlHelper': static types cannot be used as parameters
Aquí está el código de mi solicitud :
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
namespace musicStoreMVC.Helpers
{
public static class HtmlHelper
{
public static string Truncate(this HtmlHelper helper, string input, int length)
{
if (input.Length <= length)
{
return input;
}
else
{
return input.Substring(0, length) + "...";
}
}
}
}
Si alguien puede ver lo que estoy haciendo mal, o si se necesita más información, estaría agradecido por los punteros !! Gracias.
Gracias a todos los que respondieron! ¡Los nombres eran muy similares! :) – 109221793
http://stackoverflow.com/questions/5858591/c-sharp-static-types-cannot-be-used-as-type-arguments –