android报错,大神来看一下

求大神给我看一下

 java.lang.RuntimeException: Unable to start activity ComponentInfo{com.anew/com.anew.MainActivity}: java.lang.IllegalStateException: This Activity already has an action bar supplied by the window decor. Do not request Window.FEATURE_SUPPORT_ACTION_BAR and set windowActionBar to false in your theme to use a Toolbar instead.
    at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2688)
    at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2749)
    at android.app.ActivityThread.-wrap12(ActivityThread.java)
    at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1498)
    at android.os.Handler.dispatchMessage(Handler.java:102)
    at android.os.Looper.loop(Looper.java:160)
    at android.app.ActivityThread.main(ActivityThread.java:6197)
    at java.lang.reflect.Method.invoke(Native Method)
    at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:874)
    at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:764)
Caused by: java.lang.IllegalStateException: This Activity already has an action bar supplied by the window decor. Do not request Window.FEATURE_SUPPORT_ACTION_BAR and set windowActionBar to false in your theme to use a Toolbar instead.
    at android.support.v7.app.AppCompatDelegateImplV9.setSupportActionBar(AppCompatDelegateImplV9.java:207)
    at android.support.v7.app.AppCompatActivity.setSupportActionBar(AppCompatActivity.java:130)
    at com.anew.MainActivity.onCreate(MainActivity.java:19)
    at android.app.Activity.performCreate(Activity.java:6736)
    at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1119)
    at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2641)
    ... 9 more

4个回答

由于Activity已存在ActionBar,所以使用Toolbar进行替换时出错.你可以换主题也可以增加values资源文件

楼上的链接讲的很详细了

是自定义theme时遇见的吗?你看看你的Activity是不是继承自app。。。Activity,改成继承自Activity

Csdn user default icon
上传中...
上传图片
插入图片
抄袭、复制答案,以达到刷声望分或其他目的的行为,在CSDN问答是严格禁止的,一经发现立刻封号。是时候展现真正的技术了!
其他相关推荐
大神来看一下
if(p&&p->empty)这段代码什么意思
程序报错,来看一下
我的一个C语言程序,在Linux环境下可以编译通过并运行,但在windows下的netbeans环境中,就报错了,代码如下rn在文件的开头是这样的rnint N; rnint stuNum;rnrnstruct sturn int id;rn char *name;rn int sex; //0rn int age;rn double english;rn double chinese;rn double math;rn;rnrntypedef struct stu STU;rn然后下面有个排序的函数rnvoid sortStuByEnglish(STU arr[][stuNum],int classNum)rnrn int i,j;rn for(i=1; i=i; j--)rn rn if(arr[classNum][j-1].english > arr[classNum][j].english) //这是第90行,在这一行标红并报错rn rn STU temp;rn temp = arr[classNum][j];rn arr[classNum][j] = arr[classNum][j-1];rn arr[classNum][j-1] = temp;rn rn rn rn printf("按英语成绩从小到大输出:\n");rn for(i=0; i for instructions.rnmake[2]: *** [build/MyNewConfig/Cygwin-Windows/project1.o] 错误 1rnmake[1]: *** [.build-conf] 错误 2rnmake: *** [.build-impl] 错误 2rnrnBUILD FAILED (exit value 2, total time: 6s)
大神们来看一下啊
很抱歉,给大家看一段程序,有时间的麻烦帮解决一下问题rn是有关内存不能为read的问题 我看了好久,没有发现问题出现在哪里 rn//郝夫曼树的建立及编码rn#includern#includern#includern#define overflow -2rntypedef structrn char ch;rn unsigned int weight;//结点的权值rn unsigned int parent,lchild,rchild;rnHTNode,*HuffmanTree;//动态分配数组存储郝夫曼树rntypedef char **HuffmanCode;//动态分配数组存储郝夫曼编码表rn//***************rnvoid Select(HuffmanTree T,int n,int &s1,int &s2);//声明Select函数rn//........*************...............rnvoid HuffmanCoding(HuffmanTree &HT,HuffmanCode &HC,int *w,int n)rn //w存放n个字符的权值,构造郝夫曼树HT,并求出n个字符的郝夫曼编码HC.rn if(n<=1) return;rn int m=2*n-1;rn HT=(HuffmanTree)malloc((m+1)*sizeof(HTNode));//0号单元未用rn if(!HT) exit(overflow);rn (HT+1)->ch=' ';//空格rn (HT+1)->weight=186;rn rn HuffmanTree p=NULL;rn int i;rn char c;rn for(p=HT+2,i=1,c='a';i<=n;++i,++p,++w,++c)rn rn p->ch=c;rn p->weight=*(w+1);rn p->lchild=p->parent=p->rchild=0;rn rn //初始化郝夫曼树rn //rn //建造郝夫曼树rn int s1,s2;rn for(int i=n+1;i<=m;++i)rn rn Select(HT,i-1,s1,s2);rn HT[s1].parent=i;HT[s2].parent=i;rn HT[i].lchild=s1;HT[i].rchild=s2;rn HT[i].weight=HT[s1].weight+HT[s2].weight;rn rn //...从叶子到根逆向求每个字符的郝夫曼编码...rn HC=(HuffmanCode)malloc((n+1)*sizeof(char*));rn char *cd=(char*)malloc(n*sizeof(char));rn HC[0]="\0";rn cd[n-1]='\0';rn int k;rn for(k=1;k<=n;++k)rn rn int start=n-1;rn int c,f;rn for(c=k,f=HT[k].parent;f!=0;c=f,f=HT[f].parent)rn rn if(HT[f].lchild==c) rn cd[--start]='0';rn elsern cd[--start]='1';rn HC[k]=(char*)malloc((n-start)*sizeof(char));rn strcpy(HC[k],&cd[start]);rn rn free(cd);rn rnrn //rn //....Select函数.....rn void Select(HuffmanTree T,int n,int &s1,int &s2)rn rn s1=1;rn for(int i=1;i<=n;++i)rn rn if(T[s1].weight>T[i].weight)rn s1=i;rn rn s2=1;rn for(int j=1;j<=n;j++)rn rn if(s2==s1)rn rn s2=j-2;rn continue;rn rn elsern rn if(T[s2].weight>T[j].weight)rn s2=j;rn rn rn rn //rn //...主函数....rn void main()rn rn HuffmanTree HT=NULL;//郝夫曼树存储空间的头指针rn HuffmanCode HC=NULL;//存放每位字符的编码rn int w[27];rn w[0]=186;rn char c='a';rn int j;rn for(j=1;j<27;j++)rn rn printf("%c :",c++);rn scanf("%d",&w[j]);rn getchar();rn rn HuffmanCoding(HT,HC,w,27);rn char *str="this program is my favorite";rn printf("'this program is my favorite'的郝夫曼编码为:\n");rn char *q;rn for(q=str;*q!='\0';q++)rn rn if(*q==' ')rn rn printf("%s",HC[1]);rn rn elsern rn printf("%s ",HC[*q-95]);rn rn rn rnrn rnrnrnrnrnrnrnrnrnrnrnrnrnrn
大神来看~~!
这是什么错误啊??rn at ch1.TableModel.setQuery(TableModel.java:91)rn at ch1.TableModel.setQuery(TableModel.java:91)rn at ch1.TableModel.setQuery(TableModel.java:91)rn at ch1.TableModel.setQuery(TableModel.java:91)rn at ch1.TableModel.setQuery(TableModel.java:91)rn at ch1.TableModel.setQuery(TableModel.java:91)rn at ch1.TableModel.setQuery(TableModel.java:91)rn at ch1.TableModel.setQuery(TableModel.java:91)rn at ch1.TableModel.setQuery(TableModel.java:91)rn at ch1.TableModel.setQuery(TableModel.java:91)rn at ch1.TableModel.setQuery(TableModel.java:91)rn at ch1.TableModel.setQuery(TableModel.java:91)rn at ch1.TableModel.setQuery(TableModel.java:91)rn at ch1.TableModel.setQuery(TableModel.java:91)rn at ch1.TableModel.(TableModel.java:15)rn at ch1.TablePanel.(TablePanel.java:23)rn at ch1.StudentView.(StudentView.java:6)rn at ch1.StudentView.main(StudentView.java:123)rncom.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'fromStudentInfor' at line 1rn at sun.reflect.GeneratedConstructorAccessor8.newInstance(Unknown Source)rn at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(Unknown Source)rn at java.lang.reflect.Constructor.newInstance(Unknown Source)rn at com.mysql.jdbc.Util.handleNewInstance(Util.java:408)rn at com.mysql.jdbc.Util.getInstance(Util.java:383)rn at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:1062)rn at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:4226)rn at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:4158)rn at com.mysql.jdbc.MysqlIO.sendCommand(MysqlIO.java:2615)rn at com.mysql.jdbc.MysqlIO.sqlQueryDirect(MysqlIO.java:2776)rn at com.mysql.jdbc.ConnectionImpl.execSQL(ConnectionImpl.java:2834)rn at com.mysql.jdbc.ConnectionImpl.execSQL(ConnectionImpl.java:2783)rn at com.mysql.jdbc.StatementImpl.executeQuery(StatementImpl.java:1569)rn at ch1.TableModel.setQuery(TableModel.java:66)rn at ch1.TableModel.setQuery(TableModel.java:91)rn at ch1.TableModel.setQuery(TableModel.java:91)rn at ch1.TableModel.setQuery(TableModel.java:91)rn at ch1.TableModel.setQuery(TableModel.java:91)rn at ch1.TableModel.setQuery(TableModel.java:91)rn at ch1.TableModel.setQuery(TableModel.java:91)rn at ch1.TableModel.setQuery(TableModel.java:91)rn at ch1.TableModel.setQuery(TableModel.java:91)rn at ch1.TableModel.setQuery(TableModel.java:91)rn at ch1.TableModel.setQuery(TableModel.java:91)rn at ch1.TableModel.setQuery(TableModel.java:91)rn at ch1.TableModel.setQuery(TableModel.java:91)rn at ch1.TableModel.(TableModel.java:15)rn at ch1.TablePanel.(TablePanel.java:23)rn at ch1.StudentView.(StudentView.java:6)rn at ch1.StudentView.main(StudentView.java:123)rncom.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'fromStudentInfor' at line 1rn at sun.reflect.GeneratedConstructorAccessor8.newInstance(Unknown Source)rn at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(Unknown Source)rn at java.lang.reflect.Constructor.newInstance(Unknown Source)rn at com.mysql.jdbc.Util.handleNewInstance(Util.java:408)rn at com.mysql.jdbc.Util.getInstance(Util.java:383)rn at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:1062)rn at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:4226)rn at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:4158)rn at com.mysql.jdbc.MysqlIO.sendCommand(MysqlIO.java:2615)rn at com.mysql.jdbc.MysqlIO.sqlQueryDirect(MysqlIO.java:2776)rn at com.mysql.jdbc.ConnectionImpl.execSQL(ConnectionImpl.java:2834)rn at com.mysql.jdbc.ConnectionImpl.execSQL(ConnectionImpl.java:2783)rn at com.mysql.jdbc.StatementImpl.executeQuery(StatementImpl.java:1569)rn at ch1.TableModel.setQuery(TableModel.java:66)rn at ch1.TableModel.setQuery(TableModel.java:91)rn at ch1.TableModel.setQuery(TableModel.java:91)rn at ch1.TableModel.setQuery(TableModel.java:91)rn at ch1.TableModel.setQuery(TableModel.java:91)rn at ch1.TableModel.setQuery(TableModel.java:91)rn at ch1.TableModel.setQuery(TableModel.java:91)rn at ch1.TableModel.setQuery(TableModel.java:91)rn at ch1.TableModel.setQuery(TableModel.java:91)rn at ch1.TableModel.setQuery(TableModel.java:91)rn at ch1.TableModel.setQuery(TableModel.java:91)rn at ch1.TableModel.setQuery(TableModel.java:91)rn at ch1.TableModel.setQuery(TableModel.java:91)rn at ch1.TableModel.setQuery(TableModel.java:91)rn at ch1.TableModel.setQuery(TableModel.java:91)rn at ch1.TableModel.setQuery(TableModel.java:91)rn at ch1.TableModel.setQuery(TableModel.java:91)rn at ch1.TableModel.setQuery(TableModel.java:91)rn at ch1.TableModel.setQuery(TableModel.java:91)rn at ch1.TableModel.setQuery(TableModel.java:91)rn at ch1.TableModel.setQuery(TableModel.java:91)rn at ch1.TableModel.setQuery(TableModel.java:91)rn at ch1.TableModel.setQuery(TableModel.java:91)rn at ch1.TableModel.setQuery(TableModel.java:91)rn at ch1.TableModel.setQuery(TableModel.java:91)
做过android串口通信的来看一下!
Google官网给的那个android串口通信程序现在能够发送数据,但是接受不到数据! try { byte[] buffer = new byte[64]; if (mInputStream == null) return; size = mInputStream.read(buffer); if (size > 0) { on
post数据总有问题,大神来看一下
出错基本都是出现在3G信号变化的时候。我的手机开启数据连接之后就出现一个H+的标志,如果没有数据流动,这个标志会自动切换到H,加号没有了,有数据流动的时候又变为H+。问题就出现在H标志时,当我post数据时,立刻产生一个异常sendto failed: ECONNRESET,有时候是timeout异常。连接的图标没有闪烁——貌似根本就没有数据发出去就产生异常了,好了,这个时候我再点击登录,程序再post一次数据,这下立马ok了,只要之前有数据流出过网络,貌似我的登录就是正常的,没有数据静止一段时间又出错。用的是HttpUrlConnectionrnrn很诡异啊,之前用wifi调试的时候好像没遇到过这样的问题。
MyEclipse 报错,大家来看一下啊.
我用 Myeclipse 3.8 + Eclipse3.1M5 开发,但是在对MyEclipse进行设置的时候,总是报错,也不能新Struts和EJB工程. rn错误信息如下:rnrnENTRY org.eclipse.jface 4 2 2005-04-13 11:20:57.93rn!MESSAGE Problems occurred when invoking code from plug-in: "org.eclipse.jface".rn!STACK 0rnjava.lang.NoClassDefFoundError: org/eclipse/jdt/internal/ui/util/TabFolderLayoutrn at java.lang.Class.getDeclaredConstructors0(Native Method)rn at java.lang.Class.privateGetDeclaredConstructors(Unknown Source)rn at java.lang.Class.getConstructor0(Unknown Source)rn at java.lang.Class.newInstance0(Unknown Source)rn at java.lang.Class.newInstance(Unknown Source)rn at org.eclipse.core.internal.registry.ConfigurationElement.createExecutableExtension(ConfigurationElement.java:172)rn at org.eclipse.core.internal.registry.ConfigurationElement.createExecutableExtension(ConfigurationElement.java:152)rn at org.eclipse.core.internal.registry.ConfigurationElement.createExecutableExtension(ConfigurationElement.java:139)rn at org.eclipse.core.internal.registry.ConfigurationElementHandle.createExecutableExtension(ConfigurationElementHandle.java:48)rn at org.eclipse.ui.internal.WorkbenchPlugin.createExtension(WorkbenchPlugin.java:225)rn at org.eclipse.ui.internal.dialogs.WorkbenchPreferenceNode.createPage(WorkbenchPreferenceNode.java:46)rn at org.eclipse.jface.preference.PreferenceDialog.createPage(PreferenceDialog.java:1196)rn at org.eclipse.ui.internal.dialogs.FilteredPreferenceDialog.createPage(FilteredPreferenceDialog.java:246)rn at org.eclipse.jface.preference.PreferenceDialog.showPage(PreferenceDialog.java:1095)rn at org.eclipse.ui.internal.dialogs.WorkbenchPreferenceDialog.showPage(WorkbenchPreferenceDialog.java:440)rn at org.eclipse.jface.preference.PreferenceDialog$9.selectionChanged(PreferenceDialog.java:618)rn at org.eclipse.jface.viewers.StructuredViewer$3.run(StructuredViewer.java:680)rn at org.eclipse.core.internal.runtime.InternalPlatform.run(InternalPlatform.java:1021)rn at org.eclipse.core.runtime.Platform.run(Platform.java:757)rn at org.eclipse.ui.internal.JFaceUtil$1.run(JFaceUtil.java:40)rn at org.eclipse.jface.util.SafeRunnable.run(SafeRunnable.java:148)rn at org.eclipse.jface.viewers.StructuredViewer.firePostSelectionChanged(StructuredViewer.java:678)rn at org.eclipse.jface.viewers.StructuredViewer.handlePostSelect(StructuredViewer.java:949)rn at org.eclipse.jface.viewers.StructuredViewer$5.widgetSelected(StructuredViewer.java:969)rn at org.eclipse.jface.util.OpenStrategy.firePostSelectionEvent(OpenStrategy.java:231)rn at org.eclipse.jface.util.OpenStrategy.access$4(OpenStrategy.java:226)rn at org.eclipse.jface.util.OpenStrategy$3.run(OpenStrategy.java:392)rn at org.eclipse.swt.widgets.RunnableLock.run(RunnableLock.java:35)rn at org.eclipse.swt.widgets.Synchronizer.runAsyncMessages(Synchronizer.java:118)rn at org.eclipse.swt.widgets.Display.runAsyncMessages(Display.java:2871)rn at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:2530)rn at org.eclipse.jface.window.Window.runEventLoop(Window.java:803)rn at org.eclipse.jface.window.Window.open(Window.java:781)rn at org.eclipse.ui.internal.OpenPreferencesAction.run(OpenPreferencesAction.java:66)rn at org.eclipse.jface.action.Action.runWithEvent(Action.java:996)rn at org.eclipse.jface.action.ActionContributionItem.handleWidgetSelection(ActionContributionItem.java:538)rn at org.eclipse.jface.action.ActionContributionItem.access$2(ActionContributionItem.java:488)rn at org.eclipse.jface.action.ActionContributionItem$5.handleEvent(ActionContributionItem.java:400)rn at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:82)rn at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:842)rn at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java:2894)rn at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:2527)rn at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java:1570)rn at org.eclipse.ui.internal.Workbench.runUI(Workbench.java:1534)rn at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:306)rn at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:143)rn at org.eclipse.ui.internal.ide.IDEApplication.run(IDEApplication.java:103)rn at org.eclipse.core.internal.runtime.PlatformActivator$1.run(PlatformActivator.java:228)rn at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:344)rn at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:156)rn at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)rn at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)rn at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)rn at java.lang.reflect.Method.invoke(Unknown Source)rn at org.eclipse.core.launcher.Main.invokeFramework(Main.java:315)rn at org.eclipse.core.launcher.Main.basicRun(Main.java:268)rn at org.eclipse.core.launcher.Main.run(Main.java:942)rn at org.eclipse.core.launcher.Main.main(Main.java:926)rnrn请各位帮帮忙啊. rn
Android studio报错,求助大神
E:\AndroidStudio\AndroidStudioworkspaces\MyApplication\okhttp\build\intermediates\res\merged\debug\values-v24\values-v24.xmlrnError:(3) Error retrieving parent for item: No resource found that matches the given name 'android:TextAppearance.Material.Widget.Button.Borderless.Colored'.rnError:(4) Error retrieving parent for item: No resource found that matches the given name 'android:TextAppearance.Material.Widget.Button.Colored'.rnError:Execution failed for task ':okhttp:processDebugResources'.rn> com.android.ide.common.process.ProcessException: org.gradle.process.internal.ExecException: Process 'command 'E:\AndroidStudio\android-sdk-r24.4.1\android-sdk-windows\build-tools\24.0.0\aapt.exe'' finished with non-zero exit value 1rnrn下面是values-v24.xml内容rnrnrn```rn rnrn rn <style name="Base.TextAppearance.AppCompat.Widget.Button.Colored" parent="android:TextAppearance.Material.Widget.Button.Colored"/>rn <style name="TextAppearance.AppCompat.Notification.Info.Media"/>rn <style name="TextAppearance.AppCompat.Notification.Media"/>rn <style name="TextAppearance.AppCompat.Notification.Time.Media"/>rn <style name="TextAppearance.AppCompat.Notification.Title.Media"/>rn</resources>rn```rn下面是gradle文件rnrnrn```rn apply plugin: 'com.android.application'rnrnandroid rn compileSdkVersion 24rn buildToolsVersion "24.0.0"rnrn defaultConfig rn applicationId "myapp.czw.com.ceshi"rn minSdkVersion 16rn targetSdkVersion 24rn versionCode 1rn versionName "1.0"rn rn buildTypes rn release rn minifyEnabled falsern proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'rn rn rnrnrndependencies rn compile fileTree(include: ['*.jar'], dir: 'libs')rn testCompile 'junit:junit:4.12'rn compile 'com.android.support:appcompat-v7:24.0.0'rn compile 'com.squareup.okhttp:okhttp:2.4.0'rn compile 'org.xutils:xutils:3.3.38'rn compile 'com.zhy:percent-support-extends:1.0.1'rn //百分比布局rn compile 'com.squareup.picasso:picasso:+'rn //圆形图片rn compile 'de.hdodenhof:circleimageview:2.1.0'rn compile 'fm.jiecao:jiecaovideoplayer:5.5'rnrnrn```rnrn
来看一下
兄弟能告诉小弟JNDI的JAR包在哪里能找到吗
跪求大神来看!!!
[img=https://img-bbs.csdn.net/upload/201404/24/1398332109_270166.png][/img]rn[img=https://img-bbs.csdn.net/upload/201404/24/1398332118_238088.png][/img]rn[img=https://img-bbs.csdn.net/upload/201404/24/1398332129_32038.png][/img]
大神来看一哈
** 发现 5 个已存在的 RPM 数据库问题, 'yum check' 输出如下:rnicedtea-web-1.6.2-4.el7.x86_64 有缺少的需求 java-1.8.0-openjdkrnjline-1.0-8.el7.noarch 有缺少的需求 java >= ('0', '1.5', None)rnlibvlc5-3.0.1-1.mga7.i586 有缺少的需求 libpulse.so.0rnlibvlc5-3.0.1-1.mga7.i586 有缺少的需求 libpulse.so.0(PULSE_0)rnlibvlc5-3.0.1-1.mga7.i586 有缺少的需求 libvlccore.so.9rnrnyum install vlc 提示我这个, 咋整
大神来看一看呀
我这个是哪里错了,我找了好久都没有找出来,大神看看嘛[img=https://forum.csdn.net/PointForum/ui/scripts/csdn/Plugin/001/face/15.gif][/img][img=https://img-bbs.csdn.net/upload/201705/03/1493791837_678687.jpg][/img]
大神,大仙来看看吧...
对于c语言的模块化问题rnrnNode.c中代码。rn[code=C/C++]rn#include rnrnvoid Dis()rnrn int year;rn printf("Please input the year:\n");rn scanf("%d",&year);rn Year(year);rnrnrnvoid Year(int year)rnrn printf("The year you input is: \n");rn printf("%d\n",year);rnrn[/code]rnrnMain.c中代码。。。rn[code=C/C++]rn#include rnextern void Dis();rnextern void Year(int year);rnrnint main()rnrn Dis();rn return 0;rnrnrn[/code]rnrn我想问,为什么这样调用就不对呢?
大神,来看看吧
BIEE启动服务显示一直在启动rnrn打开页面出现这个问题rnError 500--Internal Server Error rnFrom RFC 2068 Hypertext Transfer Protocol -- HTTP/1.1:rn10.5.1 500 Internal Server ErrorrnThe server encountered an unexpected condition which prevented it from fulfilling the request.rn rn这个问题怎么解决?
程序运行时报错 ,请大神指导一下
下面程序通过kinect读取的数据,转换成点云后进行分割rn程序编译通过了,但是运行时提示vector subscript out of range ,请问该如何修改?rnrn#include rn#include rn#include rn#include rn#include rn#include rn#include rn#include rn#include rn#include rn#include rn#include rnrnusing namespace std;rnusing namespace xn;rnrnstruct SColorPoint3D rn rn float X; rn float Y; rn float Z; rn float R; rn float G; rn float B; rnrn SColorPoint3D( XnPoint3D pos, XnRGB24Pixel color ) rn rn X = pos.X; rn Y = pos.Y; rn Z = pos.Z; rn R = (float)color.nRed / 255; rn G = (float)color.nGreen / 255; rn B = (float)color.nBlue / 255; rn rn; rnrnvoid GeneratePointCloud( DepthGenerator& rDepthGen, rn const XnDepthPixel* pDepth, rn const XnRGB24Pixel* pImage, rn vector& vPointCloud ) rn rn // number of point is the number of 2D image pixel rn DepthMetaData mDepthMD; rn rDepthGen.GetMetaData( mDepthMD ); rn unsigned int uPointNum = mDepthMD.FullXRes() * mDepthMD.FullYRes(); rnrn // build the data structure for convert rn XnPoint3D* pDepthPointSet = new XnPoint3D[ uPointNum ]; rn unsigned int i, j, idxShift, idx; rn for( j = 0; j < mDepthMD.FullYRes(); ++j ) rn rn idxShift = j * mDepthMD.FullXRes(); rn for( i = 0; i < mDepthMD.FullXRes(); ++i ) rn rn idx = idxShift + i; rn pDepthPointSet[idx].X = i; rn pDepthPointSet[idx].Y = j; rn pDepthPointSet[idx].Z = pDepth[idx]; rn rn rnrn // un-project points to real world rn XnPoint3D* p3DPointSet = new XnPoint3D[ uPointNum ]; rn rDepthGen.ConvertProjectiveToRealWorld( uPointNum, pDepthPointSet, p3DPointSet ); rn delete[] pDepthPointSet; rnrn // build point cloud rn for( i = 0; i < uPointNum; ++ i ) rn rn // skip the depth 0 points rn if( p3DPointSet[i].Z == 0 ) rn continue; rnrn vPointCloud.push_back( SColorPoint3D( p3DPointSet[i], pImage[i] ) ); rn rn delete[] p3DPointSet; rn rnrntypedef pcl::PointXYZ PointT;rnrnint main(int argc,char** argv)rnrn XnStatus eResult = XN_STATUS_OK; rn int i = 0; rnrn // init rn Context mContext; rn eResult = mContext.Init(); rnrn DepthGenerator mDepthGenerator; rn eResult = mDepthGenerator.Create(mContext); rn ImageGenerator mImageGenerator; rn eResult = mImageGenerator.Create(mContext); rnrn // set output mode rn XnMapOutputMode mapMode; rn mapMode.nXRes = XN_VGA_X_RES; rn mapMode.nYRes = XN_VGA_Y_RES; rn mapMode.nFPS = 30; rn eResult = mDepthGenerator.SetMapOutputMode(mapMode); rn eResult = mImageGenerator.SetMapOutputMode(mapMode); rnrn // start generating rn eResult = mContext.StartGeneratingAll(); rnrn // read data rn vector vPointCloud; rn while ( !xnOSWasKeyboardHit() ) rn rn eResult = mContext.WaitNoneUpdateAll(); rn // get the depth map rn const XnDepthPixel* pDepthMap = mDepthGenerator.GetDepthMap(); rnrn // get the image map rn const XnRGB24Pixel* pImageMap = mImageGenerator.GetRGB24ImageMap(); rnrn // generate point cloud rn vPointCloud.clear(); rn GeneratePointCloud(mDepthGenerator, pDepthMap, pImageMap, vPointCloud ); rn rn // All the objects neededrn //pcl::PCDReader reader;rn pcl::PassThrough pass;rn pcl::NormalEstimation ne;rn pcl::SACSegmentationFromNormals seg; rn //pcl::PCDWriter writer;rn pcl::ExtractIndices extract;rn pcl::ExtractIndices extract_normals;rn pcl::search::KdTree::Ptr tree (new pcl::search::KdTree ());rnrn // Datasetsrn pcl::PointCloud::Ptr cloud (new pcl::PointCloud);rn pcl::PointCloud::Ptr cloud_filtered (new pcl::PointCloud);rn pcl::PointCloud::Ptr cloud_normals (new pcl::PointCloud);rn pcl::PointCloud::Ptr cloud_filtered2 (new pcl::PointCloud);rn pcl::PointCloud::Ptr cloud_normals2 (new pcl::PointCloud);rn pcl::ModelCoefficients::Ptr coefficients_plane (new pcl::ModelCoefficients), coefficients_cylinder (new pcl::ModelCoefficients);rn pcl::PointIndices::Ptr inliers_plane (new pcl::PointIndices), inliers_cylinder (new pcl::PointIndices);rnrn //fill the data cloudrn cloud->width = 640;rn cloud->height = 480;rn cloud->points.resize( cloud->width* cloud->height);rnrn for(size_t i=0;ipoints.size();++i)rn rn cloud->points[i].x=vPointCloud[i].X;rn cloud->points[i].y=vPointCloud[i].Y;rn cloud->points[i].z=vPointCloud[i].Z;rn rnrnrn // Read in the cloud datarn //reader.read ("table_scene_mug_stereo_textured.pcd", *cloud);rn std::cerr << "PointCloud has: " << cloud->points.size () << " data points." << std::endl;rnrn // Build a passthrough filter to remove spurious NaNsrn pass.setInputCloud (cloud);rn pass.setFilterFieldName ("z");rn pass.setFilterLimits (0, 1.5);rn pass.filter (*cloud_filtered);rn std::cerr << "PointCloud after filtering has: " << cloud_filtered->points.size () << " data points." << std::endl;rnrn // Estimate point normalsrn ne.setSearchMethod (tree);rn ne.setInputCloud (cloud_filtered);rn ne.setKSearch (50);rn ne.compute (*cloud_normals);rnrn // Create the segmentation object for the planar model and set all the parametersrn seg.setOptimizeCoefficients (true);rn seg.setModelType (pcl::SACMODEL_NORMAL_PLANE);rn seg.setNormalDistanceWeight (0.1);rn seg.setMethodType (pcl::SAC_RANSAC);rn seg.setMaxIterations (100);rn seg.setDistanceThreshold (0.03);rn seg.setInputCloud (cloud_filtered);rn seg.setInputNormals (cloud_normals);rn // Obtain the plane inliers and coefficientsrn seg.segment (*inliers_plane, *coefficients_plane);rn std::cerr << "Plane coefficients: " << *coefficients_plane << std::endl;rnrn // Extract the planar inliers from the input cloudrn extract.setInputCloud (cloud_filtered);rn extract.setIndices (inliers_plane);rn extract.setNegative (false);rnrn // Write the planar inliers to diskrn pcl::PointCloud::Ptr cloud_plane (new pcl::PointCloud ());rn extract.filter (*cloud_plane);rn std::cerr << "PointCloud representing the planar component: " << cloud_plane->points.size () << " data points." << std::endl;rn //writer.write ("table_scene_mug_stereo_textured_plane.pcd", *cloud_plane, false);rnrn // Remove the planar inliers, extract the restrn extract.setNegative (true);rn extract.filter (*cloud_filtered2);rn extract_normals.setNegative (true);rn extract_normals.setInputCloud (cloud_normals);rn extract_normals.setIndices (inliers_plane);rn extract_normals.filter (*cloud_normals2);rnrn // Create the segmentation object for cylinder segmentation and set all the parametersrn seg.setOptimizeCoefficients (true);rn seg.setModelType (pcl::SACMODEL_CYLINDER);rn seg.setMethodType (pcl::SAC_RANSAC);rn seg.setNormalDistanceWeight (0.1);rn seg.setMaxIterations (10000);rn seg.setDistanceThreshold (0.05);rn seg.setRadiusLimits (0, 0.1);rn seg.setInputCloud (cloud_filtered2);rn seg.setInputNormals (cloud_normals2);rnrn // Obtain the cylinder inliers and coefficientsrn seg.segment (*inliers_cylinder, *coefficients_cylinder);rn std::cerr << "Cylinder coefficients: " << *coefficients_cylinder << std::endl;rnrn // Write the cylinder inliers to diskrn extract.setInputCloud (cloud_filtered2);rn extract.setIndices (inliers_cylinder);rn extract.setNegative (false);rn pcl::PointCloud::Ptr cloud_cylinder (new pcl::PointCloud ());rn extract.filter (*cloud_cylinder);rn if (cloud_cylinder->points.empty ()) rn std::cerr << "Can't find the cylindrical component." << std::endl;rn elsern rn std::cerr << "PointCloud representing the cylindrical component: " << cloud_cylinder->points.size () << " data points." << std::endl;rn //writer.write ("table_scene_mug_stereo_textured_cylinder.pcd", *cloud_cylinder, false);rn rn // print point cloud rn /*cout.flags(ios::left); //Left-aligned rn cout << "Point number: " << vPointCloud.size() << endl; rn for(i=0;i
tomcat突然报错,大神解救一下 啊
启动报错信息如下:rn2016-11-22 09:37:36|localhost-startStop-1|ERROR|ContextLoader.java|308|Context initialization failedrnorg.springframework.beans.factory.BeanCreationException: Error creating bean with name 'sqlMapClient' defined in class path resource [tkfconfig/spring/context-base.xml]: Invocation of init method failed; nested exception is org.springframework.core.NestedIOException: Failed to parse config resource: class path resource [tkfconfig/ibatis/SqlMapConfig.xml]; nested exception is com.ibatis.common.xml.NodeletException: Error parsing XML. Cause: java.lang.RuntimeException: Error parsing XPath '/sqlMapConfig/sqlMap'. Cause: com.ibatis.common.xml.NodeletException: Error parsing XML. Cause: java.lang.RuntimeException: Error parsing XPath '/sqlMap/select'. Cause: com.ibatis.sqlmap.client.SqlMapException: There is no result map named information_space.diafavorite in this SqlMap.rn at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1455) ~[org.springframework.beans-3.1.1.RELEASE.jar:3.1.1.RELEASE]rn at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:519) ~[org.springframework.beans-3.1.1.RELEASE.jar:3.1.1.RELEASE]rn at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:456) ~[org.springframework.beans-3.1.1.RELEASE.jar:3.1.1.RELEASE]rn at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:294) ~[org.springframework.beans-3.1.1.RELEASE.jar:3.1.1.RELEASE]rn at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:225) ~[org.springframework.beans-3.1.1.RELEASE.jar:3.1.1.RELEASE]rn at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:291) ~[org.springframework.beans-3.1.1.RELEASE.jar:3.1.1.RELEASE]rn at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:193) ~[org.springframework.beans-3.1.1.RELEASE.jar:3.1.1.RELEASE]rn at org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:567) ~[org.springframework.beans-3.1.1.RELEASE.jar:3.1.1.RELEASE]rn at org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:913) ~[org.springframework.context-3.1.1.RELEASE.jar:3.1.1.RELEASE]rn at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:464) ~[org.springframework.context-3.1.1.RELEASE.jar:3.1.1.RELEASE]rn at org.springframework.web.context.ContextLoader.configureAndRefreshWebApplicationContext(ContextLoader.java:385) ~[org.springframework.web-3.1.1.RELEASE.jar:3.1.1.RELEASE]rn at org.springframework.web.context.ContextLoader.initWebApplicationContext(ContextLoader.java:284) ~[org.springframework.web-3.1.1.RELEASE.jar:3.1.1.RELEASE]rn at org.springframework.web.context.ContextLoaderListener.contextInitialized(ContextLoaderListener.java:111) [org.springframework.web-3.1.1.RELEASE.jar:3.1.1.RELEASE]rn at org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:4992) [catalina.jar:7.0.55]rn at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5490) [catalina.jar:7.0.55]rn at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150) [catalina.jar:7.0.55]rn at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:901) [catalina.jar:7.0.55]rn at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:877) [catalina.jar:7.0.55]rn at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:649) [catalina.jar:7.0.55]rn at org.apache.catalina.startup.HostConfig.deployDirectory(HostConfig.java:1247) [catalina.jar:7.0.55]rn at org.apache.catalina.startup.HostConfig$DeployDirectory.run(HostConfig.java:1898) [catalina.jar:7.0.55]rn at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471) [na:1.7.0_45]rn at java.util.concurrent.FutureTask.run(FutureTask.java:262) [na:1.7.0_45]rn at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) [na:1.7.0_45]rn at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) [na:1.7.0_45]rn at java.lang.Thread.run(Thread.java:744) [na:1.7.0_45]rnCaused by: org.springframework.core.NestedIOException: Failed to parse config resource: class path resource [tkfconfig/ibatis/SqlMapConfig.xml]; nested exception is com.ibatis.common.xml.NodeletException: Error parsing XML. Cause: java.lang.RuntimeException: Error parsing XPath '/sqlMapConfig/sqlMap'. Cause: com.ibatis.common.xml.NodeletException: Error parsing XML. Cause: java.lang.RuntimeException: Error parsing XPath '/sqlMap/select'. Cause: com.ibatis.sqlmap.client.SqlMapException: There is no result map named information_space.diafavorite in this SqlMap.rn at org.springframework.orm.ibatis.SqlMapClientFactoryBean.buildSqlMapClient(SqlMapClientFactoryBean.java:341) ~[org.springframework.orm-3.1.1.RELEASE.jar:3.1.1.RELEASE]rn at org.springframework.orm.ibatis.SqlMapClientFactoryBean.afterPropertiesSet(SqlMapClientFactoryBean.java:291) ~[org.springframework.orm-3.1.1.RELEASE.jar:3.1.1.RELEASE]rn at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeInitMethods(AbstractAutowireCapableBeanFactory.java:1514) ~[org.springframework.beans-3.1.1.RELEASE.jar:3.1.1.RELEASE]rn at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1452) ~[org.springframework.beans-3.1.1.RELEASE.jar:3.1.1.RELEASE]rn ... 25 common frames omittedrnCaused by: com.ibatis.common.xml.NodeletException: Error parsing XML. Cause: java.lang.RuntimeException: Error parsing XPath '/sqlMapConfig/sqlMap'. Cause: com.ibatis.common.xml.NodeletException: Error parsing XML. Cause: java.lang.RuntimeException: Error parsing XPath '/sqlMap/select'. Cause: com.ibatis.sqlmap.client.SqlMapException: There is no result map named information_space.diafavorite in this SqlMap.rn at com.ibatis.common.xml.NodeletParser.parse(NodeletParser.java:62) ~[hdibatis.jar:na]rn at com.ibatis.sqlmap.engine.builder.xml.SqlMapConfigParser.parse(SqlMapConfigParser.java:110) ~[hdibatis.jar:na]rn at com.ibatis.sqlmap.engine.builder.xml.SqlMapConfigParser.parse(SqlMapConfigParser.java:99) ~[hdibatis.jar:na]rn at org.springframework.orm.ibatis.SqlMapClientFactoryBean.buildSqlMapClient(SqlMapClientFactoryBean.java:338) ~[org.springframework.orm-3.1.1.RELEASE.jar:3.1.1.RELEASE]rn ... 28 common frames omittedrnCaused by: java.lang.RuntimeException: Error parsing XPath '/sqlMapConfig/sqlMap'. Cause: com.ibatis.common.xml.NodeletException: Error parsing XML. Cause: java.lang.RuntimeException: Error parsing XPath '/sqlMap/select'. Cause: com.ibatis.sqlmap.client.SqlMapException: There is no result map named information_space.diafavorite in this SqlMap.rn at com.ibatis.common.xml.NodeletParser.processNodelet(NodeletParser.java:123) ~[hdibatis.jar:na]rn at com.ibatis.common.xml.NodeletParser.process(NodeletParser.java:84) ~[hdibatis.jar:na]rn at com.ibatis.common.xml.NodeletParser.process(NodeletParser.java:102) ~[hdibatis.jar:na]rn at com.ibatis.common.xml.NodeletParser.parse(NodeletParser.java:72) ~[hdibatis.jar:na]rn at com.ibatis.common.xml.NodeletParser.parse(NodeletParser.java:60) ~[hdibatis.jar:na]rn ... 31 common frames omittedrnCaused by: com.ibatis.common.xml.NodeletException: Error parsing XML. Cause: java.lang.RuntimeException: Error parsing XPath '/sqlMap/select'. Cause: com.ibatis.sqlmap.client.SqlMapException: There is no result map named information_space.diafavorite in this SqlMap.rn at com.ibatis.common.xml.NodeletParser.parse(NodeletParser.java:62) ~[hdibatis.jar:na]rn at com.ibatis.sqlmap.engine.builder.xml.SqlMapParser.parse(SqlMapParser.java:55) ~[hdibatis.jar:na]rn at com.ibatis.sqlmap.engine.builder.xml.SqlMapConfigParser$11.process(SqlMapConfigParser.java:398) ~[hdibatis.jar:na]rn at com.ibatis.common.xml.NodeletParser.processNodelet(NodeletParser.java:121) ~[hdibatis.jar:na]rn ... 35 common frames omittedrnCaused by: java.lang.RuntimeException: Error parsing XPath '/sqlMap/select'. Cause: com.ibatis.sqlmap.client.SqlMapException: There is no result map named information_space.diafavorite in this SqlMap.rn at com.ibatis.common.xml.NodeletParser.processNodelet(NodeletParser.java:123) ~[hdibatis.jar:na]rn at com.ibatis.common.xml.NodeletParser.process(NodeletParser.java:84) ~[hdibatis.jar:na]rn at com.ibatis.common.xml.NodeletParser.process(NodeletParser.java:102) ~[hdibatis.jar:na]rn at com.ibatis.common.xml.NodeletParser.parse(NodeletParser.java:72) ~[hdibatis.jar:na]rn at com.ibatis.common.xml.NodeletParser.parse(NodeletParser.java:60) ~[hdibatis.jar:na]rn ... 38 common frames omittedrnCaused by: com.ibatis.sqlmap.client.SqlMapException: There is no result map named information_space.diafavorite in this SqlMap.rn at com.ibatis.sqlmap.engine.impl.SqlMapExecutorDelegate.getResultMap(SqlMapExecutorDelegate.java:357) ~[hdibatis.jar:na]rn at com.ibatis.sqlmap.engine.builder.xml.SqlStatementParser.parseGeneralStatement(SqlStatementParser.java:72) ~[hdibatis.jar:na]rn at com.ibatis.sqlmap.engine.builder.xml.SqlMapParser$22.process(SqlMapParser.java:581) ~[hdibatis.jar:na]rn at com.ibatis.common.xml.NodeletParser.processNodelet(NodeletParser.java:121) ~[hdibatis.jar:na]rn ... 42 common frames omittedrn十一月 22, 2016 9:37:36 上午 org.apache.catalina.core.StandardContext listenerStartrn严重: Exception sending context initialized event to listener instance of class org.springframework.web.context.ContextLoaderListenerrn
web.xml报错,那个大神说一下
web.xml报错,那个大神说一下;我是ssm初学者; 和这个一样的错,还有个filter-name
程序报错,高手来看
我的程序在自己的电脑上运行正常,但是打包后运行报错:run-time error '30468',经定位为涉及到一个表格显示控件调用出错,但是我将ocx已经拷过来了,如果不拷过来会提示找不到控件.控件为SSOleDBDataGrid.哪位高手给我指点啊。
使用EXT4报错!大神快来看~求解决
学习搭建ext4的MVC,报错~rn错误是:例外被抛出且未被接住 ext-all-debug.js rn我的代码是:rnapp:rn[code=Java]Ext.application(rn name:'AM',rn appFolder:'js',rn controllers:["Users"],rn launch: function () rn Ext.create('Ext.container.Viewport', rn layout: 'fit',rn items: [rn xtype: 'userlist'rn ]rn );rn rn);[/code]rncontroller:rn[code=Java]Ext.define('AM.controller.Users', rn extend: 'Ext.app.Controller',rn views: [rn 'List',rn 'Edit'rn ],rn stores:[rn "Users"rn ],rn models:["User"],rn init: function () rn this.control(rn 'userlist': rn itemdblclick: this.editUserrn rn );rn ,rn editUser: function(grid, record) rn console.log('Double clicked on ' + record.get('name'));rn rn);[/code]rnmodel:rn[code=Java]Ext.define('AM.model.User', rn extend: 'Ext.data.Model',rn fields: ['name', 'email']rn)[/code]rnstore:rn[code=Java]Ext.define('AM.store.Users', rn extend: 'Ext.data.Store',rn model: 'AM.model.User',rn data: [rn name: 'Ed', email: 'ed@sencha.com' ,rn name: 'Tommy', email: 'tommy@sencha.com' rn ]rn);[/code]rnview:rn[code=Java]Ext.define('AM.view.List', rn extend: 'Ext.grid.Panel',rn alias: 'widget.userlist',rn title: 'All Users',rn initComponent: function () rn this.store = "Users";rn this.columns = [rn header: 'Name', dataIndex: 'name', flex: 1 ,rn header: 'Email', dataIndex: 'email', flex: 1 rn ];rn this.callParent(arguments);rn rn);[/code]rnrn求大神们解决啊~~~在线等~!!!
关于Junit调用Axis2报错问题,大神们来看看吧
如题,调用时报出如下错误,请大家帮帮忙看看rn2011-5-17 18:33:38 org.apache.commons.httpclient.HttpMethodDirector executeWithRetryrn信息: Retrying requestrn2011-5-17 18:33:38 org.apache.axis2.transport.http.HTTPSender sendViaPostrn信息: Unable to sendViaPost to url[http://localhost:8080/BTV_WS/services/SyncUserService]rnorg.apache.axis2.AxisFault: operation cannot be null!!rn at org.apache.axis2.AxisFault.makeFault(AxisFault.java:430)rn at org.apache.axis2.transport.http.SOAPMessageFormatter.writeTo(SOAPMessageFormatter.java:83)rn at org.apache.axis2.transport.http.AxisRequestEntity.writeRequest(AxisRequestEntity.java:84)rn at org.apache.commons.httpclient.methods.EntityEnclosingMethod.writeRequestBody(EntityEnclosingMethod.java:499)rn at org.apache.commons.httpclient.HttpMethodBase.writeRequest(HttpMethodBase.java:2114)rn at org.apache.commons.httpclient.HttpMethodBase.execute(HttpMethodBase.java:1096)rn at org.apache.commons.httpclient.HttpMethodDirector.executeWithRetry(HttpMethodDirector.java:398)rn at org.apache.commons.httpclient.HttpMethodDirector.executeMethod(HttpMethodDirector.java:171)rn at org.apache.commons.httpclient.HttpClient.executeMethod(HttpClient.java:397)rn at org.apache.commons.httpclient.HttpClient.executeMethod(HttpClient.java:346)rn at org.apache.axis2.transport.http.AbstractHTTPSender.executeMethod(AbstractHTTPSender.java:550)rn at org.apache.axis2.transport.http.HTTPSender.sendViaPost(HTTPSender.java:189)rn at org.apache.axis2.transport.http.HTTPSender.send(HTTPSender.java:75)rn at org.apache.axis2.transport.http.CommonsHTTPTransportSender.writeMessageWithCommons(CommonsHTTPTransportSender.java:389)rn at org.apache.axis2.transport.http.CommonsHTTPTransportSender.invoke(CommonsHTTPTransportSender.java:222)rn at org.apache.axis2.engine.AxisEngine.send(AxisEngine.java:435)rn at org.apache.axis2.description.OutInAxisOperationClient.send(OutInAxisOperation.java:402)rn at org.apache.axis2.description.OutInAxisOperationClient.executeImpl(OutInAxisOperation.java:229)rn at org.apache.axis2.client.OperationClient.execute(OperationClient.java:165)rn at cn.com.btv.aap.service.usersyncservice.SyncUserServiceStub.SyncUser(SyncUserServiceStub.java:183)rn at cn.com.btv.aap.service.usersyncservice.SyncUserServiceTest.testSyncUser(SyncUserServiceTest.java:49)rn at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)rn at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)rn at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)rn at java.lang.reflect.Method.invoke(Method.java:585)rn at junit.framework.TestCase.runTest(TestCase.java:154)rn at junit.framework.TestCase.runBare(TestCase.java:127)rn at junit.framework.TestResult$1.protect(TestResult.java:106)rn at junit.framework.TestResult.runProtected(TestResult.java:124)rn at junit.framework.TestResult.run(TestResult.java:109)rn at junit.framework.TestCase.run(TestCase.java:118)rn at junit.framework.TestSuite.runTest(TestSuite.java:208)rn at junit.framework.TestSuite.run(TestSuite.java:203)rn at org.eclipse.jdt.internal.junit.runner.junit3.JUnit3TestReference.run(JUnit3TestReference.java:130)rn at org.eclipse.jdt.internal.junit.runner.TestExecution.run(TestExecution.java:38)rn at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:467)rn at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:683)rn at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:390)rn at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:197)rnCaused by: org.apache.axis2.databinding.ADBException: operation cannot be null!!rn at cn.com.btv.aap.service.usersyncservice.SyncUserServiceStub$UserType.serialize(SyncUserServiceStub.java:922)rn at cn.com.btv.aap.service.usersyncservice.SyncUserServiceStub$UserType.serialize(SyncUserServiceStub.java:846)rn at cn.com.btv.aap.service.usersyncservice.SyncUserServiceStub$UserListType.serialize(SyncUserServiceStub.java:3396)rn at cn.com.btv.aap.service.usersyncservice.SyncUserServiceStub$UserListType.serialize(SyncUserServiceStub.java:3340)rn at cn.com.btv.aap.service.usersyncservice.SyncUserServiceStub$UserSyncRequestType.serialize(SyncUserServiceStub.java:4322)rn at cn.com.btv.aap.service.usersyncservice.SyncUserServiceStub$UserSyncRequestType.serialize(SyncUserServiceStub.java:4266)rn at cn.com.btv.aap.service.usersyncservice.SyncUserServiceStub$UserSyncRequest.serialize(SyncUserServiceStub.java:5437)rn at cn.com.btv.aap.service.usersyncservice.SyncUserServiceStub$UserSyncRequest.serialize(SyncUserServiceStub.java:5422)rn at cn.com.btv.aap.service.usersyncservice.SyncUserServiceStub$UserSyncRequest$1.serialize(SyncUserServiceStub.java:5410)rn at org.apache.axis2.databinding.ADBDataSource.serialize(ADBDataSource.java:93)rn at org.apache.axiom.om.impl.llom.OMSourcedElementImpl.internalSerializeAndConsume(OMSourcedElementImpl.java:738)rn at org.apache.axiom.om.impl.llom.OMElementImpl.internalSerialize(OMElementImpl.java:966)rn at org.apache.axiom.om.impl.llom.OMElementImpl.internalSerializeAndConsume(OMElementImpl.java:995)rn at org.apache.axiom.soap.impl.llom.SOAPEnvelopeImpl.serializeInternally(SOAPEnvelopeImpl.java:254)rn at org.apache.axiom.soap.impl.llom.SOAPEnvelopeImpl.internalSerialize(SOAPEnvelopeImpl.java:242)rn at org.apache.axiom.om.impl.llom.OMElementImpl.internalSerializeAndConsume(OMElementImpl.java:995)rn at org.apache.axiom.om.impl.llom.OMNodeImpl.serializeAndConsume(OMNodeImpl.java:486)rn at org.apache.axis2.transport.http.SOAPMessageFormatter.writeTo(SOAPMessageFormatter.java:79)rn ... 37 morern这年头居然在google上找不到同类问题的解决方案。。。怪了,咱也做了回吃螃蟹的人?
大神过来看看我的代码,为什么会报错?
题目是网上看到的。rn假设 a b c d e 代表1~9不同的5个数字,能满足形如: ab * cde = adb * ce 这样的算式一共有多少种?rn我的算法是这样的(先不说我的算法是否高效,那个先不谈)rn[code=csharp]private static List ss() rn rn List s = new List ;rn int a, b, c, d, e;rn //int [] arr = new int[1,2,3,4,5,6,7,8,9];rn List strlist = new List 1, 2, 3, 4, 5, 6, 7, 8, 9 ;rn List strlist2, strlist3, strlist4, strlist5;rn ArrayList arr = new ArrayList();rn arr.AddRange(strlist.ToArray());rn foreach(int i in strlist)rn rn a = i;rn strlist2 = strlist;rn strlist2.Remove(i);rn foreach (int i2 in strlist2)rn rn b = i2;rn strlist3 = strlist2;rn strlist2.Remove(i2);rn foreach (int i3 in strlist3)rn rn c = i3;rn strlist4 = strlist3;rn strlist4.Remove(i3);rn foreach (int i4 in strlist4)rn rn d = i4;rn strlist5 = strlist4;rn strlist5.Remove(i4);rn foreach (int i5 in strlist5)rn rn e = i5;rn if((a*10+b)*(c*100+d*10+e) == (a*100+d*10+b)*(c*10+e))rn rn rn string str = ((a * 10 + b) * (c * 100 + d * 10 + e)).ToString() + "=" + ((a * 100 + d * 10 + b) * (c * 10 + e)).ToString();rn s.Add(str);rn rn rnrn rnrn rn rnrn rn rn return s;rn [/code]rnrn现在的情况是,代码[color=#FF0000]第二次[/color]执行到foreach (int i4 in strlist4)的时候就会报rnrn集合已修改; 列舉作業可能尚未執行。rn这样的错误。可是我明明都已经做了备份了呀?在remove之前都用新的数组做了备份的,应该和原先的数组没关系吧?
android sdk 运行时报错,求大神帮忙
2014-11-24 16:52:01 - HelloWord] ------------------------------rn[2014-11-24 16:52:01 - HelloWord] Android Launch!rn[2014-11-24 16:52:01 - HelloWord] The connection to adb is down, and a severe error has occured.rn[2014-11-24 16:52:01 - HelloWord] You must restart adb and Eclipse.rn[2014-11-24 16:52:01 - HelloWord] Please ensure that adb is correctly located at 'D:\java\android\adt-bundle-windows-x86-20130917\sdk\platform-tools\adb.exe' and can be executed.rn
高手帮忙来看一下
各位大虾,我把一个服务器的数据库导入到本地服务器上,为什么原来数据库里的试图现在都跑到用户表里去了呢?怎么做才能让本地的数据库跟远程服务器上的数据库一抹一样呢?
大家来看一下啊,,,
怎么把rnMemo里的内容保存到指定的文件,,,
难--来看一下吧
不是,我的意思就是,我现在在两台不同的机子上同时使用同一帐号登入,我如何判断该帐号已经成功登入了,并在浏览该网站,另一个人不能再用该帐号登入进去,或象QQ一样,如果该帐号登入,该帐号在其他地方再登入,出来一个提示并该帐号重新登入,那边的下线这种,不知道如何去做,希望大家提供一些意见,谢谢rn
来看一下吧,帮帮我!
帮我解释一下“嵌入式软件”的概念吧!我看现在都是这个,但是却没什么具体的概念!谢谢了!
精通WebWork来看一下。
在Action类中rn执行成功,返回SUCCESS,可是没有跳到我在xwork中设置的路径rn而是跳到首页。rnrn-----web.xml 部分rnrn webworkrn com.opensymphony.webwork.dispatcher.FilterDispatcherrn rnrnrnrn webworkrn /*rnrnrn-----xwork.xmlrnrn rn rn rn rn /register_success.jsprn rn rn rnrnrn----Actionrn 后台输出成功success.rnrn找个很长时间资料,没发现。
来看一下啊!
用ADO访问SQL,rnSQL方面要不要设置什么?
ACM的水题,来看一下
http://acm.hdu.edu.cn/showproblem.php?pid=3527rnrn谁来用C语言写个啊 ,小弟感激不尽 rn全给分
请高手来看一下!
请给出一般的解决思路 我看了一些资料 没有什么头绪 甚至对分布式文件系统本身都缺乏 了解 但是我选的这个题目 谁能帮我一下 或者提供一些资料啊
声卡驱动问题。来看一下。
我的机子声卡驱动坏了。我想去下载一个。但不知道声卡是什么牌子的。rn这怎么办?是不是随便装一个就行了?
大家来看一下
我用的是JBX+Weblogic8rn下面这个Servelet 从数据库拿出来的中文为什么总是乱码?rnrnpackage myjdbcreadservlet;rnrnimport javax.servlet.*;rnimport javax.servlet.http.*;rnimport java.io.*;rnimport java.util.*;rnimport java.sql.*;rnimport javax.naming.Context;rnimport javax.naming.InitialContext;rnimport javax.naming.NamingException;rnimport javax.sql.DataSource;rnrnpublic class myJDBCReadServlet extends HttpServlet rn private static final String CONTENT_TYPE = "text/html; charset=GB2312";rn Context ctx;rn DataSource ds;rn Statement stmt;rn ResultSet rs;rn public void init() throws ServletException rn try rn ctx = new InitialContext();rn ds = (javax.sql.DataSource)ctx.lookup ("testSysDS");rnrn catch (Exception E) rn System.out.println("Init Error: " + E);rn rn rn public void service(HttpServletRequest requ,rn HttpServletResponse resp)rn throws IOExceptionrnrn rn Connection myConn = null;rnrn try rnrn PrintWriter out = resp.getWriter();rnrn out.println("");rn out.println(" myJDBCReadServlet");rn out.println("");rnrn out.println(" myJDBCReadServlet");rn myConn = ds.getConnection();rn stmt = myConn.createStatement();rn rs = stmt.executeQuery("SELECT * FROM MOD ");rn while (rs.next()) rn out.println(rs.getString("MOD_SubSystem") + "- " +rn rs.getString("MOD_Code") + "- " +rn rs.getString("MOD_Name") + " ");rn rs.getString("mod_system");rn rnrn /* Release the ResultSet and Statement.rn */rn rs.close();rn stmt.close();rnrn catch (Exception E) rn /*rn Handle exception here.rn */rn System.out.println("Service Error: " + E);rn finally rn if (rs != null) rn try rs.close(); catch (Exception ignore) ;rn rn if (stmt != null) rn try stmt.close(); catch (Exception ignore) ;rn rn if (myConn != null) rn try myConn.close(); catch (Exception ignore) ;rn rn rn rn public void doGet(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException rn response.setContentType(CONTENT_TYPE);rn PrintWriter out = response.getWriter();rn out.println("");rn out.println(" myJDBCReadServlet");rn out.println("");rn out.println(" The servlet has received a GET. This is the reply.");rn out.println("");rn rnrn //Clean up resourcesrn public void destroy() rn rnrn
大家来看一下。
哪个有联众的四国军棋的抄分软件呀,提供者我给分。rn我的信箱是andyting@qq.comrn给我下载地址也行。我在网上找了半天没找到。那个知道的请告诉我。谢谢。
大哥哥们来看一下
各位大哥哥,小弟弟我现在在看c++ primer,感觉好难,而且书后的习题太少了,有没有比较好的习题,我想通过大量的习题来提高自己,不知道这样对不对?各位能不能推荐什么好的习题集啊?
高手来看一下
dim myConnection2 as new sqlConnection("data source=.;Initial catalog=Email;Uid=sa;PWD=")rndim myCommand2 as sqlCommandrndim qry2 as stringrnmyConnection2.openrnrnqry2="insert into email(s_email,d_email,subject,content,email_flag,sendtime,att_flag)"& _rn"values('"&session("username") & _rn"','"& receive.text & _rn"','"& subject.text & _rn"','"& content.text & _rn"','"& "1" & _rn"','"& now() & _rn"','"& "0"&"')"rnmyCommand2=new sqlClient.sqlCommand(qry2,myConnection2)rnmyCommand2.executeNonQuery()rnrn为什么报错rnrn异常详细信息: System.Data.SqlClient.SqlException: 第 1 行: 'jjj' 附近有语法错误。rnrn源错误: rnrnrn行 151:"','"& "0"&"')"rn行 152:myCommand2=new sqlClient.sqlCommand(qry2,myConnection2)rn行 153:myCommand2.executeNonQuery()rn行 154:response.Redirect("sendmail_success.aspx?receive=" &receive.text)rn行 155:end subrn rn
来看一下global.asa的问题?
global.asa文件为rn rn在index.asp文件中调用Application("conn"),但是却什么都显示不出来rnresponse.write Application("conn")rn服务器端还用设置什么东西吗?
知道GRUB的来看一下!!!
由grub引导后,系统是处于什么模式?rn保护模式还是实模式?
在线的来看一下
“函数名:local function definitions are illegal”rn高手们,出现这样的编译错误是什么意思?表示这个函数用错了?还是该函数里面有问题?谢谢啦!rn同一行还出现:“fatal error C1903: unable to recover from previous error(s); stopping compilation”rnError executing cl.exe.
求救。高手来看一下。
windows下如何解析IP数据包头。rn用vc(不用MFC,用windows api,dos界面)rn需要用到那些东西(WinSocket ?).rn过程怎样?rn急用!忘赐教。
很菜的问题来看一下
在SQL server中用什么命令添加一条记录
相关热词 c#入门推荐书 c# 解码海康数据流 c# xml的遍历循环 c# 取 查看源码没有的 c#解决高并发 委托 c#日期转化为字符串 c# 显示问号 c# 字典对象池 c#5.0 安装程序 c# 分页算法