Monthly Archives: Nóvember 2007

Moss segir mér dálkheiti mín er áskilin eða við notkun … En það er ekki

UPDATE 12/04/07: Sjá þetta Microsoft KB (http://support.microsoft.com/kb/923589) fyrir frekari upplýsingar.

Reyndar, það kemur í ljós að það er, en tricksy MOSS þurfti að gera það erfitt.

My customer does some development work on his MOSS site over the weekend. It’s a bit of a jumble as to what he actually did, en niðurstaðan er þessi:

  • He tries to add a site column called "Quantity" og mosi Svör: "The column name that you entered is already in use or reserved. Choose another name."
  • He attempts to add it to another environment and that works. Því, "Quantity" er ekki frátekið heiti.
  • He tries to find an existing site column named "Quantity" in that site collection. He cannot find it.

Ég gerði nokkrar rannsóknir, and even some coding, efldist heimspeki og að lokum komist að því að dálkinum Magn en, í raun, exist. It was in the "_Hidden" group. Hence, við gátum ekki fundið það í gegnum SharePoint notendaviðmót.

Hvernig var það fá það? I do not know, en ég hef kenningu (eða eins og konan mín myndi kalla það, "blah blah blah"). Einhvers staðar meðfram línu, a stórkostlegur fjörutíu sniðmát was added and probably activated at a site in the site collection. It was then deactivated (eða staður fjarri). The site column, þó, remained but in the "_Hidden" group. If someone knows better, vinsamlegast láttu mig vita með netfang eða staða í athugasemdum.

SharePoint was telling the truth. It’s hardly worth pointing out that that message is not as helpful as it could be. It would be nice to see that message fork into two different messages in the future: 1) Segja að dálkur heiti er frátekið eða það er ekki. 2) Ef það er ekki áskilinn, sýna síðuna, eða að minnsta kosti að hópurinn, þar sem dálkurinn nafn er þegar í notkun.

</enda>

OM Núverandi gögn með Custom List (eða, Enn ein OM Gögn Displayor [eins Yacc, en mismunandi])

Í dag, I spent a handful of hours tracking down the root cause behind the message "The column name that you entered is already in use or reserved. Choose another name."

Súlan í viðkomandi gæti skapað, eytt og aftur búið í öðru umhverfi, so I knew it wasn’t a reserved name. Hins, I simply couldn’t find the column anywhere via the standard SharePoint user interface at any site in the site collection.

I posted to MSDN forums here and the indomitable Andrew Woodward pointed me in the direction of the underlying object model data.

I went off to codeplex to find some tools that would help me peer into the underlying OM data and help me locate the trouble.

I tried several tools and they were very cool and interesting but in the end, the UI wasn’t good enough for my purpose. I’m not criticizing them by any means, but clearly the tool-makers didn’t have my problem in mind when they created their UI :). Most people seem to be investing a fair amount of time and effort in creating workstation / client applications that provide tree views, right-click context menus and so forth. These are nice and all, but it’s a lot of work to create a top-of-the-line user experience that is also very flexible.

I really needed an answer to this problem. It occurred to me that if I could get all of the site columns in the site collection into a custom list, I could filter, sort and create views that would help me find this supposedly existing column (which it did, BTW). I went ahead and did that and an hour or two later, had all my site columns loaded into a custom list with grouping, sorting and so forth. I found my answer five minutes later.

If and when I successfully take over the world, I think I will decree that all SharePoint tools providers must seriously consider surfacing their object model data in a custom list. That way, I have the power to search any way I want (constrained, auðvitað, by standard sharepoint features).

SharePoint Designer Vinnuflæði Custom Action — Athugun Um <Field Tie Hönnuður Gerð =”StringBuilder” … />

Bara fljótur athugun að það er mjög mikilvægur munur á milli þessara tveggja skilgreininga:

<FieldBind Field = "InParam1" Hönnuður type = "String Builder" Id = "2" Texti = "Inntak breytu # 1" />

á móti:

<FieldBind Field = "InParam1" Id = "2" Texti = "Inntak breytu # 1" />

Fyrstu sýnir eins og þetta í SPD:

mynd

á meðan hið síðarnefnda sýnir svona:

mynd

I’m not sure how helpful these screen shots are but I put in the effort to make them so you have to view them 🙂

Athugun er þetta: StringBuilder gerir þér kleift að byggja upp band (augljóslega) með því að blanda saman band literals og workflow gögn (via the "Add Lookup" hnappinn í neðra vinstra horninu). When you use the Add Lookup button, it inserts a token in the form "[%tákn%]". When SharePoint invokes your custom action, (C # kóða í mínu tilfelli), SharePoint fer táknið sjálft, not the value of the token. If you use the default designer type (The second tegund), SharePoint stækkar táknið og fer raunverulegt verðmæti skapi til aðgerða þína.

StringBuilder = BAD, sjálfgefið hönnuður type = GOOD.

Auðvitað, that’s not what I really mean. Just don’t try and pass a parameter to your custom action when the designer type = StringBuilder. Use the default designer type and chain a StringBuilder to it up front if you need to build complex strings in your workflow (sem er tilviljun nákvæmlega hvað maður gerir til að búa til öflugt efni fyrir email aðgerð, en það er fyrirsögn á annan bloggfærslu, Har Har).

<endir />

Ótímabær Vinnuflæði Virkjun — A Non-læknis Lausn

UPDATE: Sjá þessa MSDN umræðu, sérstaklega síðustu færslu: http://forums.microsoft.com/MSDN/showpost.aspx?postid=2631057&siteid=1. It describes a condition that may short circuit this whole thing. In short, það getur verið eins einfalt og að minnsta kosti eitt af þeim sviðum sem nauðsynlegur.

Ég er með skjal bókasafn sem styður átta tegundir efnis.

I have a SharePoint Designer workflow that wants to calculate and assign a "reminder date" með því einfaldlega að draga 30 dagar frá öðrum dálki, "due date". This should only happen for one of the content types, "Insurance". The business objective is to produce a KPI that shows two categories of insurance documents: "about to expire" and "expired." (Þú getur lesið meira um þessa tegund af KPI og umfangsmeiri bora niður hér).

I have configured the workflow to fire when a new item is created and when an item is modified. The idea is that when an insurance document is uploaded, we calculate a "warning date" based on the expiration date. A pair of views work in connection with a KPI List to highlight these conditions when users hit their home page.

Þessi stefna virkar ekki þegar ég hlaða skjal.

I upload the document and I am presented with the meta data entry screen. Á þessum tímapunkti, I’m already in trouble. SharePoint has already, snemma frá sjónarhóli mínum, fired the workflow. I haven’t had a chance to pick the correct content type nor assign a due date. Á sama tíma, the workflow does not fire when I hit the submit button at this time. There’s some built-in logic that "believes" that first submit is part of the "create" event. Svo … workflow minn hefur rekinn og þegar hann framkvæma, it was passed default meta data values.

The best work-around I know of is to insert a "pause until" activity in the workflow. I have the workflow pause for 1 minute. While it’s pausing, Ég velja rétta gerð efnis, enter the meta data and submit. The pause completes and the workflow proceeds as needed. (Athugið að í umhverfi mínu, timer workflow activities from SPD do not work out of the box. You may have the same trouble. Sjá hér fyrir frekari upplýsingar).

I don’t like "magic delay" work-around. What happens if the user uploads a document and the phone rings and the ensuing conversation outlasts the pause? I can make the pause longer, en ég samt líkar það ekki.

Ég skrifaði um þetta á MSDN málþing hér: http://forums.microsoft.com/MSDN/ShowPost.aspx?PostID=2430725&SiteID=1

SharePoint Öryggi Undirstöðuatriði grunnur / Forðastu Common gildra

UPDATE 12/18/07: Sjá grein Paul Liebrand fyrir nokkrum tæknilegum afleiðingum að fjarlægja eða breyta þeim sjálfgefið nöfn (sjá athugasemd hans hér að neðan og).

Yfirlit:

SharePoint security is easy to configure and manage. Hins, it has proven to be difficult for some first-time administrators to really wrap their hands around it. Not only that, I have seen some administrators come to a perfect understanding on Monday only to have lost it by Friday because they didn’t have to do any configuration in the intervening time. (I admit to having this problem myself). This blog entry hopefully provides a useful SharePoint security primer and points towards some security configuration best practices.

Important Note:

This description is based on out of the box SharePoint security. My personal experience is oriented around MOSS so there may be some MOSS specific stuff here, but I believe it’s accurate for WSS. I hope that anyone seeing any errors or omissions will point that out in comments or email mig. I’ll make corrections post haste.

Fundamentals:

For the purposes of this overview, there are four fundamental aspects to security: users/groups, securable objects, permission levels and inheritance.

Users and Groups break down to:

  • Individual users: Pulled from active directory or created directly in SharePoint.
  • Groups: Mapped directly from active directory or created in SharePoint. Groups are a collection of users. Groups are global in a site collection. They are never "tied" to a specific securable object.

Securable objects break down to at least:

  • Sites
  • Document libraries
  • Individual items in lists and document libraries
  • Folders
  • Various BDC settings.

There other securable objects, but you get the picture.

Permission levels: A bundle of granular / low level access rights that include such things as create/read/delete entries in lists.

Inheritance: By default entities inherit security settings from their containing object. Sub-sites inherit permission from their parent. Document libraries inherit from their site. So on and so forth.

Users and groups relate to securable objects via permission levels and inheritance.

The Most Important Security Rules To Understand, Alltaf 🙂 :

  1. Groups are simply collections of users.
  2. Groups are global within a site collection (i.e. there is no such thing as a group defined at a site level).
  3. Group name not withstanding, groups do not, in and of themselves, have any particular level of security.
  4. Groups have security in the context of a specific securable object.
  5. You may assign different permission levels to the same group for every securable object.
  6. Web application policies trump all of this (see below).

Security administrators lost in a sea of group and user listings can always rely on these axioms to manage and understand their security configuration.

Common Pitfalls:

  • Group names falsely imply permission: Út af the kassi, SharePoint defines a set of groups whose names imply an inherent level of security. Consider the group "Contributor". One unfamiliar with SharePoint security may well look at that name and assume that any member of that group can "contribute" to any site/list/library in the portal. That may be true but not because the group’s name happens to be "contributor". This is only true out of the box because the group has been provided a permission level that enables them to add/edit/delete content at the root site. Through inheritance, the "contributors" group may also add/edit/delete content at every sub-site. One can "break" the inheritance chain and change the permission level of a sub-site such that members of the so-called "Contributor" group cannot contribute at all, but only read (til dæmis). This would not be a good idea, augljóslega, since it would be very confusing.
  • Groups are not defined at a site level. It’s easy to be confused by the user interface. Microsoft provides a convenient link to user/group management via every site’s "People and Groups" hlekkur. It’s easy to believe that when I’m at site "xyzzy" and I create a group through xyzzy’s People and Groups link that I’ve just created a group that only exists at xyzzy. That is not the case. I’ve actually created a group for the whole site collection.
  • Groups membership does not vary by site (i.e. it is the same everywhere the group is used): Consider the group "Owner" and two sites, "HR" and "Logistics". It would be normal to think that two separate individuals would own those sites — an HR owner and a Logistics owner. The user interface makes it easy for a security administrator to mishandle this scenario. If I didn’t know better, I might access the People and Groups links via the HR site, select the "Owners" group and add my HR owner to that group. A month later, Logistics comes on line. I access People and Groups from the Logistics site, add pull up the "Owners" group. I see the HR owner there and remove her, thinking that I’m removing her from Owners at the Logistics site. Í raun, I’m removing her from the global Owners group. Hilarity ensues.
  • Failing to name groups based on specific role: The "Approvers" group is a perfect example. What can members of this group approve? Where can they approve it? Do I really want people Logistics department to be able to approve HR documents? Of course not. Always name groups based on their role within the organization. This will reduce the risk that the group is assigned an inappropriate permission level for a particular securable object. Name groups based on their intended role. In the previous HR/Logistics scenario, I should have created two new groups: "HR Owners" and "Logistics Owners" and assign sensible permission levels for each and the minimum amount required for those users to do their job.

Other Useful References:

If you’ve made it this far:

Please let me know your thoughts via the comments or email me. If you know other good references, please do the same!

Technorati Tags:

Fljótur og Þægilegur: Búa til Data View Web Part (DVWP)

Það er mikið af mikill upplýsingar á WSS 3.0 Gögn Skoða Web Part (DVWP) on the web from several sources. Hins, I found it to be surprisingly difficult to find information on this first very basic step. Here is another article in the "quick and easy" röð til að takast það.

Follow these steps to create a data view web part (DVWP). They are based on an "Announcements" web part, but apply to most lists.

  1. Create an Announcements web part and add it to a site.
  2. Open the site in SharePoint Designer.
  3. Open the site’s default.aspx.
  4. Select the Announcements web part and right-click.
  5. From the context menu, select "Convert to XSLT Data View".

SharePoint Designer notifies you that this site is now customized from its site definition. That’s not necessarily bad, but there are important implications (performance, upgrade, aðrir) which are beyond the scope of this little "Quick and Easy" færslu. To get more information on this subject, I recommend both books hér as well as your favorite Internet search.

Confirm that you did it correctly:

  1. Close and re-open the web browser (to avoid accidentally re-posting the original "add a new web part").
  2. Select the web part’s arrow drop-down and choose "Modify Shared Web Part" from the menu.
  3. The tool panel opens to the right.
  4. The panel has changed from its usual set options to this:
mynd

“Get ekki fá stefið lista dálki eign af SharePoint listi” — lýsing / vinna-arounds

Í þessari viku, við afrita loks vandamál sem hafði verið greint frá a fjarlægur notandi: Þegar hún reyndi að flytja efni af lista til að skara fram úr, það virðist að byrja að vinna, en þá Excel myndi skjóta upp villa: "Cannot get the list schema column property from the SharePoint list". She was running office 2003, windows XP and connecting to MOSS.

I searched the Internets and saw some speculation but nothing 100% definitive. Hence, þessa færslu.

The problem: Exporting a view to excel that contains a date (date = the data type of the column).

What worked for us: Convert the date to a "single line of text". Þá, convert it back to a date.

That solved it. It was nice to see that the conversion worked, actually. It was quite nervous that converting things this way would fail, but it did not.

This bug has thrown a huge shadow over the date data type in the client’s mind, so we’re going to be seeking out a definitive answer from Microsoft and hopefully I’ll post and update here in the next short period of time with their official answer and hotfix information.

Other references:

http://www.kevincornwell.com/blog/index.php/cannot-get-the-list-schema-column-property-from-the-sharepoint-list/

http://forums.microsoft.com/MSDN/ShowPost.aspx?PostID=2383611&SiteID=1

<enda>

Gerast áskrifandi að bloggið mitt.

Technorati Tags: ,

Fljótleg og einföld: Senda tölvupóst með embed in tengil frá SharePoint Designer workflow

Einu sinni eða tvisvar mánuði, einhver innlegg vettvangur spurning: "Hvernig bæti ég tengla á URL sem eru smella af SharePoint Designer tölvupósti?"

Kynnt án frekari athugasemda: (vel, raun það er frekar athugasemd eftir myndina):

mynd

Becky Isserman fylgir með gagnlegar skýringar á hvernig á að embed in tengil á hlut í tölvupósti: http://www.sharepointblogs.com/mosslover/archive/2007/11/20/addition-to-paul-galvin-s-post-about-sending-an-e-mail-with-hyperlinks-in-spd.aspx

Ný útgáfa: SharePoint Designer vinnuflæðisreglum Eftirnafn (band meðferð aðgerðir)

UPDATE: Sjá hér fyrir hugsunum mínum á commercializing þetta verkefni: http://paulgalvin.spaces.live.com/blog/cns!1CC1EDB3DAA9B8AA!569.entry

Ég hef verið upptekinn að vinna á Codeplex verkefninu mínu sem er nú áherslu á að veita band handfjöllun eftirnafn til workflows búin með SharePoint Designer.

Sjá hér fyrir nánari upplýsingar:

Heimasíða verkefnisins: http://www.codeplex.com/spdwfextensions

Slepptu: https://www.codeplex.com/Release/ProjectReleases.aspx?ProjectName=spdwfextensions&ReleaseId=8280

Útgáfa 1.0 felur í sér eftirfarandi nýjar aðgerðir:

Virka Lýsing (ef ekki sama og. Hreinar virka)
NUM-færslur() Skilar fjölda "færslur" in a string as per a specified delimiter.

Til dæmis: Num-entries in a string "a,B,c" with delimiter "," = 3.

Entry() Returns the nth token in a string as per a specified delimiter.
Lengd String.Length
Skipta() String.Replace()
Inniheldur() String.Contains()
Returns the word "true" or the word "false".
Hlutstreng(byrja) String.Substring(byrja)
Hlutstreng(byrja,lengd) String.Substring(byrja,lengd)
ToUpper() String.ToUpper()
ToLower() String.ToLower()
StartsWith() String.StartsWith()
Returns the word "true" or the word "false".
EndsWith() String.EndsWith()
Returns the word "true" or the word "false".

A BDC afturkreistingur villa útskýrt

Ég olli BDC villa í þessari viku sem fram sig á notendaviðmóti og í 12 Hive þig á afturkreistingur.

Fyrsta, Þetta birtist í the notandi tengi:

Gat ekki fundið reiti til að setja inn allar kennimerki Values ​​að rétt framkvæma SpecificFinder MethodInstance með nafni … Tryggja inntak breytur hafa TypeDescriptors tengslum við hvert Identifier skilgreind fyrir þessa aðila.

Hér er skjámynd:

clip_image001

Ég gæti einnig valdið þessi skilaboð að birtast í 12 Hive þig á vilja (using my patented high-tech-don’t-try-this-at-home "mysterious errors" aðferð):

11/14/2007 09:24:41.27 w3wp.exe (0x080C) 0x0B8C SharePoint Portal Server Business Data 6q4x High Exception in BusinessDataWebPart.OnPreRender: System.InvalidOperationException: The Identifier gildi ”, tegund í ”, er ógild. Expected Identifier value of Type ‘System.String’. á Microsoft.Office.Server.ApplicationRegistry.MetadataModel.Entity.FindSpecific(Object[] subIdentifierValues, LobSystemInstance lobSystemInstance) á Microsoft.SharePoint.Portal.WebControls.BdcClientUtil.FindEntity(Heild aðila, Object[] userValues, LobSystemInstance lobSystemInstance) á Microsoft.SharePoint.Portal.WebControls.BusinessDataItemBuilder.GetEntityInstance(Skoða desiredView) á Microsoft.SharePoint.Portal.WebControls.BusinessDataDetailsWebPart.GetEntityInstance() á Microsoft.SharePoint.Portal.WebControls.BusinessDataDetailsWebPart.SetDataSourceProperties()

Ég leitaði í kring og fann nokkrar leiðir í MSDN Forum, but they weren’t enough for me to understand what I was doing wrong. I watched a webcast by Ted Pattison að minn fyrirtæki hefur squirreled burt á netþjóni og kom að átta vandamál mitt.

Í ADF minn, Ég er að tengja við SQL gagnagrunn eins og sýnt:

            <Eign Nafn="RdbCommandText" Tegund="System.String">
              <![CDATA[
                SELECT
                      , CARRIER_ID, EFFDT, DESCR, EFF_STATUS, TAXPAYER_ID, NETWORK_ID, FRT_FORWARD_FLG, ALT_NAME1, ALT_NAME2, LANGUAGE_CD,
                      COUNTRY, ADDRESS1, ADDRESS2, ADDRESS3, ADDRESS4, CITY, Num1, Num2, HOUSE_TYPE, ADDR_FIELD1, ADDR_FIELD2, ADDR_FIELD3,
                      COUNTY, STATE, Pósti, GEO_CODE, IN_CITY_LIMIT, COUNTRY_CODE, SÍMI, EXTENSION, FAX, LAST_EXP_CHK_DTTM, FREIGHT_VENDOR,
                      INTERLINK_DLL, TMS_EXCLUDE_FLG
                 (nolock)
                HVAR
                  (LEAs <> Hlutdeild ') og
                  (lækka(CARRIER_ID) >= Lægra(@ MinID)) og
                  (lækka(CARRIER_ID) <= Lægra(@ MaxId)) og
                  (lækka(DESCR) EINS lægri(@ InputDescr))
                ]]>
            </Eign>

Ég var að því tilskildu að SQL frá DBA mann og ég er gefið að skilja að það er sérstakt view they created just for me. The unique key there is CARRIER_ID.

Hér er villan sem ég kynnt:

      <Auðkenni>
        <Þekkja Nafn="CARRIER_ID" TypeName="System.String" />
        <Þekkja Nafn="DESCR" TypeName="System.String" /> 
</Auðkenni>

Einhvers staðar meðfram línu, Ég hafði tekist að rugla mig yfir skilningi <Auðkenni> and added DESCR even though it’s not actually an identifier. I took DESCR out of the identifiers set and presto! Það gekk allt.

Ég vona að þetta bjargar einhverjum sorg 🙂

Technorati Tags: , , ,