Hli Archives: Lub ob hlis ntuj 2008

Me pej xeem ntawv tshaj tawm: Qhov rais tej chaw nyob ruaj ntseg thiab chaw Contacting tswv

Kuv tau txais ib handful cov lus los ntawm tus neeg ntawm tus built-in "xa lus" nuj nqi Microsoft qhia nrog rau tej qhov chaw nyob (uas tseem hosts kuv blog) txhua txhua lub hli.

Ib feem peb ntawm lub sij hawm, cov neeg siv cov muaj ruaj lawv tus account nyob tej qhov chaw xws tias kuv teb tsis tau lus. Qhov no yog tej yam los tiv thaiv spam feature kuv xav tias.

</kawg>

Tej yam yooj yim piav: “Tus nqi tsis poob li ntawm txoj kev tsim kev khwv.”

HLOOV TSHIAB: Ib daim ntawv loj loj anonymous tshuav ib koob saib txog lub npe. Nco ntsoov nyeem nws.

Thaum ua hauj lwm nrog cov kev tshwm sim receivers thiab lwm yam cai references SharePoint daim ntawv teev khoom ntawm tus kwv qauv, Kuv yeej ua yuam kev uas ua kom muaj qhov yuam kev ntawm runtime:

Yuam kev chaw thau khoom thiab khiav cov kev tshwm sim receiver Conchango.xyzzyEventReceiver nyob xyzzy, Version = 1.0.0.0, Culture = nruab nrab, PublicKeyToken = 0dc50a750396c3ac. Xav paub ntxiv hauv qab no yog. : Tus nqi tsis poob tsis pub dhau lub expected ntau yam.

Kuv xav tias qhov no yog ib qho yuam kev lawm generic haum uas uas vim muaj ntau yam. Txawm li cas los, ib cov lus qhia yog tias kuv nyob referencing teb incorrectly. Yog hais tias lub teb lub npe yog "Hnub so", Kuv yuav tsum reference nws zoo li no nyob rau hauv ib qhov kev tshwm sim receiver:

zog.ListItem["Hnub"]

Thaum twg kuv misspell los siv rau rooj plaub no tsis ncaj ncees lawm thaum referencing lub teb, SharePoint generates cov saum no lum runtime yuam kev. Piv txwv, qhov no tsis yog lawm:

zog.ListItem["hnub"]

</kawg>

Subscribe rau kuv blog.

Ntawv cim npe Technorati:

Cov neeg siv kawg ntsis ceev: Tsi Views nyob rau hauv ib daim ntawv qiv, Sau, yam.

Peb yuav tau, yuav tsum tau thiab tsim views ntau nyob rau hauv SharePoint muaj npe (daim ntawv qiv, kev cai npe, yam). SharePoint yeej teev muaj views hais alphabetical. Peb yuav hloov tsis tau qhov no uas siv rau hauv lub thawv functionality. Yog hais tias nws yuav ua tau ntawm customization (thiab kuv tsis paub hais tias nws yuav), Nws yog kev mus deb rau koj cov neeg siv kawg raug.

Yog hais tias koj xav tswj tau qhov kev txiav txim nyob rau hauv cov SharePoint uas teev muaj views, cias prepend tus xov tooj los yog tsab ntawv mus rau tus saib npe, raws li nyob rau hauv:

1 – Los ntawm hom Material
2 – Tag nrho cov ntawv
3 – Hnub so

-los sis-

IB – Los ntawm hom Material
B – Tag nrho cov ntawv
C – Hnub so

Kuv kuj tsim nws lub hom phiaj yog nruj me ntsis mus noj ib KPI views. Kuv tau soj qab no naming convention:

Z_KPI_[hauj lwm lawm]

Uas ua rau cov "KPI kuv" views los tshwm sim rau daim ntawv hauv qab.

</kawg>

Subscribe rau kuv blog.

Ntawv cim npe Technorati: ,

Sunday Funny: “Thaum kuv muaj ib tug me tub”

Ib tug niam txiv, qhov chaw raws li cov kab kuv sab hauv "thaum kuv muaj ib tug me tub" ua kom yuam kev.

Kuv tus tub, tej zaum plaub los tsib lub sij hawm, ua si ib zais pa thiab tsis nyiam cov me tub hluas uas ua si nrog balloons, nws plaws tom. Nws chim heev. Lub ntiaj teb twb tuaj nto. Kuv hais rau nws, "thaum kuv muaj me tub, Kuv muaj ib tug zais pa thiab plaws tom nws thiab nws thiaj li, Kuv tau txais ib tug tshiab zais pa." Nws seemed kom pab nws khwv nws tsi paub daws thiab coj mus muaj kev lom zem nrog lawv tham txog dab tsi yog ib yam li thaum kuv muaj ib tug me tub.

Uas ua hauj lwm zoo raws li tus txheej txheem consolation thiab kuv siv ib ob peb zaug dhau lub sij hawm uas tom ntej. Kuv puas tau mus raug teeb meem ib zaug thaum nws dab Rancher 3 zeej tuag. Kuv tham txog kuv tus aub, Tub fuabtais, muaj tuag hauv tsheb sib tsoo. Lub sij hawm no, yog nws teb, "Tam sim no kuv hnov ob txog tej yam phem!" Kuv shied txhob siv cov "thaum kuv tus me tub" cov txheej txheem rau consolation tom qab ntawd.

Ua ntej cov dev tuag xwm, Txawm li cas los, Kuv yuav tsum tau pib siv tus txheej txheem convince nws ua haujlwm. "Thaum kuv muaj ib tug me tub, Kuv yuav tsum tau tawm rooj thiab txais cov ntawv xov xwm", "ntxuav kuv chav", "tau Mommy nws lub khob kas fes", yam.

Dhau qhov no zoo zoo nkauj ib pliag, tab sis, nws pib qhia rebel tiv thaiv tsis tau qhov tyranny ntawm kuv thaum yau. Kas, hauv particular, cim xaus. Kuv hais kom nws coj lub kaus poom khib nyiab ntawm teeb rov qab mus rau qhov chaw rau tsheb. Nws tau argued thiab kuv yeej teb, "Thaum kuv muaj ib tug me tub, Kuv yuav tsum tau nqa lub khib nyiab rov qab mus rau qhov chaw rau tsheb." Nws yeej teb, "Huag muaj! Zoo thaum koj tau ib tug me tub, uas yog STUPID!".

</kawg>

Subscribe rau kuv blog.

Ntawv cim npe Technorati:

Views thiab txhua rau npe thiab daim ntawv qiv tsis tau yuav ruaj

HLOOV TSHIAB (02/29/08): No yog ib qhov codeplex tshiab rau nkawd muab rau phiaj txhua tug: http://www.codeplex.com/SPListDisplaySetting. Yog hais tias koj muaj tej kev ua hauj lwm nrog nws, thov cia ib saib.

Rooj sab laj zog nquag hais ib lo lus nug li no: "Kuv muaj ib tug neeg saib xyuas pom thiab thiab tus neeg ua hauj lwm pom ntawm ib daim ntawv teev. Cas ua kuv luag cov neeg saib xyuas pom kom neeg ua hauj lwm yuav tsis siv nws?"

Lawv tseem pheej hais lwm yam lus nug: "Kuv xav kom muaj kev metadata sab kom tswj xwb tej zaum yuav txawv ntawd qhia kiag thaum lwm tus tsis txawm pom nws."

Cov lus teb hais txog leej WSS 3.0 thiab NTXHUAB:

  • SharePoint tsis muab qhov nyiaj them yug tawm-of-the-kem rau phiaj views.
  • SharePoint tsis muab qhov nyiaj them yug tawm-of-the-kem kev ruaj ntseg txhua.

Muaj ntau ntau hom kev kawm ib yuav ua raws li uas raws li tej yam kev ruaj ntseg yuav tsum. Ntawm no yog kuv yuav xav li cas txog:

  • Siv cov khoom tawm-ntawm-tus-kem theem ruaj ntseg. Ib txwm views tsim yam ruaj ntseg kawm configuration. Tej receivers thiab/los yog workflow yuav automate cov ntus ruaj ntseg.
  • Siv koj tus kheej views rau "privileged" views. Cov no yog cov yooj yim txaus teeb. Txawm li cas los, vim lawv "koj tus kheej" xwm, Cov no yuav tsum tau configured rau txhua tus neeg. Siv kev ruaj ntseg txheem configuration tiv thaiv leej twg los ntawm peb tus kheej saib.
  • Siv ib cov ntaub ntawv saib web feem thiab siv tej yam kev ruaj ntseg rau AJAXy trimming kua.
  • Dov rau koj daim ntawv teev zaub functionality thiab teeb ruaj ntseg trimming nyob sab.
  • Hloov cov ntaub ntawv cov ntaub ntawv nkag teb chaws thiab siv JavaScript tau nrog rau cov qauv ruaj kom muaj kev theem sab kev ruaj ntseg trimming.
  • Siv ib daim ntawv InfoPath rau cov ntaub ntawv nkag teb chaws. Kev ruaj ntseg kem duas trimming ntawm cov Web site qhov kev pab hu SharePoint thiab conditionally nkaum tom teb raws li xav tau.
  • Dov rau koj tus kheej ASP.NET tej ntaub ntawv nkag teb chaws muaj nuj nqi uas implements kem theem kev ruaj ntseg trimming.

Yog tsis muaj cov kev xaiv tiag tiag li yawm suab, tiamsis nws muaj tsawg kawg yog ib txog kev ua raws li yog hais tias koj xav tau, Txawm hais tias nws yog ib qho nyuaj.

CEEB TOOM: Yog hais tias koj nqes ib yam ntawm cov paths, tsis txhob hnov qab txog "kev-> Qhib cov qhov rais Explorer". Koj yuav tau nco ntsoov tias koj kuaj mob ntawd feature kom paub tseeb tias nws tsis ua hauj lwm raws li ib tug "qhov rooj nram qab" thiab defeat koj lub tswvyim ruaj ntseg.

Yog koj muaj lwm cov tswv yim rau los yog rua cov paub phiaj txhua los views, thov email rau kuv los yog tawm ib saib thiab kuv mam hloov no xo raws li tsim nyog.

</kawg>

Subscribe rau kuv blog.

Ntawv cim npe Technorati:

Nreeb taub: BDC ADF Version tooj yog koj cov phooj ywg

Yog koj nyob nraum tes-coding ADF ntaub ntawv thiab ua chaws/ntshuam/kuaj mus ntau ntau, siv tus xov tooj version yuav ua rau koj lub neej yooj yim.

Kuv yuav lees nws ntxub, tab sis, txog rau lub lim tiam no, Kuv twb yeej Hmong cov ADF thiab rov importing nws. Qhov no yuav tawg kuv ua lag ua luam cov ntaub ntawv txhua thiab ua rau kuv rov wire lawv. Tag nrho ruaj.

Daim ntawv no nyob rau hauv "yog cuab kev thaum koj pom nws".

Piv txwv:

<LobSystem
xmlns:xsi="http://www.w3.org/ 2001/XMLSchema-lom" xsi:schemaLocation="http://schemas.Microsoft.com/Office/2006/03/BusinessDataCatalog BDCMetadata.xsd" Hom="WebService" Version="1.2.0.0" Lub npe="xyzzyDocumentReview" xmlns="http://schemas.Microsoft.com/Office/2006/03/BusinessDataCatalog">

Tias version thiab rov import thiab ib lub lag luam cov ntaub ntawv sab siv kho tshiab cov version yeej uas tsis muaj ntxiv configuration yuav tsum tau hloov.

</kawg>

Subscribe rau kuv blog.

Ntawv cim npe Technorati:

Kua: BDC Picker qhia tau hais tias tsuas muaj ib sab ntawm lub ntsiab

Hauv kuv npaj siab rau mus ntawm kev muab ib pab tau ntau lookup sab siv BDC, Kuv ntaus ib phab ntsa nrog rau lub BDC picker. Yog hais tias koj tsis tau pom nws, cov BDC picker yog zoo li ib tug neeg picker tsuas tias nws ua haujlwm nrog rau txhua yam "lag luam cov ntaub ntawv".

Koj saib tau cov picker los txhaj rau lub icon qhib phau ntawv uas qhia tus lag luam cov ntaub ntawv kiag li:

duab

Cov duab saum toj no qhia tau hais tias ib lub lag luam cov ntaub ntawv kem hu ua "Tswv daim ntawv Id". Qhia kiag qhov txuas nrog, ntawm BDC, rau qhov Web site. Cov Web site qhov rov txhua ob lus: Daim ntawv ID thiab Title. Tus ua hauj lwm ntawm no yog muab ib "daim ntawv no yog xyuas los ntawm" muaj nuj nqi. Cov neeg siv xaiv ib tug "tswv" ntaub ntawv thiab thaum lawv tseg, ib qhov kev tshwm sim receiver copies meta liaj teb cov ntaub ntawv los ntawm tus tswv tsuav.

Los vim, cov BDC picker zoo li no thaum kuv nrhiav kom tau ib qho ntaub ntawv uas nws daim ID = "38":

clip_image002

Tus ntawd yog yuav pab tau, tab sis tsis zoo txaus. Neeg tsis xav saib raws tawm lawv tus ID, lawv xav hais tias ntawd lub npe thiab/los yog lwm yam ntaub ntawv meta. Tus picker no tso cai rau koj mus nrhiav tau rau ntawm lwm txhua (e.g. Npe) tab sis yuav tsis qhia tau tias daim ntawv ntawm lub npe uas nws pom tseeb, tos lawv DocId tus li no:

clip_image002[1]

(Txhaj tshuaj ntsuam tsis zoo li ntawd, vim kuv tsis de mus nrhiav rov rau tej kev ntsuam mhuv, tab sis koj pom tau tias yog nws tau pom ib co ntsiab, nws yuav tsuas pom tus DocId, tsis tau muaj lub npe).

High tsis nrhiav rau lo lus teb rau qhov no thiab ua tsis tau tejyam. Kuv colleague, lub venerable Jonathan Bradshaw, muaj muag thiab solved no qhov teeb meem. Thaum kuv mus txog nws tau kev pab, Nws taw kuv ua raws li siab xav.

Configure lub picker qhia ntau txhua ntawm "ShowInPicker cov" cov cuab yeej nyob hauv lub ADF:

<Khoom Lub npe="ShowInPicker" Hom="System.Boolean">tseeb</Khoom>

Nyob rau ntau yam:

  <!-- Npe -->
  <TypeDescriptor TypeName="System.String" Lub npe="Npe" >
    <LocalizedDisplayNames>
      <LocalizedDisplayName LCID="1033">Npe</LocalizedDisplayName>
    </LocalizedDisplayNames>
    <Khoom>
      <Khoom Lub npe="DisplayByDefault" Hom="System.Boolean">tseeb</Khoom>
      <Khoom Lub npe="ShowInPicker" Hom="System.Boolean">tseeb</Khoom>
    </Khoom>
  </TypeDescriptor>

Teev cov cuab yeej no ua kom paub cov teeb meem me. Thaum koj teev nws ib zaug, koj yuav tsum muab tso rau txhua sab koj yuav tau qhia. Hauv kuv tsev neeg, BDC picker tsom DocId yog vim. Txawm li cas los, ib zaug kuv ntxiv "ShowInPicker" rau npe, DocId tsis tso tawm kom pom. Kuv solved uas los ntawm ntsees teev cov cuab yeej ShowInPicker rau Doc ID.

Ntawm no yog cov:

duab

(Kuv mam li piav qhov odd-looking "168 – CamlSchema.xsd" siv hauv lub tsev xa blog yav tom ntej. Hauv ntej, Nws yog ib txoj hlua concatenated pub rau cov neeg siv kev zoo me ntsis).

tau mas, daim ntawv no qhov nkag teb chaws blog, Kuv cia li tsis nrhiav ib tug "ShowInPicker" ua heev heev hits, xws li cov no ib: http://msdn2.microsoft.com/en-us/library/ms583986.aspx. Nws qhia txog lub ntsiab ntawm qhov cuab yeej nrog rau ib co lwm zoo BDC khoom.

</kawg>

Subscribe rau kuv blog!

Ntawv cim npe Technorati:

Ceev & Yooj yim: Tsim ib tug ntawv tais ceev tseg thiab cob ib txheej yam (Los sis, Muaj koj KPIs thiab cov noj tau thiab)

Yuav kom ua num nyob ib ncig ntawm qhov teeb meem KPI Kuv thiaj sau txog no, Kuv puas tau ib co los soj ntsuam thiab sab ntawd KPI ua hauj lwm rau cov folders uas muaj ntaub ntawv meta tib hais tias lawv ua hauj lwm cov ntaub ntawv los teev. Kuv proved nws tawm los ntawm txoj kev kom cov ib yam tshiab nyob rau hauv daim nplaub tshev cov hom thiab ntxiv ob peb teb. Kuv tsim ib co indicators, As thiab proved rau kuv tus kheej tias KPIs ua hauj lwm raws li tau leej twg. Qhov no yog xov xwm txais tos. Yog tsis zoo meej, vim cov laum-down koj tau los ntawm lub KPI tiv thaiv cov folders yog tsis raws nraim koj xav li cas. Qhov no tsis yog noj ntau dhau ib drawback hauv kuv tsev neeg vim 1) rau cov neeg siv tag tsis paub lus zoo thiab 2) laum-down mus rau ib lub tais ceev tseg. Lawv nias lub nplaub tshev Npe thiab nyob rau tom qhov khoom. Nws yog ob tug clicks txhob siv ib tug, uas tsis yog rau thaum xaus rau lub ntiaj teb no.

Qhov no ntws ntawm nicely nrog cov ua hauj lwm uas kuv tau ua. Kuv yuav tsim ib tug ntawv tais ceev tseg rau txhua daim ntawv uas tau txais uploaded. Qhov no yog ua li cas rau ntawm ib qho kev tshwm sim receiver. Yog li ntawd, Nws yog ib daim ntawm ncuav mog qab zib kom txhob muaj qhov niam txiv sis meta cov ntaub ntawv nyob rau hauv cov sync uas muaj cov ntaub ntawv meta KPI-uas tau tsav ntawv xwb vim cov kais dej yog twb nyob rau hauv qhov chaw. Qhov no tso cai rau kuv muaj kuv tus KPI thiab yuav noj tau ib yam nkaus thiab 🙂

Cov kev tshwm sim receiver ntxiv lub sis thiab ces koj muab no nplaub tshev tus tshiab cov hom los kuv kev cai KPI hauv chav ntawv kawm yam hloov kuv. Chaws no me ntsis puas tau qhov ua kom yuam kev:

 SPFolderCollection srcFolders = targetWeb.GetFolder("Cov ntaub ntawv").SubFolders;
  SPFolder addedFolder = srcFolders.Add(zog.ListItem.ID.ToString());
  SPContentTypeId kpiCT = tshiab SPContentTypeId("0x0120002A666CAA9176DC4AA8CBAA9DC6B4039F");
  addedFolder.Item["Cov hom ID"] = kpiCT;
  addedFolder.Item.Update();

Los nrhiav lub txoos cov hom ID, Accessed ntawd hom kawm ntawd ntawm qhov chaw thiab luam/Document nws los ntawm qhov URL li:

duab

</kawg>

Subscribe rau kuv blog!

Ntawv cim npe Technorati: ,

Txoj kev sai thiab yooj yim: Tau qhov SPFolder ntawm kev SPListItem nyob hauv ib lub Receiver Event

Kuv yuav lees nws ntxub, tab sis kuv struggled nrog no ib txhua hnub. Kuv caij receiver kev hloov ntawm cov niam txiv sis teb. Qhov no tshuav me me qhia tau hais tias yuav ua li cas:

lwm yam khoob lug UpdateParentFolder(SPItemEventProperties khoom)
{

SPFolder thisItemFolder = zog.ListItem.File.ParentFolder;
thisItemFolder.Item["ZZ pom zoo lawv"] = "Xov zoo, sawv daws!";
thisItemFolder.Item.Update();


} // UpdateParentFolder

Qhov no, Kuv tabtom ua hauj lwm nrog rau ib daim ntawv qiv ntawv thiab cov khoom los yog ib qho kev tshwm sim hauv ItemAdded.

Qhov ua kom yuam kev yog tias tsis tau qhov SPFolder ntawm yam khoom no ntawm yam khoom no xwb (i.e. zog.Yog thov ListItem.Folder). Xwb, mus saib daim ntawv teev khoom txoj kab ntaub ntawv thiab muab cov ntaub ntawv ceev.

</kawg>

Subscribe rau kuv blog!

Ntawv cim npe Technorati:

Tsis tau lwm yam kev tshwm sim Receiver Debug ua kom yuam kev

Kuv kom kuv kuj tsis yog thawj tug neeg tuaj txog qhov nov. Txawm li cas los, Kuv tsis pom leej twg luam tawm tsab ib ua kom yuam kev li no vim kuv pib hmoog kaw rau lub zej zog lub Xya Hli Ntuj tas los no. Li ntawd, Kuv xav tias kuv yuav tswg nws no lub taub debug txoj kev sai thiab yooj yim.

Kuv tabtom ua hauj lwm rau hauv ib qho kev tshwm sim receiver uas pib Meskas no yuam kev hauv lub 12 nas muv:

Yuam kev chaw thau khoom thiab khiav cov kev tshwm sim receiver Conchango.xyzzyEventReceiver nyob xyzzy, Version = 1.0.0.0, Culture = nruab nrab, PublicKeyToken = blahbalhbalh. Xav paub ntxiv hauv qab no yog. : Kwv siv tsis tau teem rau kev lom los ntawm ib tug kwv.

Kuv tsis paub qhov twg kuv twb nkag tau no tiam sis vim kuv tau ua ntau yam hauv ib qhov ntawm kuv qhov chaws/deploy/kuaj mus.

Kuv sim cov tshuaj no tau txais kuv cov pdb nyob rau ntawd nrog hopes ntawd SharePoint 12 nas muv yuav qhia rau cov pawg ib txoj lw, tab sis tsis muaj hmoo. Kuv tsis paub tias yog tau thiab yog hais tias ib tug neeg twg, thov qhia rau kuv paub 🙂

Kuv paub tias nws puas yuav tau mus sau ntawv rau koj tus kheej mus sib cav ntawm 12 nas muv. Frankly, Kuv xav tej yam tsawg me ntsis scary thiab kom muaj kev cuam sai.

Nws pom kuv tias kuv kawg tau ib cov lus sau ib txoj lw los tuag thiab rov ntuav generic ntxiv li no:

  ua tiag {
    UpdateEditionDate(khoom);
  }
  ntes (Kos e)
  {
    pov tshiab Kos("Dispatcher, UpdateEditionDate(): Kos: [" + e.ToString() + "].");
  }

Qhov no kuj nyob hauv lub 12 hive thusly:

Yuam kev chaw thau khoom thiab khiav cov kev tshwm sim receiver Conchango.xyzzyEventReceiver nyob xyzzy, Version = 1.0.0.0, Culture = nruab nrab, PublicKeyToken = blahblahblah. Xav paub ntxiv hauv qab no yog. : Dispatcher, UpdateEditionDate(): Kos: [System.NullReferenceException: Kwv siv tsis tau teem rau kev lom los ntawm ib tug kwv. tom Conchango.xyzzyManagementEventReceiver.UpdateEditionDate(SPItemEventProperties zog) tom Conchango.xyzzyManagementEventReceiver.Dispatcher(SPItemEventProperties zog, Txoj hlua eventDescription)].

Uas tau muab kuv nthuav dav kuv tau teev cia tias xyov qhov teeb meem thiab kuv cia siab tias yuav siv heev mus rau pem hauv ntej.

</kawg>

Subscribe rau kuv blog!

Ntawv cim npe Technorati: ,