Aumentar tamaño de disco en MacOSX despues de expandirlo en VMWare

Si expandimos el disco duro de una máquina virtual con Mac OS X instalado, después tenemos que ampliar la partición dentro de la propia máquina. Desde Mac OS X El Capitan la aplicación Disk Utility ha cambiado y no da la opción de hacerlo. La forma más fácil es por Terminal: sudo diskutil resizeVolume / …

Sigue leyendo Aumentar tamaño de disco en MacOSX despues de expandirlo en VMWare

Mostrar Mensaje de Confirmacion en PowerShell

$caption = "TITLE" $message = "MESSAGE" $yes = new-Object System.Management.Automation.Host.ChoiceDescription "&Yes","HELP_FOR_YES" $no = new-Object System.Management.Automation.Host.ChoiceDescription "&No","HELP_FOR_NO" $choices = [System.Management.Automation.Host.ChoiceDescription[]]($yes,$no) $answer = $host.ui.PromptForChoice($caption,$message,$choices,0) if($answer -eq 0){ //YOUR_CODE_IF_YES }

Error Microsoft SharePoint is not supported in 32-bit process

Error An unhandled exception of type 'System.PlatformNotSupportedException' occurred in Microsoft.SharePoint.dll Additional information: Microsoft SharePoint is not supported in 32-bit process. Please verify that you are running in a 64-bit executable. Explicación Se trata de un proyecto que se esta ejecutando en modo 32 bits y la librería de SharePoint no está soportada, debe ser en …

Sigue leyendo Error Microsoft SharePoint is not supported in 32-bit process

Firmar DLLs (Microsoft IL Disassembler-Assembler)

Debemos crear un fichero BAT (.bat) en la misma ruta de la DLL que queremos firmar. DEL .\SIGNED_LIBRARY.* /F "C:\Program Files (x86)\Microsoft SDKs\Windows\v7.0A\bin\ildasm.exe" .\LIBRARY.dll /output:.\SIGNED_LIBRARY.il "C:\Windows\Microsoft.NET\Framework\v2.0.50727\ilasm.exe" .\SIGNED_LIBRARY.il /dll /key=.\LIBRARY_KEY.snk /output=.\SIGNED_LIBRARY.dll PAUSE LIBRARY = Nombre de la DLL SIGNED_LIBRARY = Nombre de la DLL firmada LIBRARY_KEY = Key que usaremos para firmar la librería (La podéis …

Sigue leyendo Firmar DLLs (Microsoft IL Disassembler-Assembler)

Obtener Datos de Servicio REST con RestSharp

Este fragmento de código nos permite hacer una llamada a un Web Service REST mediante la librería RestSharp. var client = new RestClient("REST_SERVICE_URL"); client.Authenticator = new HttpBasicAuthenticator("USER", "PASSWORD"); var request = new RestRequest(Method.GET); request.RequestFormat = DataFormat.Json; IRestResponse response = client.Execute(request); var content = response.Content;

Error al guardar Infopath con llamadas REST (No sobreescribe el item)

Caso Tenemos un formulario Infopath con llamadas REST para obtener valores que utilizamos en Dropdowns. Al crear un nuevo item en la lista de SharePoint funciona. Al editar ese item no podemos guardarlo, nos genera un error. Test Si quitamos las llamadas REST, no se produce el error. Solución En Infopath vamos a las opciones …

Sigue leyendo Error al guardar Infopath con llamadas REST (No sobreescribe el item)

Añadir Site Column del tipo Lookup Field via PowerShell

Con este script podeis crear columnas del tipo Lookup a una lista en SharePoint: $web = Get-SPWeb "WEB_URL" $list = $web.Lists["LIST_NAME"] $lookupFieldXML = '<Field Type="Lookup" DisplayName="NEW_FIELD" Required="FALSE" EnforceUniqueValues="FALSE" List="{LIST_ID}" ShowField="Title" UnlimitedLengthInDocumentLibrary="FALSE" RelationshipDeleteBehavior="None" SourceID="LOOKUPLIST_ID" StaticName="NEW_FIELD" Name="NEW_FIELD" ShowInDisplayForm="TRUE" ShowInEditForm="TRUE" ShowInNewForm="TRUE" RowOrdinal="0" />' $a = $list.Fields.AddFieldAsXml($lookupFieldXML, $true, [Microsoft.SharePoint.SPAddFieldOptions]::AddFieldToDefaultView); $list.Update(); $web.Dispose();

Convertir string en string[] o char[] y viceversa

Podemos convertir strings, chars y arrays entre si de estas formas:   string -> string[] (Todo el string en un solo elemento del Array) string[] myArray = new []{ myString };   string -> string[] (String separado en cada caracter, tratado como string) string[] myArray = myString.ToCharArray().Select(s => s.ToString()).ToArray();   string -> char[] (String separado …

Sigue leyendo Convertir string en string[] o char[] y viceversa