Arkivat mujore: Dhjetor 2007

Biri im Hacked Gamespot

Kështu, këtë mëngjes, djali im është i vendosur për të parë një Halo moshën trembëdhjetë kufizuar 3 Video në Gamespot. I’m outside shoveling snow, so I’m not there to help or hinder. Necessity is the mother of invention and all that … he has a eureka! moment. He realizes that even though Gamespot wants him to enter his real data e lindjes, ai në fakt mund të hyjë ndonjë birth date he wants. Once he realized that, ai e bëri veten të vjetër të mjaftueshme për të parë këtë video.

I’m not quite sure how I feel about this 🙂

E diel Funny: “Është Shtypi Garbage”

Në punën time të parë të kolegjit në 1991, Unë kam qenë me fat për të punuar për një kompani prodhuese me 13 Lokacionet, not including its corporate HQ in New Jersey. I joined just when the company was rolling out a new ERP system. We were a small IT department of about ten people altogether, two of whom Did Not Travel. Part of the project involved replacing IBM System 36 boxes with HP hardware and HPUX. Everyone used green tubes to access the system.

Projekti rrotullon së bashku dhe unë jam i dërguar poshtë në Baltimore me një të ri bashkë-punëtor, Jeff. Our job was to power up the Unix box, sigurohuni O / S ishte duke vrapuar, instaluar sistemin ERP, konfiguroni ERP, train people on the ERP and do custom work for folks on the spot. (This was a dream job, especially coming straight out of college). Before we could really get off the ground, we needed to unpack all the green tubes, put them on desks and wire them. And the best part was that we had to put the RJ11 connectors on ourselves.

For some reason that I never understood and actually never thought to ask about at the time, we had had some contracting company come along and run cable throughout the plant, but we didn’t have them put on the connectors. Kështu, there was a "patch box" with dozens of of unlabeled cables in the "computer room" and these snaked around the building to various places in the building.

Ne kemi punuar rrugën tonë nëpërmjet saj gjatë rrjedhës së një fundjavë, testimi çdo tel, vënë në një lidhës (duke u siguruar se ishte e drejtë vs. kaluar), sigurimin settings pak në tubat e gjelbër dhe printera ishin të sakta, labeling wires, making sure that "getty" was running correctly for each port and probably a thousand other things that I’ve suppressed since then. It all came together quite nicely.

Por, there was one important cable that we couldn’t figure out. The plant in Baltimore had a relationship with a warehousing location in New Jersey. Some orders placed in Baltimore shipped out of that location. There were two wires that we had to connect to the HPUX box: a green tube and a printer. The green tube was easy, but the printer turned into a three-week nightmare.

If you don’t know it, or have suppressed it, dealing with green tubes and printers this way, there are various options that you deal with by setting various pins. 8-bit, 7-bit, parity (even/odd/none), probably others. If you get one of those settings wrong, the tube or printer still shows stuff, but it will be total gibberish, or it will be gibberish with a lot of recognizable stuff in between. Sigurisht, these pins are hard to see and have to be set by using a small flat-edge screw driver. And they are never standard.

We set up the first of many quick calls with the NJ guy (a grizzled computer hater who probably curses us to this day). We got the green tube working pretty quickly, but we couldn’t get the printer to work. It kept "printing garbage". We would create a new RJ11 connector, switching between crossed and straight. We would delete the port and re-created in Unix. We went through the arduous task of having him explain to us the pin configuration on the printer, kurrë me të vërtetë i sigurt nëse ai e kishte bërë atë të saktë.

Është koha për të shkuar të jetojnë, gjithçka në Baltimore është gjallë, por ne nuk mund të merrni printer mallkuar deri në New Jersey për të punuar! We’ve exhausted all possibilities except for driving back up to NJ to work on the printer in person. To avoid all that driving, we finally ask him to fax us what he’s getting when it’s "garbage", hoping that maybe there will be some clue in that garbage that will tell us what we’re doing wrong.

When we got the fax, we immediately knew what was wrong. Shoh, our method of testing whether we had configured a printer correctly was to issue an "lp" command like this:

lp /etc/passwd

Në parim, we printed out the unix password file. It’s always present and out of the box, always just one page. You standard Unix password file looks something like this:

smith:*:100:100:8A-74(zyrë):/home/smith:/usr/bin/sh
guest:*:200:0::/home/guest:/usr/bin/sh  

We had been printing out the password file over and over again for several weeks and it was printing correctly. Megjithatë, to the end user, it was "printing garbage".

</fund>

Yet Another Kredencialet Rrjeti Multi-Sfida dhe Çështja Zgjidhja

Klienti im kohët e fundit instaluar një pajisje magjike nga Dëllinjë që me sa duket zëvendësoi vjetër e tyre akrobat ngarkesës Cisco rrjet (NLB). At about the same time, ne kemi instaluar një hotfix për të trajtuar një problem të rrjedhës së punës.

Një ditë apo dy më vonë, kemi vënë re një problem kur kemi në disponim ofruesin e shërbimit të përbashkët (SSP). We could get to it, but we would be challenged for a user ID and password many times on each page. This didn’t happen with the main portal app, nor central administration. Naturally, ne nuk e dimë se cili prej të dyve (Dëllinjë ose hotfix) do të jetë çështja, pse unë fuqimisht dyshuar e hotfix, parafytyruar ne nuk e kishte instaluar atë mjaft e drejtë.

It turned out that Juniper had some kind of compression setting. Një nga Shifrat veshur over in the network group turned that setting off. That solved our problem.

This is not the first time that compression has been the root cause of a SharePoint problem for me. IIS compression adversely affected a 3rd party tool from the good people at The Dot Net Factory for IE 6 shfletues (IE 7 shfletues punuar pa vështirësi).

Kështu, add "compression" në listën e rreziqeve.

</fund>

Kredia për: http://www.elfwood.com/art/s/h/sherry/death_colour.jpg.html

Technorati Tags: ,

Thinking About Ndryshimi platformë Blogging

I started off my "blogging career" using Microsoft’s platform and it’s been good to me. It’s easy to post, there are good options and widgets for managing your "space", decent web storage and so forth.

Megjithatë, I really just fell into the MS solution with almost no planning. That alone calls for me to evaluate where I am and where I’m going, in terms of a blogging platform. There are also two important limitations that bother me right now vis-à-vis Windows Live Spaces.

I parë, I can’t get very good statistics. There are stats but the detail is often truncated and not presented in a way that allows for any kind of analysis. There no sorting or export capability. I get many blog ideas based on the kind of information people find (or especially fail to find) when they search my blog. It’s very hard to use lives spaces for that.

I dytë, there does not seem to be any mechanism to "monetize" a windows live space blog. Në të vërtetë, in order to get rid of MS ads (from which I derive no benefit), I need to actually pay Microsoft. (At least, that’s how I understand it; I have been unable to get definitive answers to this and questions like it).

Now that I’ve got an established pattern and set of blogging habits, I want to evaluate other options. I’ve done some research and there are a lot of choices, but I’m curious as to what other people, particularly others in the SharePoint community (as bloggers or readers), like to use.

If this subject interests you and you have an opinion or are willing to share your experience, please leave a comment or email me directly.

Falënderim!

<Fundi />

Technorati Tags:

Email SharePoint Designer Dërgon ???? në një email

Përdoruesit Forum here pas here pyet: Pse nuk SharePoint Designer vënë ???? në email tim në vend të një vlerë në terren?

Një arsye kjo ndodh për shkak se është e ndryshueshme për të cilën ju i referoheni është null.

This can happen because you are trying to reference a field from the "current item" por kurrë përdoruesi ka hyrë një vlerë në atë fushë formë.

<Fundi />

Technorati Tags:

Krahasoj / Test për datat Blank në SharePoint Designer Workflow

Skenar: In a SharePoint Designer workflow, you need to determine if a date field is blank.

Problem: SPD does not provide a direct method for comparing dates to anything other than a date. You cannot create a condition like this: "If [DateField] equals blank".

Zgjidhje: Convert the date to a string. Use string comparison to determine if the date is blank.

Screen Shots:

The following screen shots show how to do this. Në këtë skenar, a field on an item, "Environmental Permits:First Permit Reminder Date", is submitted and the workflow fires in response.

imazh

imazh

Shënimet:

When I tried this, I was pleasantly surprised to learn that it works. I was worried that SharePoint Designer might disallow the string assignment (Variabël:StringReminderDateDate) but it did allow it.

I was also concerned that allowing it, the value might be null and either blow up the WF at runtime or maybe raise the global temperature 1/2 a degree, but those concerns were unfounded.

</fund>

Technorati Tags:

Bar është ende mjaft i lartë do të zgjasë Moss

Sot, I was working with a client and describing how to modify the content query web part and display additional bits of information from a content type.

"First, ju konfiguroni CQWP për t'u lidhur me burimet e saj të të dhënave, atëherë ju eksportojë atë në workstation tuaj, modifikoj <CommonViewFields>, ngarkoni, remove the original and now it’s ‘primed’ to display those other columns. Tjetër, open up SharePoint designer, navigate to the site collection root and locate ItemStyle.xsl. Copy one of the templates as a useful starting point. Go back and modify the CQWP to make use of this new template. Më në fund, modify the template to render your new fields! (Don’t forget to check it back in so that other users can see the results)."

It’s all quite clear to me (and most of us SharePoint developer types) what’s going on and how it’s quite nice, vërtet, that the data retrieval aspects of the CQWP are so well-separate from the data presentation aspects. Por, it’s not so easy to explain, is it?

<Fundi />

Technorati Tags: ,

Shfaq Query Content Rezultatet Web pjesë në një rrjet / Tryezë

Përmbledhje dhe Objektiva

Nga kutia, Moss’ Query Përmbajtja Web Part (CQWP) shfaq rezultatet e veta në një format të listës, similar to search results. It is also possible to display the results in a grid format (i.e. Formati HTML tryezë). Grid formats are better in some circumstances. I describe how to achieve that effect in this article.

Skenari Biznes

I have worked with a client on an enterprise-wide MOSS rollout. We have designed their taxonomy such that projects are first class citizens in the hierarchy and have their own top level site. Project managers maintain a singleton list of project summary information, such as title, budget, expected completion date, remaining budget and other summary type fields. By "singleton" I mean a custom SharePoint list guaranteed to contain only one item. Simplistically, kjo duket si ky:

imazh

The technical approach is much the same as described këtu (http://paulgalvin.spaces.live.com/blog/cns!1CC1EDB3DAA9B8AA!447.entry). The CQWP uses an XSL transform to emit HTML for the browser to render.

I always envision the result before diving into the XSL because XSL is a nightmare. Here’s my desired result:

imazh

HTML like this generates that result:

<html>
 <trup>
 <qendër>
 <tryezë kufi=1>

<!-- Labels -->
 <tr bgcolor=blue>
 <td><font ngjyrë=white><b>Project Name</b></font></td>
 <td align=right><font ngjyrë=white><b>Complete Date</b></font></td>
 <td align=right><font ngjyrë=white><b>Budget</b></font></td>
 <td align=right><font ngjyrë=white><b>Actual Expense</b></font></td>
 <td><font ngjyrë=white><b>Overall Status</b></font></td>
 </tr>

<tr>
 <td>Re-wire computer room.</td>
 <td align=right>02/01/08</td>
 <td align=right>22,500.00</td>
 <td align=right>19,000.00</td>
 <td>In Progress</td>
 </tr>

<tr>
 <td>Provision servers for SQL Upgrade</td>
 <td align=right>04/01/08</td>
 <td align=right>7,500.00</td>
 <td align=right>0.00</td>
 <td>Planned</td>
 </tr>

</tryezë>
 </qendër>
 </trup>
</html>

Approach

Follow these steps to create the grid:

  1. Identify the components of the grid (rows/columns).
  2. Define and create necessary site columns.
  3. Create sub sites for the projects and singleton lists.
  4. Add the CQWP to a web page and configure it to search for your lists.
  5. Modify the CQWP’s XML to gather up the additional columns.
  6. Modify the XSL to generate a table.

I’m going to concentrate on number six. Numbers one through four are straight-forward and something that any CQWP user has already done. Number five has been well-documented by others including this exhaustive screen-shot laden article from MSDN këtu (http://msdn2.microsoft.com/en-us/library/bb897399.aspx) and Heather Solomon’s blog këtu (http://www.heathersolomon.com/blog/articles/CustomItemStyle.aspx).

Nuts And Bolts

Begin and implement steps one through five as per the MSDN documentation and Heather Solomon’s article.

Në këtë pikë, you’ve added your CQWP to the page and you have your <CommonViewFields> configured as necessary.

Following the usual steps, I get these intermediate results:

1. Krijo një lloj përmbajtje, a templatized custom list for that content type and two sites. Here is the content type:

imazh

Here is the site structure:

imazh

2. Add the CQWP after creating my project subsites and singleton project summary lists:

imazh

3. Add all the additional information I want via the <CommonViewFields>:

        <pronë emër="CommonViewFields" lloj="varg">Project_x0020_Name;Project_x0020_Expenses;Project_x0020_Status;Project_x0020_Start_x0020_Date;Project_x0020_End_x0020_Date;Project_x0020_Budget</pronë>

Note that I had to keep all the property fields on one line or it would not work (CQWP would tell me that the query returned no items).

4. Në këtë pikë, we’re ready to move beyond the MSDN article and flip on over to Heather Solomon’s article. Follow her steps starting near step #5 to create a customized / unghosted version of ItemStyle.xsl. I follow Heather’s advice, up through step 11 and get these intermediate results:

4.1: Name my XSL template as follows:

<XSL:template name="Grid" match="Row[@Style=’Grid’]" mode="itemstyle">

I also slightly modify her suggested <XSL:për njëri- …> by adding a <br/> tag to provide a cleaner listing:

    <XSL:për njëri- zgjedh="@*">
      P:<XSL:vlera-e zgjedh="emër()" /><br/>
    </XSL:për njëri->

4.2: I modify the web part, go to appearance and select my "Grid" stil:

imazh

Apply the change and here is the result:

imazh

We can see from the above that the fields we want (Project name, expense, status, etj) are available for us to use when we emit the HTML. Not only that, but we see the names by which we must reference those columns in the XSL. Për shembull, we reference Project Status as "Project_x005F_x0020_Name".

Në këtë pikë, we depart from Heather’s blog and from the shoulders of these giants, I add my own little bit.

ContentQueryMain.xsl

SHËNIM: When making changes to both ContentQueryMain.xsl as well as ItemStyle.xsl, you need to check those files back in before you see the effect of your changes.

For grid-making purposes, MOSS uses two different XSL files to produce the results we see from a CQWP. To generate the previous bit of output, we modified ItemStyle.xsl. MOSS actually uses another XSL file, ContentQueryMain.xsl to in conjunction with ItemStyle.xsl to generate its HTML. As its name implies, ContentQueryMain.xsl is the "main" XSL that controls the overall flow of translation. It iterates through all the found items and passes them one by one to templates in ItemStyle.xsl. We’ll modify ItemStyle.xsl to generate the open <tryezë> tag before emitting the first row of data and the closing <tryezë> tag after emitting the last row. To accomplish this, ContentQueryMain.xsl is modified to pass two parameters to our "grid" template in ItemStyle.xsl, "last row" and "current row". ItemStyle.xsl uses these to conditionally emit the necessary tags.

Using Heather Solomon’s technique, we locate ContentQueryMain.xsl. It is located in the same place as ItemStyle.xsl. This screen shot should help:

imazh

We need to make the following changes:

  • Modify an xsl template, "CallItemTemplate" that actually invokes our Grid template in ItemStyle.xsl. We will pass two parameters to the Grid template so that it will have the data it needs to conditionally generate opening and closing <tryezë> tags.
  • Modify another bit of ContentQueryMain.xsl that calls the "CallItemTemplate" to pass it a "LastRow" parameter so that LastRow may be passed on to our Grid template.

Locate the template named "OuterTemplate.CallItemTemplate" identified by the string:

  <XSL:shabllon emër="OuterTemplate.CallItemTemplate">

Replace the whole template as follows:

  <XSL:shabllon emër="OuterTemplate.CallItemTemplate">
    <XSL:param emër="CurPosition" />

    <!--
      Add the "LastRow" parameter.
      We only use it when the item style pass in is "Grid".
    -->
    <XSL:param emër="LastRow" />

    <XSL:zgjedh>
      <XSL:kur provë="@Style='NewsRollUpItem'">
        <XSL:apply-templates zgjedh="." mode="itemstyle">
          <XSL:me param- emër="EditMode" zgjedh="$cbq_iseditmode" />
        </XSL:apply-templates>
      </XSL:kur>
      <XSL:kur provë="@Style='NewsBigItem'">
        <XSL:apply-templates zgjedh="." mode="itemstyle">
          <XSL:me param- emër="CurPos" zgjedh="$CurPosition" />
        </XSL:apply-templates>
      </XSL:kur>
      <XSL:kur provë="@Style='NewsCategoryItem'">
        <XSL:apply-templates zgjedh="." mode="itemstyle">
          <XSL:me param- emër="CurPos" zgjedh="$CurPosition" />
        </XSL:apply-templates>
      </XSL:kur>

      <!--
              Pass current position and lastrow to the Grid itemstyle.xsl template.
              ItemStyle.xsl will use that to emit the open and closing <tryezë> tags.
      -->
      <XSL:kur provë="@Style='Grid'">
        <XSL:apply-templates zgjedh="." mode="itemstyle">
          <XSL:me param- emër="CurPos" zgjedh="$CurPosition" />
          <XSL:me param- emër="Last" zgjedh="$LastRow" />
        </XSL:apply-templates>
      </XSL:kur>

      <XSL:ndryshe>
        <XSL:apply-templates zgjedh="." mode="itemstyle">
        </XSL:apply-templates>
      </XSL:ndryshe>
    </XSL:zgjedh>
  </XSL:shabllon>

The comments describe the purpose of the changes.

Sigurisht, the "OuterTemplate.CallItemTemplate" is itself called from another template. Locate that template by searching for this text string:

<XSL:shabllon emër="OuterTemplate.Body">

Scroll through the instructions in OuterTemplate.Body and insert the LastRow parameter as follows (shown as a comment in italics):

<XSL:thirrje-template emër="OuterTemplate.CallItemTemplate">
  <XSL:me param- emër="CurPosition" zgjedh="$CurPosition" />
  <!-- Insert the LastRow parameter. -->
  <XSL:me param- emër="LastRow" zgjedh="$LastRow"/>
</XSL:thirrje-template>

After all of this, we finally have things set up properly so that our ItemStyle.xsl can emit <tryezë> tags at the right place.

ItemStyle.Xsl

SHËNIM: Përsëri, check in ItemStyle.xsl after making any changes so that you see the effect of those changes.

We have two tasks here:

  • Replace the entire Grid template. You can copy/paste from below.
  • Add some mumbo jumbo outside the template definition that enables "formatcurrency" template to work. (You can tell that I have a tenuous handle on XSL).

I parë, near the top of ItemStyle.xsl, add this line:

  <!-- Some mumbo jumbo that enables us to display U.S. currency. -->
  <XSL:Te Dhjeta-format emër="staff" digit="D" />

  <XSL:shabllon emër="Default" ndeshje="*" mode="itemstyle">

Note that I added it directly before the <XSL:template name="Default" …> definition.

Tjetër, go back to our Grid template. Replace the entire Grid template with the code below. It is thoroughly commented, but don’t hesitate to email me or leave comments on my blog if you have questions.

  <XSL:shabllon emër="Grid" ndeshje="Row[@Style='Grid']" mode="itemstyle">

    <!--
      ContentMain.xsl passes CurPos and Last.
      We use these to conditionally emit the open and closing <tryezë> tags.
    -->
    <XSL:param emër="CurPos" />
    <XSL:param emër="Last" />

    <!-- The following variables are unmodified from the standard ItemStyle.xsl -->
    <XSL:variabël emër="SafeImageUrl">
      <XSL:thirrje-template emër="OuterTemplate.GetSafeStaticUrl">
        <XSL:me param- emër="UrlColumnName" zgjedh="'ImageUrl'"/>
      </XSL:thirrje-template>
    </XSL:variabël>
    <XSL:variabël emër="SafeLinkUrl">
      <XSL:thirrje-template emër="OuterTemplate.GetSafeLink">
        <XSL:me param- emër="UrlColumnName" zgjedh="'LinkUrl'"/>
      </XSL:thirrje-template>
    </XSL:variabël>
    <XSL:variabël emër="DisplayTitle">
      <XSL:thirrje-template emër="OuterTemplate.GetTitle">
        <XSL:me param- emër="Titull" zgjedh="@Title"/>
        <XSL:me param- emër="UrlColumnName" zgjedh="'LinkUrl'"/>
      </XSL:thirrje-template>
    </XSL:variabël>
    <XSL:variabël emër="LinkTarget">
      <XSL:nëse provë="@OpenInNewWindow = 'True'" >_blank</XSL:nëse>
    </XSL:variabël>

    <!--
      Here we define a variable, "tableStart".  This contains the HTML
      that we use to define the opening of the table as well as the column
      labels.  Note that if CurPos = 1, it includes the HTML in a CDATA tag.
      Otherwise, it will be empty.

      The value of tableStart is emited every time ItemStyle is called via
      ContentQueryMain.xsl.
    -->
    <XSL:variabël emër="tableStart">
      <XSL:nëse provë="$CurPos = 1">
        <![CDATA[
        <table border=1>
          <tr bgcolor="blue">
            <td><font color="white"><b>Project Name</b></font></td>
            <td align="right"><font color="white"><b>Complete Date</b></font></td>
            <td align="right"><font color="white"><b>Budget</b></font></td>
            <td align="right"><font color="white"><b>Actual Expense</b></font></td>
            <td><font color="white"><b>Overall Status</b></font></td>
          </tr>
        ]]>
      </XSL:nëse>
    </XSL:variabël>

    <!--
      Another variable, tableEnd simply defines the closing table tag.

      As with tableStart, it's always emited.  This is why its value is
      assigned conditionally based upon whether we've been passed the last
      row by ContentQueryMain.xsl.
    -->
    <XSL:variabël emër="tableEnd">
      <XSL:nëse provë="$CurPos = $Last">
        <![CDATA[ </tryezë> ]]>
      </XSL:nëse>
    </XSL:variabël>

    <!--
      Always emit the contents of tableStart.  If this is not the first
      row passed to us by ContentQueryMain.xsl, then we know its value
      will be blank.

      Disable output escaping because when tableStart it not blank, it
      includes actual HTML that we want to be rendered by the browser.  If
      we don't tell the XSL parser to disable output escaping, it will generate
      stuff like "&lt;tryezë&gt;" instead of "<tryezë>".
    -->
    <XSL:vlera-e zgjedh="$tableStart" disable-output-ikin="po"/>


    <tr>
      <!--
      P:Project_x005F_x0020_Name
      P:Project_x005F_x0020_End_x005F_x0020_Date
      P:Project_x005F_x0020_Budget
      P:Project_x005F_x0020_Expenses
      P:Project_x005F_x0020_Status
      -->
      <td>
        <XSL:vlera-e zgjedh="@Project_x005F_x0020_Name"/>
      </td>

      <td align="e drejtë">
        <XSL:vlera-e zgjedh="@Project_x005F_x0020_End_x005F_x0020_Date"/>
      </td>

      <td align="e drejtë">
        <XSL:thirrje-template emër="formatcurrency">
          <XSL:me param- emër="vlerë" 
zgjedh="@Project_x005F_x0020_Budget"></XSL:me param-> </XSL:thirrje-template> </td> <td align="e drejtë"> <XSL:thirrje-template emër="formatcurrency"> <XSL:me param- emër="vlerë" zgjedh="@Project_x005F_x0020_Expenses">
</XSL:me param-> </XSL:thirrje-template> </td> <td> <XSL:vlera-e zgjedh="@Project_x005F_x0020_Status"/> </td> <!-- All of the following is commented out to clarify things. Megjithatë, bring it back and stuff it into a <td> to see its effect. --> <!-- <div id="linkitem" class="item"> <XSL:if test="string-length($SafeImageUrl) != 0"> <div class="image-area-left"> <a href="{$SafeLinkUrl}" target="{$LinkTarget}"> <img class="image-fixed-width" src="{$SafeImageUrl}"
alt="{@ImageUrlAltText}"/> </një> </div> </XSL:nëse> <div class="link-item"> <XSL:thirrje-template
name="OuterTemplate.CallPresenceStatusIconTemplate"/> <a href="{$SafeLinkUrl}"
target="{$LinkTarget}" title="{@LinkToolTip}"> <XSL:value-of select="$DisplayTitle"/> </një> <div class="description"> <XSL:value-of select="@Description" /> </div> </div> </div>
--> </tr> <!-- Emit the closing table tag. If we are not on the last row, this will be blank. --> <XSL:vlera-e zgjedh="$tableEnd" disable-output-ikin="po"/> </XSL:shabllon> <XSL:shabllon emër="formatcurrency"> <XSL:param emër="vlerë" zgjedh="0" /> <XSL:vlera-e zgjedh='Formati-numri($vlerë, "$DDD,DDD,DDD.DD", "staff")' /> </XSL:shabllon>

Standard WSS / MOSS hyrjes Ekrane të dhënave nuk e mbështesin Cascading drop-downs (apo të tjera intra-nga komunikimi)

UPDATE (04/2008): Kjo hyrje blog i madh tregon një qasje të mirë javascript bazuar për këtë problem: http://webborg.blogspot.com/2008/04/add-functions-and-events-to-sharepoint.html

UPDATE II: (04/2008): Kjo hyrje blog duket premtues, si dhe: http://www.cleverworkarounds.com/2008/03/13/free-mosswss-2007-web-part-hide-controls-via-javascript/

Disa herë në javë, nëse nuk e përditshme, forum users describe a requirement that would normally be met via cascading drop-downs. Për shembull, Unë kam dy drop-down kontrollet:

  • Lista e U.S. shtetet
  • Lista e U.S. Qytetet.

Si përgjegjës ofruesit UI, ne duam që ajo të veprojë si kjo:

  • Paul zgjedh një U.S. state from the drop-down.
  • This causes the cities drop-down to filter only those cities that belong to the selected state.
  • Paul zgjedh një qytet nga kjo listë filtruar.

There is no out-of-the-box support for this feature. Në të vërtetë, there is no OOB support for any kind of direct intra-form communication. This includes programmatically hiding/enabling/disabling fields in response to field changes elsewhere on the form.

Objektivi i vërtetë i këtij neni ndaj të përshkruani zgjidhjet e mundshme dhe këto janë opsionet sa di unë ato:

  1. Develop a custom column type. As a custom-column-developer, you have full control over the "world" of that custom column. You can implement a cascading drop-down that way.
  2. Consider using workflow. In some cases, you want to automatically assign a value to field based on another field’s value. Në këtë rast, ju do të normalisht të provoni të përdorni një kolonë të llogaritur, por disa herë, it just won’t get the job done. SharePoint Designer workflow is a relatively administer-friendly alternative to dropping down into code and visual studio. If you go this route, të jetë i vetëdijshëm për çështjen që trajtohet nga ky artikull (http://paulgalvin.spaces.live.com/blog/cns!CC1EDB3DAA9B8AA!405.entry).
  3. Handlers Event: Ashtu si workflow, this is an after-the-fact solution. Your event handler is a .NET assembly (C #, VB.NET) to which SharePoint passes control. The object you develop has access to the data of the list (dhe modeli i tërë objekti) dhe mund të bëjmë ndonjë kalkulim të nevojshme.
  4. Use SharePoint Designer to create custom entry forms. I don’t have direct experience with this approach, but I hear they are doing good things with NewForm.aspx these days 🙂
  5. Roll funksionin tuaj ASP.NET futja e të dhënave (si një faqe më vete interneti ose si një pjesë web) dhe të përdorin që në vend.

Nëse dikush e di opsione të tjera dhe / ose më të mirë, ju lutem postoj një koment dhe unë do update trupin e këtë post.

<Fundi />

Technorati Tags:

Yes/No (kontrolloni kutinë) filtrim në Pjesën Web Content Query

To filter for a query for the Yes/No check box entitled "PG Milestone", konfiguroni CQWP si kjo:

imazh

Kjo është një tjetër një nga ato qartë-dikur-ju-di-atë, por e vështirë për ta gjetur-nje-përgjigje në pyetjet-: Si për të filtruar në një kuti Po / Nuk ka kontroll duke përdorur query përmbajtjes pjesën web.

Parë rezultati i kërkimit I find using the search term "filter yes/no content query web part" është e sheshtë jashtë gabuar, kështu që unë mendova se do të vënë këtë deri atje dhe të shohim nëse ajo mund të zëvendësojë rezultatin gabuar në rezultatet e kërkimit tipike.

Është mjaft e lehtë: True values = "1" and false values do not equal "1" (goxha retro, në të vërtetë).

Në shembullin e mësipërm, I created site column of type "Yes/No (checkbox)" named "PG Milestone". I added it to a doc library, ngarkuar një disa dokumente, vendosur vlera për një çift dhe testuar atë.

<Fundi />