Content type of .pages file format
Dear team ,
please tell me the "contenttype" of the .pages file format....
example: .doc....is having the content type as "application/ms-word"
similarly can u tell me content type of .pages
Regards,
spradeepkumar
For Numbers it is:
kind = "Document Numbers" (localization dependent )
type identifier = "com.apple.iwork.numbers.sffnumbers"
For Pages it is:
kind = "Publication Pages" (localization dependent )
type identifier = "com.apple.iwork.pages.sffpages"
For Keynote it is:
kind = "Keynote Document" ( not sure of localization behavior)
type identifier:"com.apple.keynote.key"
grab it with this script after changing the pathname
set pathName to (choose file) as text
tell application "System Events"
get properties of item pathName
end tell
Yvan KOENIG (from FRANCE lundi 12 janvier 2009 16:31:07)
Similar Messages
-
Content type of .numbers files
Dear team ,
please tell me the "contenttype" of the .pages file format....
example: .doc....is having the content type as "application/ms-word"
similarly can u tell me content type of .pages
Regards,
spradeepkumarIf the document is a Numbers '09 single file,
package folder = false
kind = "Document Numbers" (localization dependant )
type identifier = "com.apple.iwork.numbers.sffnumbers"
If the document is a Numbers '08 or 09 package,
package folder = true
kind = "Document Numbers" (localization dependant )
type identifier = "com.apple.iwork.numbers.sffnumbers"
Yvan KOENIG (from FRANCE lundi 12 janvier 2009 11:06:20) -
Content type of .key files
Dear team ,
please tell me the "contenttype" of the .pages file format....
example: .doc....is having the content type as "application/ms-word"
similarly can u tell me content type of .pages
Regards,
spradeepkumarhi balusC thanks, it works very well.
your site http://balusc.xs4all.nl/srv/dev-jep-pdf.html helped me a lot.
But one point. There is another method : URLConnection.guessContentTypeFromStream(InputStream)but it don't work and i receive as result a null.
Is there another classes/methods which helps getting the content type of a file? not necessarily from sun. thanks
bye -
When I change the settings to allow for the content type and page extraction and save it, it shows allowed. When I close the pdf, reopen it, review the security properties, it shows the content type as allowed and the page extraction as disallowed. I need both to stay at allowed, how do make this happen?
The moment that you select not to allow any kind of change done to the file then pages extraction is automatically not allowed as well. There's no way around that.
-
Set content type based on file extension after uploading into document library
when there are multiple content types associated with a document library, say, report builder report, and excel documents, after you drag and drop a document into the document library, content type will not be detected based on the file extension. Suppose
your default content type is document, and you had added the report build report content type, and you uploaded a .RDL file, the content type for the file will be set to the default document content type.
I get a requirement to update the content type automatically based on the file extension, what follows is my code:
public class setCNTByFileExtItemAdded : SPItemEventReceiver
/// <summary>
/// An item was added.
/// </summary>
public override void ItemAdded(SPItemEventProperties properties)
if (properties.Web.GetFile(properties.AfterUrl).Exists)
SPListItem CurrentListItem = properties.Web.GetFile(properties.AfterUrl).Item;
String FileName = CurrentListItem.Name;
if (FileName.EndsWith(".rdl",StringComparison.OrdinalIgnoreCase))
CurrentListItem.Properties["ContentTypeId"] = "0x010100C3676CDFA2F24E1D949A8BF2B06F6B8B";
CurrentListItem.SystemUpdate(false);
base.ItemAdded(properties);
What follows are references that helped me:
http://stackoverflow.com/questions/7984300/properties-listitem-is-null-in-itemadded-event-while-uploading-documents-using
http://williamvanstrien.blogspot.in/2011/10/read-content-of-uploaded-file-within.html
http://blogs.msdn.com/b/manuj/archive/2009/09/22/itemadded-event-on-document-library-the-file-has-been-modified-by-on-error.aspx
http://support.microsoft.com/kb/2647429user may have further requirement to detect whether the uploaded .xlsx file contains powerpivot data model, i tried the following code, the caveat is that .xlsx is actually a zip file, i just test whether the uploaded stream contains an entry xl/model/item.data.
public partial class ApplicationPage2 : LayoutsPageBase
protected void Page_Load(object sender, EventArgs e)
if (this.IsPostBack)
if (FileUpload1.PostedFile == null)
return;
string destWeb = DestinationUrl.Url;
string destUrl = destWeb + "/" + FileUpload1.FileName;
using (SPSite site = new SPSite(destWeb))
using (SPWeb web = site.OpenWeb())
SPFile f = web.Files.Add(destUrl, FileUpload1.PostedFile.InputStream);
if (FileUpload1.FileName.EndsWith(".xlsx") )
Stream fs = f.OpenBinaryStream() as Stream;
using (ZipArchive zfs = new ZipArchive(fs, ZipArchiveMode.Read))
if (zfs.GetEntry("xl/model/item.data") == null)
Debug.WriteLine("Does not contain data model");
else
Debug.WriteLine("Contain data model");
The code i posted here is part of an application page in layout folder, the reason why i use application page is described in
http://social.msdn.microsoft.com/Forums/sharepoint/en-US/065d010a-d37e-4da4-9873-172ab2c50d6d/custom-list-new-application-page-with-listfielditerator-and-savebutton?forum=sharepointdevelopment#288a686e-bfbe-41aa-83d0-58a80f0cec07 -
HOW MANY TYPES OF FLAT FILE FORMAT
hi gurus......
Basically there r 3 types of flat file format
ASC
DAT
BIN
i am correct or wrong???
what is the difference between these formats?Hi,
you are right.
This is from the documentation available in GUI_UPLOAD func.module:
'BIN'.
The system reads a binary representation of the internal table from the
file. The data is neither converted nor interpreted in this case.
Usually, reasonable results are obtained only if the internal table
consists of a single column of type 'X'.
'DAT'
The components of the internal table are filled from the file. If the
table contains several columns, the entries in the file must be
separated by tabs. No conversion exits are performed. eg: .TXT with tab delimited
The following applies for the different data types:
I or N or P or F
The numbers must be formatted according to the decimal representation
defined in the user settings.
D
The date must be formatted according to the date format defined in the
user settings.
T
The time must be formatted as hh:mm:ss.
'ASC'.
The components of the internal table are filled from the file. Only
data types with fixed length are allowed. The data must be contained
in the file in its full length. eg: Like ·TXT or ·CSV files
Anirban -
Tranfer table content in to excel file format
HI
I have Created one table .and I want to download this table in to excel file format.how can i do this.Hi Vijay
1) Type the t-code SE16
2) Type the table name, for example USR02
3) Press F7 to view the table contents
4) If you need filter the data in the next screen you could do it.
5) Press F8 or press the execute bottom.
In the next screen you will find the result.
In the menu, follow the options:
System->List->Save->Local File->Spreadsheet
Type the excel name, and click generate
Hope it helps, and please reward points if helpful
Regards -
Setting Content-Type in .jspx file
Hello,
My application is not rendered by an HTML Browser.
I need to set the contentType to application/x-ywidget+xml in my JSPX file.
The content type returned is always text/xml !!!
I have tried:
1. To create a phaseListener and overloading before or after phase in ANY_PHASE
FacesContext context = FacesContext.getCurrentInstance();
ExternalContext extContext = context.getExternalContext();
HttpServletResponse response =
(HttpServletResponse)extContext.getResponse();
String contentType = "application/x-ywidget+xml";
response.setContentType(contentType);
2. To add a new MimeType extension in web.xml and create my file under this extension
<servlet-mapping>
<servlet-name>jsp</servlet-name>
<url-pattern>*.xygo</url-pattern>
</servlet-mapping>
<mime-mapping>
<extension>xygo</extension>
<mime-type>application/x-ywidget+xml</mime-type>
</mime-mapping>Frank,
Thanks you for you help.
What i would like to do is to use a JSF library components to build YahooGO pages (Yahoo mobile widgets).
For this my server needs to return an xml document with the application/x-ywidget+xml content type.
Regarding you question i don't think that the target device understand the HTML.. on my mobile, it's J2ME application...
Perhaps you can provide me some advices.
Regards,
Fred -
Changing content type of xml file to pdf
Hello,
I have an xml file (extension is *.xdp) which can locally be opened with Adobe Reader and displays as a regular pdf file. Adobe has a technology that allows xml to be merged with a pdf shell, and thus populating the pdf file with the values retrieved from the xml file.
My issue is that I want this to be done on an application server level (jboss in particular). In a servlet, I stream the xml file for the contents to be printed out within a browser (IE). I specify the content type to be application/pdf, however, the data is not being displayed within Adobe Reader, but rather as a regular xml file.
Any help is greatly appreciated. Here is the code below:
response.setHeader("Pragma", "public");
response.setHeader("Cache-Control", "max-age=30");
response.setContentType("application/pdf");
ServletOutputStream out = response.getOutputStream();
byte[] fileBytes = readFile();
out.write(fileBytes);Yes, the xml does contain a reference to the shell pdf. This works fine if I do so manually (open the xml file using Adobe Reader). However, through a browser, it seems that the forced content type is completely ignored:
<?xml version="1.0"?>
<?xfa generator="XFA2_0" APIVersion="1.4.4127.0"?>
<xdp:xdp xmlns:xdp="http://ns.adobe.com/xdp/">
<xfa:datasets xmlns="" xmlns:xfa="http://www.xfa.org/schema/xfa-data/1.0/">
<xfa:data>
<DocRoot>
<Cldemographics<Cldatecreated>7/21/05</Cldatecreated...
</DocRoot>
</xfa:data>
</xfa:datasets>
<pdf href="/opt/jboss-tomcat-server-build-4.0.0-2/.../pdfShell/Shell.pdf"
xmlns="http://ns.adobe.com/xdp/pdf/"/>
</xdp:xdp> -
Pdf with table of contents from a Pages file
I discovered in a pdf file sent to me that it has a table of contents in the sidebar where thumbnails, and annotations also reside.
When I create a pdf from my pages document this is not available.
In the table of contents sidebar are the words 'No Sections'. How do I create sections for every para styled as a heading so that they show in the table of contents sidebar of the pdf file.
I have been using outline to navigate in the pages file but the pdf would be simpler for me to do under meeting conditions.
PAMYour son was probably referring to *Adobe Acrobat Pro*. But I can't see how that would help with the sidebar automatically.
In *Acrobat Pro* it would be a matter of selecting each head to make a bookmark from that and then resave the .pdf file with the bookmarks sidebar showing upon opening.
You can also add and edit bookmarks in Preview.
+Preview > Menu > Bookmarks > Add Bookmark/Edit Bookmarks…+
I did a further experiment with a Pages document with bookmarks to see if that created the sidebar with bookmarks, but it didn't work.
There are differences in the ways Preview and Acrobat Reader display .pdfs even with what seem to be straight forward settings. I can never depend on a uniform display.
Particularly where PC users are involved.
Peter
btw When you viewed your Pages document with your TOC did you set the Preview sidebar to show "Table of Contents" in the little icons at the foot of the Preview sidebar. -
Abstract way to get Content Type of a File?
Using a java.io.File or java.io.FileInputStream is there any was the get the mime type of that file? I am working with a JEditorPane which loads files from a JTree, however I would like to take advantage of the tree's setContentType method for formatting...
I think the
JAVABEANS ACTIVATION FRAMEWORK (JAF)
is what you're looking for.
http://java.sun.com/products/javabeans/glasgow/jaf.html
But I actually never used it... (or not yet :-) )
Greets
Puce -
Video Content Type Welcome Page
For most document sets, you can determine which fields show on the welcome page by going to Document Set settings - Welcome Page Columns, but the Welcome Page Columns section does not show on the OOB Video Content Type. How do I change which fields show
on the welcome page for a video?
Specifically, I want to be able to display a custom field and remove the owner field.Hi,
According to your post, my understanding is that you got an error while creating custom document set content type.
The issue is that you set the Inherits=”FALSE” in the element. If you set the Inherits=”TRUE”, the content type would work.
Based on the article form MSDN:
If Inherits is TRUE, the child content type inherits all fields that are in the parent, including fields that users have added.
If Inherits is FALSE or absent and the parent content type is a built-in type, the child content type inherits only the fields that were in the parent content type when SharePoint Foundation was installed.
The child content type does not have any fields that users have added to the parent content type.
If Inherits is FALSE or absent and the parent content type was provisioned by a sandboxed solution, the child does not inherit any fields from the parent.
It means if you set the Inherits to true, we would lose all our customization there.
If we set Inherits="FALSE", which means you then have to remember to explicitly add into the definition all the stuff you should be inheriting, like the default Doc Set event receivers.
More reference:
http://morefunthanapokeintheeye.blogspot.com/2012/10/how-to-successfully-provision-and.html
http://ybbest.wordpress.com/2012/07/04/how-to-deploy-document-set-using-caml-in-sharepoint2010-solution-package/
Thanks & Regards,
Jason
Jason Guo
TechNet Community Support -
Document Set custom content type - welcome page missing
Sharepoint 2013. 404 error on welcome page for a following content type based on document
set:
<?xml version="1.0" encoding="utf-8"?>
<Elements xmlns="http://schemas.microsoft.com/sharepoint/">
<Field ID="{B9B7D98D-A2D3-4191-9B30-C516C8EDD9F4}" DisplayName="Fieldpr41" Name="Fieldpr41" Type="Note" RichText="false" NumLines="3" Group="pr41" Overwrite="TRUE" />
<!-- Parent ContentType: Document Set (0x0120D520) -->
<ContentType ID="0x0120D5200062FEFD4873814585B3EFD57010F1F8AE"
Name="ContentType41"
Group="Custom Content Types"
Description="My Content Type"
Inherits="FALSE"
ProgId="SharePoint.DocumentSet"
Version="0">
<FieldRefs>
<FieldRef ID="{B9B7D98D-A2D3-4191-9B30-C516C8EDD9F4}" DisplayName="Fieldpr41" Name="Fieldpr41" />
</FieldRefs>
<XmlDocuments>
<XmlDocument
NamespaceURI=
"http://schemas.microsoft.com/office/documentsets/welcomepagefields">
<wpFields:WelcomePageFields
xmlns:wpFields=
"http://schemas.microsoft.com/office/documentsets/welcomepagefields"
LastModified="1/1/2010 08:00:00 AM">
<WelcomePageField id="83729202-DCA7-4BF8-A75B-56DDDE53189C" />
</wpFields:WelcomePageFields>
</XmlDocument>
</XmlDocuments>
</ContentType>
</Elements>
Here's
what i did after changing Inherits parameter to FALSE: 1) added ProgId parameter 2) added wpFields section
Any ideas?Hi,
According to your post, my understanding is that you got an error while creating custom document set content type.
The issue is that you set the Inherits=”FALSE” in the element. If you set the Inherits=”TRUE”, the content type would work.
Based on the article form MSDN:
If Inherits is TRUE, the child content type inherits all fields that are in the parent, including fields that users have added.
If Inherits is FALSE or absent and the parent content type is a built-in type, the child content type inherits only the fields that were in the parent content type when SharePoint Foundation was installed.
The child content type does not have any fields that users have added to the parent content type.
If Inherits is FALSE or absent and the parent content type was provisioned by a sandboxed solution, the child does not inherit any fields from the parent.
It means if you set the Inherits to true, we would lose all our customization there.
If we set Inherits="FALSE", which means you then have to remember to explicitly add into the definition all the stuff you should be inheriting, like the default Doc Set event receivers.
More reference:
http://morefunthanapokeintheeye.blogspot.com/2012/10/how-to-successfully-provision-and.html
http://ybbest.wordpress.com/2012/07/04/how-to-deploy-document-set-using-caml-in-sharepoint2010-solution-package/
Thanks & Regards,
Jason
Jason Guo
TechNet Community Support -
File Adapter content conversion delimited/possitional file format.
Hi,
I have the following file to JDBC scenario, but having some issues with the file content conversion due to the file structure.
Example:
=======
000038A020301
000038A020101=AA1=AC1=AD=AG1=AH1=AI1=AK3049572=BN01 =BOMETLSS_ML_STD_30A7
000038A020200=AA96=AB001=AC17000.000=AD1200=AF13021537=AE=AG8005992427=AH10
OLRENDZZZZ
Example 2:
========
000040A020301
000040A020101=AA1=AC1=AD=AG1=AH1=AI1=AK3049570=BN01 =BOMETLSS_ML_STD_30A7
000040A020200=AA96=AB001=AC17000.000=AD1200=AF13021537=AE=AG8005992425=AH10
000041A020301
000041A020101=AA1=AC1=AD=AG1=AH1=AI1=AK3049571=BN01 =BOMETLSS_ML_STD_30A7
000041A020200=AA96=AB001=AC17000.000=AD1200=AF13021537=AE=AG8005992426=AH10
000042A020301
000042A020101=AA1=AC1=AD=AG1=AH1=AI1=AK3049572=BN01 =BOMETLSS_ML_STD_30A7
000042A020200=AA96=AB001=AC17000.000=AD1200=AF13021537=AE=AG8005992427=AH10
000043A020301
000043A020104=AA1=AC1=AD200619=AG1=AH1=AI1=AK3049568=BN01
000043A020200=AA73=AB001=AC3700.000=AD1300=AF13047285=AE200619=AG8005992423=AH10
000043A020200=AA73=AB002=AC5500.000=AD1300=AF13047285=AE200619=AG8005992423=AH10
000043A020200=AA73=AB003=AC1800.000=AD1300=AF13047285=AE200619=AG8005992423=AH10
000043A020200=AA73=AB004=AC5000.000=AD1300=AF13047285=AE200619=AG8005992423=AH10
000044A020301
000044A020104=AA1=AC1=AD200619=AG1=AH1=AI1=AK3049569=BN01
000044A020200=AA73=AB001=AC3700.000=AD1300=AF10008536=AE200619=AG8005992424=AH10
000044A020200=AA73=AB002=AC5500.000=AD1300=AF10008536=AE200619=AG8005992424=AH10
000044A020200=AA73=AB003=AC2500.000=AD1300=AF10008536=AE200619=AG8005992424=AH10
000044A020200=AA73=AB004=AC5000.000=AD1300=AF10008536=AE200619=AG8005992424=AH10
OLRENDZZZZ
Example Explained:
==============
Position 1-9 is a "Transactional number".
Position 10-11 is "Record type".
Position 12-13 is "Line Item count".
Four record types exist:
03 = Location header
01 = Transactional Header
02 = Line Item
OLRENDZZZZ = EoF marker.
The equal sign "=" is a field separator/delimiter.
In each delimited field, after the first equal sign in the record, the first two characters represent a field qualifier/field name tag/identifier and there only the data begins until the following delimiter.
Each record is ended in a "CLRF"/'nl'.
The file is build up, but not locked and only completed until the EoF marker "OLRENDZZZZ" is inserted by the application on the last record of the file.
My solution so far:
=============
Record Structure: row,*
Record Sequence: Ascending
row.fieldNames: field1,field2,field3,ect.......
row.fieldSeparator: =
row.endSeparator: 'nl'
row.keyFieldInStructure: ignore
ignoreRecordsetName: true
This brings the file into the integation server as xml as follow:
============================================
<?xml version="1.0" encoding="utf-8"?>
<ns:SAPtoFuelFACS xmlns:ns="urn:engenoil-com:i_fuel_facs_sap">
<row>
<field1>000038A020301</field1>
</row>
<row>
<field1>000038A020101</field1>
<field2>AA1</field2>
<field3>AC1</field3>
<field4>AD</field4>
<field5>AG1</field5>
<field6>AH1</field6>
<field7>AI1</field7>
<field8>AK3049572</field8>
<field9>BN01</field9>
<field10>BOMETLSS_ML_STD_30A7</field10>
<field11>BP0003049572</field11>
</row>
<row>
<field1>000038A020200</field1>
<field2>AA96</field2>
<field3>AB001</field3>
<field4>AC17000.000</field4>
<field5>AD1200</field5>
<field6>AF13021537</field6>
<field7>AE</field7>
<field8>AG8005992427</field8>
<field9>AH10</field9>
</row>
<row>
<field1>OLRENDZZZZ</field1>
</row>
</ns:SAPtoFuelFACS>
So far, so good.
The problem I am having is that I have to check for the EoF marker "OLRENDZZZZ" to be present before picking up the file, else the file is not completed.
I have tried a script to rename files in msg pre-processing in the channel, but the problem is the file channel has to be triggered and the original file mask is necessary for this, but then this mask is a valid pickup file mask. So to me it seems the only way is to do this is during the content conversion process as the files not matching the file criteria, where a EoF "OLRENDZZZZ" definition is not present, will not be picked up and be ignored until it is present or totally independent with a batch job.
If someone has a more elegant way to solve this problem with just using the file channel configuration where every thing is pretty much apparent, I would greatly appreciate it if you could assist.
Regards
Willie HugoThe problem I am having is that I have to check for the EoF marker "OLRENDZZZZ" to be present before picking up the file, else the file is not completed.
I suggest a script.
Say The files are dropped in FolderA. Have a script transfer a file to FolderB only if it finds the EoF marker in a file. Thus FolderB will be what XI will poll and that will always have the complete file.
Hope this sounds good!!! -
My daughter has a MacBook with locked software provided by her school. All week she has been working on her homework in Pages but today when she goes to open the files they are all blank, although the thumbnails show the content and the bottom of the screen shows the number of
Ages and words. We justcan't see them. Can anyone help her please?That crash appears to be casued by the Facebook plug-in.
Create a new account (systempreferences -> accounts or Users & Groups on 10.7 and 10.8), make a new Library in that account, import some shots and see if the problem is repeated there. If it is, then a re-install of the app might be indicated. If it's not, then it's likely the app is okay and the problem is something in the main account.
Maybe you are looking for
-
Device syncing, multiple Windows users accounts
I have an old iPod, an iPhone, and an iPad. I've been using only 1 account on my computer for a while now, but I recently went to 2 accounts with another computer. Both accounts are usually signed in at the same time. However, when I try to plug in a
-
How to use memo datatype in msaccess in the labview 7.1
dear all i want to save 801 data values in one cell of the field of a ms access .but the option are OLE here i can't see the data values only long binary information is displayed & also while reading i can't read too.its giving invalid data type. the
-
How do I setup a group of contacts to text?
-
I just upgraded to Yosemite on my 2010 MacBook Pro. When I reboot I get the message "To view this web content, you need to install the Java Runtime Environment" and I've also seen the same pop-up once while running OpenOffice. And now while composi
-
Invalid serial number for Windows
Hi, I got Photoshop Elements 7.0 a while ago in the Wacom tablet bundle, and I installed it on my PC. But for some reason, my tablet stopped working on my PC and I wanted to install Photoshop on my laptop instead (which is Windows Vista). When I put