html - pre tag'i
$("#showCase2").showcase({ images: [{ url: "images/showcase_rik_1.jpg", description: "Imageset from flickr", link: "#" }, { url: "images/showcase_rik_2.jpg", description: "Just Perugia", link: "#" }, { url: "images/showcase_rik_3.jpg", description: "Anzio, winter sea", link: "#" }, { url: "images/showcase_rik_4.jpg", description: "Livorno, Piazza Grande", link: "#" }, { url: "images/showcase_rik_5.jpg", description: "Glacial", link: "#" }], width: "650px", height: "435px", animation: { autoCycle: false }, navigator: { position: "top-left", showNumber: true, orientation: "vertical", padding: "3px", item: { cssClass: "item3", selectedCssClass: "item3selected" } } });
js - png fix
http://jquery.andreaseberhard.de/pngFix/
denedim, fakat işe yaramadı =/
Etiketler: png fix
System.NotSupportedException: An attempt has been made to Attach or Add an entity that is not new, perhaps having been loaded from another DataContext
System.NotSupportedException: An attempt has been made to Attach or Add an entity that is not new, perhaps having been loaded from another DataContext. This is not supported.
You may have gotten this error when using LINQ to SQL. I personally hate this error, but surprisingly enough, out of 2 years of using LINQ to SQL, this is the first time I've gotten this (2 years later, I mean). This error happens in this scenario: imagine loading up an object Order. This object has a primary key relationship Customer, which you can access via:
Order.Customer
Under the scenes, the order class uses the EntityRef
order.Customer
This reference gets loaded from the context, using the value from CustomerKey. if you assign a new value to Order.CustomerKey as in:
order.CustomerKey = 3;
The LINQ entity notices that the Customer object (underlying EntityRef
order.Customer = this.DataContext.Customers.First(i => i.Key == 1);
You have to assign the reference to the Customer, and this instead updates the key, the reverse way around. I don't like this because this forces me to perform an additional data query, and in a business app this may reduce performance just to update a reference. I chose an alternate way. By adding a partial class for the order, I add a ClearCustomer method that does the following (note all LINQ types implement partial keyword, which means you can create another partial class to add additional methods).
public partial class Order ...
{
public void ClearCustomer()
{
_Customer = default(EntityRef
}
}
And now, calling this method before changing the assignment clears the customer, and I can make the change. A bit of a hack, but it works. Unfortunately, because again the EntityRef is internal to the class, the method has to be in the class definition (can't use a static helper class to do this, at least easily). To update the reference, I can now do:
order.ClearCustomer();
order.CustomerKey = 7;
http://dotnetslackers.com/Community/blogs/bmains/archive/2009/05/21/linq-to-sql-error-foreignkeyreferencealreadyhasvalueexception.aspx
Etiketler: ForeignKeyReferenceAlreadyHasValueException , insertonsubmit , linq
Serve extensionless URL without using ISAPI handler or wildcard mapping
Etiketler: extensionles , urlrewriting
The out parameter 'xxx' must be assigned to before control leaves
void myVoid (out string xxx)
{
if (...)
{
xxx = ....
return;
}
xxx = ""; // bu kısım olmadığında başlıktaki hata oluşuyor.
}
http://bytes.com/topic/net/answers/116772-url-rewriting-problems-postbacks
connectionstring by using web.config
< asp:SqlDataSource ID="SqlDataSource1" runat="server" ConnectionString=' < % $ ConnectionStrings:Main.ConnectionString % > '
SelectCommand="Select CategoryID, Title, UpperCategoryID From Category" / >
web.config:
< connectionStrings >
< add name="Main.ConnectionString" providerName="System.Data.SqlClient" connectionString="data source=pisipisi\sql2008; initial catalog=yapimatik; Trusted_Connection=yes" / >
< / connectionStrings>
Etiketler: connectionstring , sqldatasource , web.config
The changes you have made require the following tables to be dropped and re-created
When changing tables in SQL Server Management Studio 2008 you may get the following error: Saving changes is not permitted. The changes you have made require the following tables to be dropped and re-created. I was surprised when I saw this message first but there is very simple solution. From top menu select Tools and then Options. Select Designer and Table and Database Designers. Uncheck the box Prevent saving changes that require table re-creation. Now you can edit your tables without being stopped by re-creation limits. Update. As mxmissile pointed out in his comment then don't use this on tables with millions of rows.
Url Rewriting Breaks ASP.NET 2.0 Themes - HttpContext.ReWritePath - Screws Up Link to StyleSheet
I was neck deep into ASP.NET 2.0 Themes and Url Rewriting today when I came across the fact that Url Rewriting breaks your ASP.NET 2.0 Themes by changing the base file path looked at by the client and screwing up the relative URL to your stylesheets. Actually, I expected this to happen, but I didn't think the fix was going to be so simple.
Much thanks goes to Fabrice who I remembered blogged about this problem with Url Rewriting and ASP.NET 2.0 Themes the other day.
Turns out this problem with Url Rewriting and ASP.NET 2.0 Themes was reported to Microsoft and they created a new boolean parameter for HttpContext.RewritePath, called rebaseClientPath, that allows you to specify whether or not you want the virtual path reset when doing Url Rewriting.
public void RewritePath (string path, bool rebaseClientPath)
By default, rebaseClientPath is set to true, which is why the links to the stylesheets are broken. If you are doing Url Rewriting with ASP.NET 2.0 Themes and having problems with your stylesheets, change your code to set rebaseClientPath to false and it may fix your problem.
http://davidhayden.com/blog/dave/archive/2006/01/14/2693.aspx
Etiketler: css , rewritepath , urlrewriting