locked
VSCTCompiler Error RRS feed

  • Question

  • when i add "visual studio integration package project" to source contorl this error occure

    Error    141    The "VSCTCompiler" task failed unexpectedly.
    System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation. ---> System.NullReferenceException: Object reference not set to an instance of an object.
       at CVsFileMapping.Write(CVsFileMapping* , Void* pv, UInt32 cb, Int32 fForceFlush) in f:\whidbeyvssdk\vssdk\vsintegration\tools\src\ctc\vsctcompress\vsctcompress\filemap.cpp:line 117
       at Microsoft.VisualStudio.CommandTable.Compressor.WriteUInt32(UInt32 n) in f:\whidbeyvssdk\vssdk\vsintegration\tools\src\ctc\vsctcompress\vsctcompress\vsctcompress.h:line 188
       at Microsoft.VisualStudio.CommandTable.BinaryWriteCTCStream.WriteUInt32(UInt32 i) in f:\dd\vssdk\VSIntegration\Tools\src\CTC\VSCTLibrary\BinaryWriteCTCStream.cs:line 308
       at Microsoft.VisualStudio.CommandTable.FileHeader.Write(BinaryWriteCTCStream s) in f:\dd\vssdk\VSIntegration\Tools\src\CTC\VSCTLibrary\FileHeader.cs:line 81
       at Microsoft.VisualStudio.CommandTable.CommandTable.Write(BinaryWriteCTCStream s) in f:\dd\vssdk\VSIntegration\Tools\src\CTC\VSCTLibrary\CommandTable.cs:line 1477
       at Microsoft.VisualStudio.CommandTable.CommandTable.Save(String fileName, SaveOptions so, IMessageProcessor errorProcessor) in f:\dd\vssdk\VSIntegration\Tools\src\CTC\VSCTLibrary\CommandTable.cs:line 298
       at Microsoft.VisualStudio.CommandTable.Compiler.Compile() in f:\dd\vssdk\VSIntegration\Tools\src\CTC\VSCT\Compiler.cs:line 321
       at Microsoft.VisualStudio.CommandTable.VSCTCompiler.Execute() in f:\dd\vssdk\VSIntegration\Tools\src\CTC\VSCT\VSCTCompilerTask.cs:line 333
       --- End of inner exception stack trace ---
       at System.RuntimeMethodHandle._InvokeMethodFast(Object target, Object[] arguments, SignatureStruct& sig, MethodAttributes methodAttributes, RuntimeTypeHandle typeOwner)
       at System.RuntimeMethodHandle.InvokeMethodFast(Object target, Object[] arguments, Signature sig, MethodAttributes methodAttributes, RuntimeTypeHandle typeOwner)
       at System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture, Boolean skipVisibilityChecks)
       at System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture)
       at System.RuntimeType.InvokeMember(String name, BindingFlags bindingFlags, Binder binder, Object target, Object[] providedArgs, ParameterModifier[] modifiers, CultureInfo culture, String[] namedParams)
       at System.Type.InvokeMember(String name, BindingFlags invokeAttr, Binder binder, Object target, Object[] args, CultureInfo culture)
       at Microsoft.VsSDK.Build.Tasks.VSCTCompiler.Execute()
       at Microsoft.Build.BuildEngine.TaskEngine.ExecuteInstantiatedTask(EngineProxy engineProxy, ItemBucket bucket, TaskExecutionMode howToExecuteTask, ITask task, Boolean& taskResult)    C:\Program Files\MSBuild\Microsoft\VisualStudio\v9.0\VSSDK\Microsoft.VsSDK.targets    133    5    CaranePackage
    Sunday, March 14, 2010 8:44 AM

All replies

  • When I add "visual studio integration package project" to source contorl this error occure when I build project

    Error    141    The "VSCTCompiler" task failed unexpectedly.
    System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation. ---> System.NullReferenceException: Object reference not set to an instance of an object.
       at CVsFileMapping.Write(CVsFileMapping* , Void* pv, UInt32 cb, Int32 fForceFlush) in f:\whidbeyvssdk\vssdk\vsintegration\tools\src\ctc\vsctcompress\vsctcompress\filemap.cpp:line 117
       at Microsoft.VisualStudio.CommandTable.Compressor.WriteUInt32(UInt32 n) in f:\whidbeyvssdk\vssdk\vsintegration\tools\src\ctc\vsctcompress\vsctcompress\vsctcompress.h:line 188
       at Microsoft.VisualStudio.CommandTable.BinaryWriteCTCStream.WriteUInt32(UInt32 i) in f:\dd\vssdk\VSIntegration\Tools\src\CTC\VSCTLibrary\BinaryWriteCTCStream.cs:line 308
       at Microsoft.VisualStudio.CommandTable.FileHeader.Write(BinaryWriteCTCStream s) in f:\dd\vssdk\VSIntegration\Tools\src\CTC\VSCTLibrary\FileHeader.cs:line 81
       at Microsoft.VisualStudio.CommandTable.CommandTable.Write(BinaryWriteCTCStream s) in f:\dd\vssdk\VSIntegration\Tools\src\CTC\VSCTLibrary\CommandTable.cs:line 1477
       at Microsoft.VisualStudio.CommandTable.CommandTable.Save(String fileName, SaveOptions so, IMessageProcessor errorProcessor) in f:\dd\vssdk\VSIntegration\Tools\src\CTC\VSCTLibrary\CommandTable.cs:line 298
       at Microsoft.VisualStudio.CommandTable.Compiler.Compile() in f:\dd\vssdk\VSIntegration\Tools\src\CTC\VSCT\Compiler.cs:line 321
       at Microsoft.VisualStudio.CommandTable.VSCTCompiler.Execute() in f:\dd\vssdk\VSIntegration\Tools\src\CTC\VSCT\VSCTCompilerTask.cs:line 333
       --- End of inner exception stack trace ---
       at System.RuntimeMethodHandle._InvokeMethodFast(Object target, Object[] arguments, SignatureStruct& sig, MethodAttributes methodAttributes, RuntimeTypeHandle typeOwner)
       at System.RuntimeMethodHandle.InvokeMethodFast(Object target, Object[] arguments, Signature sig, MethodAttributes methodAttributes, RuntimeTypeHandle typeOwner)
       at System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture, Boolean skipVisibilityChecks)
       at System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture)
       at System.RuntimeType.InvokeMember(String name, BindingFlags bindingFlags, Binder binder, Object target, Object[] providedArgs, ParameterModifier[] modifiers, CultureInfo culture, String[] namedParams)
       at System.Type.InvokeMember(String name, BindingFlags invokeAttr, Binder binder, Object target, Object[] args, CultureInfo culture)
       at Microsoft.VsSDK.Build.Tasks.VSCTCompiler.Execute()
       at Microsoft.Build.BuildEngine.TaskEngine.ExecuteInstantiatedTask(EngineProxy engineProxy, ItemBucket bucket, TaskExecutionMode howToExecuteTask, ITask task, Boolean& taskResult)    C:\Program Files\MSBuild\Microsoft\VisualStudio\v9.0\VSSDK\Microsoft.VsSDK.targets    133    5    CaranePackage

    Sunday, March 14, 2010 8:46 AM
  • Hello,

    You said this happens when you move your project to source control, does this happen before your move it?

    Could you post your VSCT file here? It is hard to diagnose your issue according to your stack trace.

    Thanks

    Chao

    Tuesday, March 16, 2010 3:21 AM
  • Hello Chao Kuo Yes , my program work correctly before add to source control, when I add it to source control this error occure My VSCT File: <?xml version="1.0" encoding="utf-8"?> <CommandTable xmlns="http://schemas.microsoft.com/VisualStudio/2005-10-18/CommandTable" xmlns:xs="http://www.w3.org/2001/XMLSchema"> <Extern href="stdidcmd.h"/> <Extern href="vsshlids.h"/> <Extern href="msobtnid.h"/> <Commands package="guidCaranePackagePkg"> <Menus> <Menu guid="guidCaranePackageCmdSet" id="CaraneMainMenu" type="Menu" priority="0x0113"> <Parent guid="guidSHLMainMenu" id="IDG_VS_MM_TOOLSADDINS" /> <Strings> <ButtonText>Carane</ButtonText> <CommandName>Carane</CommandName> </Strings> </Menu> </Menus> <Groups> <Group guid="guidCaranePackageCmdSet" id="MyMenuGroup" priority="0x0600"> <Parent guid="guidCaranePackageCmdSet" id="CaraneMainMenu"/> </Group> </Groups> <Buttons> <Button guid="guidCaranePackageCmdSet" id="cmdidCaraneCommand" priority="0x0100" type="Button"> <Parent guid="guidCaranePackageCmdSet" id="MyMenuGroup" /> <Icon guid="guidImages" id="bmpPic1" /> <Strings> <CommandName>cmdidCaraneCommand</CommandName> <ButtonText>Set Refrence Path</ButtonText> </Strings> </Button> <Button guid="guidCaranePackageCmdSet" id="CaranePackage2" priority="0x0200" type="Button"> <Parent guid="guidCaranePackageCmdSet" id="MyMenuGroup" /> <Icon guid="guidImages" id="bmpPic1" /> <Strings> <CommandName>SmartPart</CommandName> <ButtonText>Smart Service</ButtonText> </Strings> </Button> <Button guid="guidCaranePackageCmdSet" id="CaranePackage3" priority="0x0300" type="Button"> <Parent guid="guidCaranePackageCmdSet" id="MyMenuGroup" /> <Icon guid="guidImages" id="bmpPic1" /> <Strings> <CommandName>Register</CommandName> <ButtonText>Register</ButtonText> </Strings> </Button> <Button guid="guidCaranePackageCmdSet" id="CaranePackage3" priority="0x0300" type="Button"> <Parent guid="guidCaranePackageCmdSet" id="MyMenuGroup" /> <Icon guid="guidImages" id="bmpPic1" /> <Strings> <CommandName>Register</CommandName> <ButtonText>Register</ButtonText> </Strings> </Button> <Button guid="guidCaranePackageCmdSet" id="CaranePackage4" priority="0x0400" type="Button"> <Parent guid="guidCaranePackageCmdSet" id="MyMenuGroup" /> <Icon guid="guidImages" id="bmpPic1" /> <Strings> <CommandName>FillResources</CommandName> <ButtonText>Fill Resources</ButtonText> </Strings> </Button> </Buttons> <Bitmaps> <Bitmap guid="guidImages" href="Resources\Images_32bit.bmp" usedList="bmpPic1, bmpPic2, bmpPicSearch, bmpPicX, bmpPicArrows"/> </Bitmaps> </Commands> <Symbols> <GuidSymbol name="guidCaranePackagePkg" value="{d55593d2-8500-486d-9a5c-e8f00f43f592}" /> <GuidSymbol name="guidCaranePackageCmdSet" value="{9d99e548-a4f9-4eee-ba5a-c561292f3794}"> <IDSymbol name="MyMenuGroup" value="0x1020" /> <IDSymbol name="cmdidCaraneCommand" value="0x0100" /> <IDSymbol name="CaraneMainMenu" value="0x0150"/> <IDSymbol name="CaranePackage2" value="0x0200"/> <IDSymbol name="CaranePackage3" value="0x0300"/> <IDSymbol name="CaranePackage4" value="0x400"/> <IDSymbol name ="ShortcutMenu" value="0x0001"/> </GuidSymbol> <GuidSymbol name="guidImages" value="{bb76ad3c-8441-4166-b6ef-dbaf2775b85e}" > <IDSymbol name="bmpPic1" value="1" /> <IDSymbol name="bmpPic2" value="2" /> <IDSymbol name="bmpPicSearch" value="3" /> <IDSymbol name="bmpPicX" value="4" /> <IDSymbol name="bmpPicArrows" value="5" /> </GuidSymbol> </Symbols> </CommandTable> Thanks Afshin
    Sunday, March 21, 2010 10:04 PM