วิธีแก้ปัญหา Macbook เกิดปัญหา Wi-Fi อยู่ดีๆหาย แจ้งว่า no hardware installed
Macbook เกิดปัญหา Wi-Fi อยู่ดีๆหายแจ้งว่า no hardware installed วิธีแก้ดังนี้
เปิด Terminal ของ Mac ขึ้นมา
หลังจากนั้นพิมพ์ sudo rm -f /var/vm/sleepimage ถ้ามันให้ใส่ password ก็ใส่ password เขาเครื่องลงไป
หลังจากนั้นให้กดปุ่ม Power button ค้างไว้และเลือก shutdown ถ้ามันถามให้ตกลงก็กดตกลงไปมันจะเตือนเรื่องการเปลี่ยนแปลงค่า config
ส่วนวิธีการแก้ไขปัญหาอื่นๆสามารถอ่านได้จากที่นี่ https://discussions.apple.com/thread/3210949?start=75
Photoshop CS6 Shortcut Key for Mac
windows->workspace->Reset Essential ทำให้ panel ด้านขวากลับมา
command & + – เป็นการ Zoom In/Out
command & 0 เป็นการดูเต็มภาพ
command & 1
command & Spacebar จะเป็นรูปมือสำหรับเลื่อนภาพ
command & delete เทสี background
command & z คือ undo ย้อนกลับได้ 1 ครั้ง
command & alt & z จะย้อนกลับได้ไม่เกิน 20 ครั้ง
command & shift z จะไปข้างหน้า
command & j เป็นการ copy layer
command & d ยกเลิก selection
command & g เป็นการ group layer
command & shift & g เป็นการ ungroup
alt & delete เทสี foreground
Tab เปิดปิด tool
Shift+Tab ปิด Panel ด้านขวา
รูปแว่นด้านซ้ายเมื่อคลิ้กแล้วจะเป็นการ zoom จะต้องเอา Scrubby Zoom ออก แล้วจะลากแบบ Select แล้วมันจะ zoom ตรงที่เลือกได้
กด x จะเป็นการสลับสี foreground/background
เว็บสำหรับแต่งสี
colorlovers.com
kuler.adobe.com
subtlepatterns.com
ตัว kuler สามารถเลือกได้จาก menu window->extension->kuler
เรื่องของ Selection
เวลาเลือก selection กด alt ค้างไว้มันจะวาดจากลางวัตถุ
selection เมื่อกด shift ค้างแล้ววาดไปจะวาดจัตุรัส
ถ้าวาด selection ไปแล้วเมื่อกด shift จะวาดเพิ่มได้ จะเป็นเหมือน + selection
ถ้าวาด selection ไปแล้วกด alt จะเป็นการลบ selection เอาไว้วาดพระจันทร์ได้เช่นวาดวงกลมสองวง
ใช้ Magic wand tool เวลาเลือก selection ให้ปรับ Tolerance สัก 100มันจะเลือกสีใกล้เคียง
ใช้ Quick Selection tool ง่ายสุดสามารถปรับแปรงได้
menu filter->convert smart filter จะเป็นการ convert selection ภาพที่เลือกเป็น smart object ข้อดีคือเมื่อย่อขยายจะไม่แตก และเมื่อกด alt & move tool จะสร้าง layer ใหม่ด้วยการ copy ให้
การหมุน free transform
distrot เอาไว้ปรับมุมเช่นเอารูปหน้าคนหน้าบานมาใส่หน้าเรียว
Perspective ทำพวกแสงเงาจากด้านหลังได้ เช่นไฟส่องจากด้านหลังด้านหน้าเงาสาดส่องมา
คลิ้กขวาหลังชื่อหลัง Layer จะมี Lasterize Layer จะเป็นการเอา effect ทุกอย่างที่ติดมากับ Layer ออกเช่นการ convert smart object
โซ่ลิงค์ขวาล่างจะเลือก Layer ให้ไปด้วยกันทั้ง move free transform
download brush
http://www.brusheezy.com/
ทำ brush เองได้จากเมนู Edit define brush preset
Devexpress ASPxComboBox add item in code behind
ตัวอย่างการทำ combobox ให้ดึงข้อมูลจาก datasource และ add new item ลงไปด้วยในส่วน code behind
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 |
<%@ Page Language="C#" AutoEventWireup="true" CodeFile="Default.aspx.cs" Inherits="_Default" %> <%@ Register Assembly="DevExpress.Web.ASPxEditors.v12.1, Version=12.1.6.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" Namespace="DevExpress.Web.ASPxEditors" TagPrefix="dx" %> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head runat="server"> <title>ASPxComboBox: Add an item to the ItemCollection after data-bound and perform custom client-side validation</title> </head> <body> <form id="form1" runat="server"> <div> <table class="style1"> <tr> <td> <strong>Products:</strong></td> </tr> <tr> <td> <dx:ASPxComboBox ID="cmbox" runat="server" ClientInstanceName="cmbox" TextField="ProductName" ValueField="ProductID" DataSourceID="AccessDataSource1" ondatabound="cmbox_DataBound"> <ClientSideEvents Validation="function(s, e) { if (s.GetSelectedIndex()==0) { e.isValid = false; e.errorText = "You should Select One of the Products"; } }" /> <ValidationSettings ValidateOnLeave="False"> </ValidationSettings> </dx:ASPxComboBox> </td> </tr> <tr> <td> <dx:ASPxButton ID="btn" runat="server" AutoPostBack="False" ClientInstanceName="btn" Text="Validate"> <ClientSideEvents Click="function(s, e) { cmbox.Validate(); }" /> </dx:ASPxButton> </td> </tr> </table> </div> <asp:AccessDataSource ID="AccessDataSource1" runat="server" DataFile="~/App_Data/Northwind.mdb" SelectCommand="SELECT [ProductID], [ProductName] FROM [Products]"></asp:AccessDataSource> </form> </body> </html> |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 |
using System; using System.Collections.Generic; using System.Linq; using System.Web; using System.Web.UI; using System.Web.UI.WebControls; using DevExpress.Web.ASPxEditors; public partial class _Default : System.Web.UI.Page { protected void cmbox_DataBound(object sender, EventArgs e) { ListEditItem defaultItem = new ListEditItem("------Select One------------", -1); cmbox.Items.Insert(0, defaultItem); cmbox.SelectedIndex = 0; } } |
สำหรับตัวอย่าง Add Month , Year ใน Combobox
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 |
int j = 0; for (int i = 2556; i <= Convert.ToInt16(DateTime.Now.ToString("yyyy", CultureInfo.GetCultureInfo("th-TH"))); i++) { ListEditItem defaultItem = new ListEditItem(i.ToString(), i); cbbYear.Items.Insert(j, defaultItem); cbbYear.SelectedIndex = j; j++; } // Get the en-US culture. CultureInfo ci = new CultureInfo("th-TH"); // Get the DateTimeFormatInfo for the en-US culture. DateTimeFormatInfo dtfi = ci.DateTimeFormat; int jMonth = 0; foreach (string name in dtfi.MonthGenitiveNames) { ListEditItem defaultItem = new ListEditItem(name, (jMonth+1)); cbbMonth.Items.Insert(jMonth, defaultItem); cbbMonth.SelectedIndex = 0; jMonth++; } |
Recent Comments