这个该怎么解决,求大神

图片

8个回答

你选择下拉框下面的 Remove..或者Change...开头的都可以解决你的问题~你会发现他们的变化~自然你就知道该怎么解决了

构造函数没有定义,可能是你传的参数多了,少了或者类型不对。

参数不对应,造成的,核对声明与使用的地方

没有匹配的构造方法,确认一下你的参数类型和顺序是不是一样的

你选择下拉框下面的 Remove..或者Change...开头的都可以解决你的问题~你会发现他们的变化~自然你就知道该怎么解决了

没有定义子类

构造方法 没有找到。 也就是 你要看下你的传参是否与你的构造方法的参数相同, 一定要看泛型是否一致, 参数是否类型统一。

适配器构造函数参数可能不对应,还有可能就是this这里。getApplication()试试。

构造器未定义,,查看一下构造器就知道了,,

Csdn user default icon
上传中...
上传图片
插入图片
抄袭、复制答案,以达到刷声望分或其他目的的行为,在CSDN问答是严格禁止的,一经发现立刻封号。是时候展现真正的技术了!
其他相关推荐
求大神这个数据表该怎么建
我现在想设计个工作计划管理的小软件,我的工作计划分周计划、月计划、年计划,这个工作计划表是不是要分别建立周表,月表,年表,还是直接建一个工作计划表呢?请大神帮忙分析一下。rn 现在我的想法是这样的,建立三个表,周表,月表,年表。但是周表得包含属于哪个月的,属于哪一年的,月表得包含属于哪一年的。这样的会不会有冗余数据呢?请大神指点。
求各位大神,这是该怎么解决
[img=https://img-bbs.csdn.net/upload/201506/14/1434291631_148065.png][/img]rn求各位指点,不胜感激
求大神过来看看这个怎么解决?
导入新浪sdk后出现的。[img=https://img-bbs.csdn.net/upload/201403/02/1393741749_592614.jpg][/img][img=https://img-bbs.csdn.net/upload/201403/02/1393741792_164169.jpg][/img]
求大神告诉我怎么解决这个问题
[img=https://img-bbs.csdn.net/upload/201401/03/1388731665_320739.jpg][/img]rnrn如图所示,关键字的大小仿佛固定住了似得,在如何解决这个问题 ?
这个问题怎么解决,求大神!
开发了个winform应用程序,里面用到了Sql Server Compact3.5数据库,打包完成后(数据库跟可执行文件在同一个目录的),到win7-64bit下安装,出现异常 “不允许访问数据库”。rn请问这是什么问题啊,是系统权限问题还是其他?请大家帮帮忙,都搞了一天了。。。。
求大神指导 这个错误怎么解决
严重: Exception sending context initialized event to listener instance of class org.springframework.web.context.ContextLoaderListenerrnorg.springframework.beans.factory.CannotLoadBeanClassException: Error loading class [com.service.DefaultMultipartResolver] for bean with name 'multipartResolver' defined in ServletContext resource [/WEB-INF/applicationContext.xml]: problem with class file or dependent class; nested exception is java.lang.UnsupportedClassVersionError: com/service/DefaultMultipartResolver : Unsupported major.minor version 51.0rnCaused by: java.lang.UnsupportedClassVersionError: com/service/DefaultMultipartResolver : Unsupported major.minor version 51.0rn at java.lang.ClassLoader.defineClass1(Native Method)rn at java.lang.ClassLoader.defineClass(ClassLoader.java:621)rn at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:124)rn at org.apache.catalina.loader.WebappClassLoader.findClassInternal(WebappClassLoader.java:1817)rn at org.apache.catalina.loader.WebappClassLoader.findClass(WebappClassLoader.java:872)rn at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1325)rn at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1204)rn at org.springframework.util.ClassUtils.forName(ClassUtils.java:201)rn at org.springframework.beans.factory.support.AbstractBeanDefinition.resolveBeanClass(AbstractBeanDefinition.java:327)rn at org.springframework.beans.factory.support.AbstractBeanFactory.resolveBeanClass(AbstractBeanFactory.java:1066)rn at org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:282)rn at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:352)rn at org.springframework.web.context.ContextLoader.createWebApplicationContext(ContextLoader.java:244)rn at org.springframework.web.context.ContextLoader.initWebApplicationContext(ContextLoader.java:187)rn at org.springframework.web.context.ContextLoaderListener.contextInitialized(ContextLoaderListener.java:49)rn at org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:3827)rn at org.apache.catalina.core.StandardContext.start(StandardContext.java:4334)rn at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:791)rn at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:771)rn at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:525)rn at org.apache.catalina.startup.HostConfig.deployDirectory(HostConfig.java:920)rn at org.apache.catalina.startup.HostConfig.deployDirectories(HostConfig.java:883)rn at org.apache.catalina.startup.HostConfig.deployApps(HostConfig.java:492)rn at org.apache.catalina.startup.HostConfig.start(HostConfig.java:1138)rn at org.apache.catalina.startup.HostConfig.lifecycleEvent(HostConfig.java:311)rn at org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:117)rn at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1053)rn at org.apache.catalina.core.StandardHost.start(StandardHost.java:719)rn at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1045)rn at org.apache.catalina.core.StandardEngine.start(StandardEngine.java:443)rn at org.apache.catalina.core.StandardService.start(StandardService.java:516)rn at org.apache.catalina.core.StandardServer.start(StandardServer.java:710)rn at org.apache.catalina.startup.Catalina.start(Catalina.java:566)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:597)rn at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:288)rn at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:413)rn2018-4-20 18:35:08 org.apache.catalina.core.StandardContext startrn严重: Error listenerStartrn2018-4-20 18:35:08 org.apache.catalina.core.StandardContext startrn严重: Context [/qxj] startup failed due to previous errorsrn2018-4-20 18:35:08 org.apache.catalina.core.ApplicationContext log
求大神看看这个怎么解决
[img=https://img-bbs.csdn.net/upload/201512/17/1450341851_319606.png][/img]rn[img=https://img-bbs.csdn.net/upload/201512/17/1450341765_893873.png][/img]rn这个错误怎么解决啊,代码在这边
这个异常怎么解决,求大神指点
编了一个java小问题: 找出数组元素的最大值,并放到原数组之后rn运行,抛出错误:Exception in thread "main" java.lang.ArrayIndexOutOfBoundsException: 8rn at maxOfArray.main(maxOfArray.java:14)rn怎么解决,求大神指点!rnimport java.util.Arrays;rnpublic class maxOfArray rn /**rn * 找出数组元素的最大值,并放到原数组之后rn */rn public static void main(String[] args) rn //先扩容,后找最大值rn int[] arr=3,5,8,2,10,52,1;rn int[] arr1=new int[8];rn System.arraycopy(arr, 0, arr1, 0, 7);rn arr1[arr1.length]=arr1[0];rn for(int i=1;iarr[arr1.length-1])rn arr1[arr1.length-1]=arr1[i];rn rn rn System.out.println(arr1.toString());rn rnrn
这个该怎么解决
Fatal error: Call to undefined function helper() in D:\wwwroot\w1h2n3\wwwroot\include\common.inc.php on line 355rnrn我的网站 80后怀旧网,后台登陆不了,后台登陆地址显示如上,怎么解决呀!
这个该怎么解决 。。。。。
rn rn rn 序号rn rn rn rnrn 这是代码。。我是想把从数据库中取出来的数据DataTable 中有id,和name。 把name变成列 显示出来。rnDataTable 里面的数据部固定有几行
这个该怎么解决?
在打印的时候,运用了ActiveX控件,如下代码:rnrn rn rnrnrnrnrn在进行浏览的时候,IE浏览器总是提示我阻止了该ActiveX控件运行.该如何启用这个呢?谢谢!
这个该怎么解决?
一个类似对话框的form,想要输入用户名和密码的时候按回车就等于按确认,以前我是用eidt的KeyDown事件,不过总在回车时候发出一个响声,请问该怎么解决?谢谢rn特别注明:我是超级菜菜菜鸟
这个该怎么解决?!
我连接一数据库,能连上.rn然后操作数据库的表,数据库是SQL server 2000rn操作系统自带的表没有问题,但是如果操作用户建的表,问题就出现了rn比如操作系统的表A,直接"select * from A"就可以了rn但是要是B,不是系统的,是用户建的,"select * from B "就会报 "对象名"A"无效"的错误rn但是倘若改成"select * from test.dbo.B"就没有问题 (假设数据库是test,我是在企业管理器里面建的数据库和表)rn在查询分析器里面直接"select * from B "就可以.rn我看了权限,应该有权限啊,很不明白.rnrn请高人赐教,本人很菜.rn谢谢rn连接字符串 server=HAN;userid=sa;password=sa;database=test;Trusted_Connection=yes
求大神解决这个编程
[size=13px]#includernusing namespace std;rnclass Pointrnrnpublic:rn Point(int xx=0,int yy=0)rn rn x=xx;y=yy;rn rn Point(Point &p);rn int getX()rn return x;rn rn int getY()rn return y;rn rnprivate:rn int x,y;rn;rnPoint::Point(Point &p)rnrn x=p.x;rn y=p.y;rn cout<<"caling"<
求大神解决下这个问题
[img=https://img-bbs.csdn.net/upload/201804/12/1523547660_532045.png][/img][img=https://img-bbs.csdn.net/upload/201804/12/1523547666_627945.png][/img]这个要怎么改啊,学的很基础的东西。。
求大神这个怎么写?
定义一个公共类TestAbstactShape,编程实现:定义声明100个Shape对象数组,然后循环100次随机产生100个图形对象(为上述的Rectangle、Circle、Triangle之一,要求生成后输出其信息),然后分别计算输出所有100个图形对象的面积与周长的累加。
这个问题怎么解决.....androidstudio 求大神解决
Gradle sync failed: Server sent an unsupported extension: type_35rn Consult IDE log for more details (Help | Show Log)
这个报错该怎么解决?
错误1 无法创建“DoctorWorkStation\MedicalRecord\frmSubDiseaseTrack.resx”的清单资源名称。未能找到文件“D:\gs_d\hh\test1\iCare_gxqyy\iCare_gxqyy\code\EMR\iCare\DoctorWorkStation\MedicalRecord\frmSubDiseaseTrack.cs”。
这个问题该怎么解决??
请问一下高手们,我的数据库中有一个表与其中数据库中多个表是相关联的,同时该表中有一个唯一ID都在其他与之相关联的表中也存在,这个唯一ID数据库中新增的时候是自动加一的, 但是我在在某一条记录之前插入一条记录,那么在他之后的记录的唯一ID也都应该相应的自动加一,同时与之相关联的表中记录也应该相应的进行改变。 我的问题是这样的,由于数据中的记录可能比较的多,考虑到速度问题,我是第一种方案是利用数据存储器(datastore)来先检索所有表的满足条件的记录,再相应的把他的值进行相应的修改,然后再进行数据存储器调用UPDATE()函数,rn 第二中是直接写SQL语句,进行相应的修改。rn 如果要是用SQL语句的话,因为我是一个表一个表进行处理的,所以我在每个表中都是用了事物进行判断,成功就提交,否则就回滚,返回, 那样的话,就会出现这样的问题,就是我第一个表保存成功,并提交了,可是在第二个表失败了,就返回了,那样修改的数据就只有一部分了,那样的操作是错误的。rn 请问大家两中方案哪种最适合,或者是还有其他更好的方案,希望大家能够给我指点迷津!
这个问题该怎么解决
程序里有一个类rn StandardConditionFormrn里面一个函数 rn Public Sub RaiseEventDoExportrn现在我有个类 继承它:[color=#FF0000]Public Class ConditionFormrn Inherits StandardConditionForm[/color][b][/b]rn我现在想 覆盖掉 父类 RaiseEventDoExport 这个方法 rn前提:StandardConditionForm 我不能改 是别人已经提供好的
这个异常该怎么解决
异常详细信息: CrystalDecisions.CrystalReports.Engine.LogOnException: Error in File C:\DOCUME~1\LIZH\ASPNET\LOCALS~1\Temp\temp_ab286288-5fe9-4b26-8366-7797e0448f66.rpt: Unable to connect: incorrect log on parameters
这个报错该怎么解决
各位前辈:rn  我现在正学编程。可一开始就给难住了。情况是这样的:rn我学习的是《windows 程序设计》第5版。因为刚拿到书不久,所以还没有仔细看,就忙着上机做试验。第三章的试验hellowin.c 这个例程, 我照着编完以后,编译时没有报错,但是当我进行“构建hellowin.exe"时报出了以下的错误:rnrnrnrnrn--------------------Configuration: hellowin - Win32 Debug--------------------rnLinking...rnhellowin.obj : error LNK2001: unresolved external symbol __imp__PlaySoundA@12rnDebug/hellowin.exe : fatal error LNK1120: 1 unresolved externalsrnError executing link.exe.rnrnhellowin.exe - 2 error(s), 0 warning(s)rnrnrn开始我以为是我编写时,可能什么地方因为粗心了,输入错误,于是在栓查不出来的情况下把原程序给拷了去,再进行构建时还是以上的错误。rnrnrn  我有msdn.但是我的英文阅读能力太差了,越看我头越大。所以就来让前辈们指点一下。rnrn我用的编程工具是 VC++6.0版 。完整的例程如下:rn/*------------------------------------------------------------rn HELLOWIN.C -- Displays "Hello, Windows 98!" in client arearn (c) Charles Petzold, 1998rn ------------------------------------------------------------*/rnrn#include rnrnLRESULT CALLBACK WndProc (HWND, UINT, WPARAM, LPARAM) ;rnrnint WINAPI WinMain (HINSTANCE hInstance, HINSTANCE hPrevInstance,rn PSTR szCmdLine, int iCmdShow)rnrn static TCHAR szAppName[] = TEXT ("HelloWin") ;rn HWND hwnd ;rn MSG msg ;rn WNDCLASS wndclass ;rnrn wndclass.style = CS_HREDRAW | CS_VREDRAW ;rn wndclass.lpfnWndProc = WndProc ;rn wndclass.cbClsExtra = 0 ;rn wndclass.cbWndExtra = 0 ;rn wndclass.hInstance = hInstance ;rn wndclass.hIcon = LoadIcon (NULL, IDI_APPLICATION) ;rn wndclass.hCursor = LoadCursor (NULL, IDC_ARROW) ;rn wndclass.hbrBackground = (HBRUSH) GetStockObject (WHITE_BRUSH) ;rn wndclass.lpszMenuName = NULL ;rn wndclass.lpszClassName = szAppName ;rnrn if (!RegisterClass (&wndclass))rn rn MessageBox (NULL, TEXT ("This program requires Windows NT!"), rn szAppName, MB_ICONERROR) ;rn return 0 ;rn rn hwnd = CreateWindow (szAppName, // window class namern TEXT ("The Hello Program"), // window captionrn WS_OVERLAPPEDWINDOW, // window stylern CW_USEDEFAULT, // initial x positionrn CW_USEDEFAULT, // initial y positionrn CW_USEDEFAULT, // initial x sizern CW_USEDEFAULT, // initial y sizern NULL, // parent window handlern NULL, // window menu handlern hInstance, // program instance handlern NULL) ; // creation parametersrn rn ShowWindow (hwnd, iCmdShow) ;rn UpdateWindow (hwnd) ;rn rn while (GetMessage (&msg, NULL, 0, 0))rn rn TranslateMessage (&msg) ;rn DispatchMessage (&msg) ;rn rn return msg.wParam ;rnrnrnLRESULT CALLBACK WndProc (HWND hwnd, UINT message, WPARAM wParam, LPARAM lParam)rnrn HDC hdc ;rn PAINTSTRUCT ps ;rn RECT rect ;rn rn switch (message)rn rn case WM_CREATE:rn PlaySound (TEXT ("hellowin.wav"), NULL, SND_FILENAME | SND_ASYNC) ;rn return 0 ;rnrn case WM_PAINT:rn hdc = BeginPaint (hwnd, &ps) ;rn rn GetClientRect (hwnd, &rect) ;rn rn DrawText (hdc, TEXT ("Hello, Windows 98!"), -1, &rect,rn DT_SINGLELINE | DT_CENTER | DT_VCENTER) ;rn EndPaint (hwnd, &ps) ;rn return 0 ;rn rn case WM_DESTROY:rn PostQuitMessage (0) ;rn return 0 ;rn rn return DefWindowProc (hwnd, message, wParam, lParam) ;rnrnrnrnrn我第一次参加csdn,不知道怎么散分。在这里只有先谢过各位前辈了。
这个问题该怎么解决?
[img=http://localhost/dddd/5.jpg][/img]rnrn在循环输出时,总是不能跟表头对应,因为他中间有合计,请教各位!
这个错误该怎么解决?
“/oa”应用程序中的服务器错误。 rn--------------------------------------------------------------------------------rnrn配置错误 rn说明: 在处理向该请求提供服务所需的配置文件时出错。请检查下面的特定错误详细信息并适当地修改配置文件。 rnrn分析器错误信息: 文件“Excel”正被另一个进程使用,因此无法访问该文件。rnrn源错误: rnrn行 170: rn行 171: rn行 172: //产生错误的一行rn行 173: rn行 174:rn rnrn源文件: c:\winnt\microsoft.net\framework\v1.0.3705\Config\machine.config 行: 172 rnrnrn--------------------------------------------------------------------------------rn版本信息: Microsoft .NET 框架版本:1.0.3705.0; ASP.NET 版本:1.0.3705.0 rnrnrn以上是错误提示信息,应该怎么修改?
这个异常该怎么解决?
请问各位:rn 我的多层分布式数据库在运行时出现异常:'project project1.exe raised exception class EOleError with message 'Method "getdatabasenames" not supported by automation object',其中getdatabasenames是我添加的一个函数用来得到所有数据库名,不知道这个异常该怎么解决?代码如下:rnrn以下是服务器程序:rnunit server;rnrninterfacernrnusesrn Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,rn Dialogs, StdCtrls, ExtCtrls;rnrntypern TForm1 = class(TForm)rn Panel1: TPanel;rn Label1: TLabel;rn clientcout: TLabel;rn Label3: TLabel;rn querycount: TLabel;rn privatern clientcounts:integer;rn querycounts:integer;rn Private declarations rn publicrn procedure updateclientcounts(incr:integer);//统计客户个数rn procedure updatequerycounts;//统计查询次数rn Public declarations rn end;rnrnvarrn Form1: TForm1;rnrnimplementationrnrn$R *.dfmrnrnprocedure Tform1.updateclientcounts(incr:integer);rnbeginrn clientcounts:=clientcounts+incr;rn form1.clientcout.Caption:=inttostr(clientcounts);//clientcout是一个LABLE控件,用于显示客户个数rnend;rnrnprocedure Tform1.updatequerycounts;rnbeginrn inc(querycounts);rn form1.querycount.Caption:=inttostr(querycounts);//querycount是一个LABLE控件,用于显示查询次数rnend; rnend.rnrn以下是远程数据模块的程序:rnunit module;rnrn$WARN SYMBOL_PLATFORM OFFrnrninterfacernrnusesrn Windows, Messages, SysUtils, Classes, ComServ, ComObj, VCLCom, DataBkr,rn DBClient, Project1_TLB, StdVcl, Provider, DBTables, DB, variants, server;//server是服务器程序rnrntypern Trdm1 = class(TRemoteDataModule, Irdm1) rn Query1: TQuery;rn Database1: TDatabase;rn Session1: TSession;rn DataSetProvider1: TDataSetProvider;rn procedure RemoteDataModuleCreate(Sender: TObject);rn procedure RemoteDataModuleDestroy(Sender: TObject);rn procedure Query1AfterOpen(DataSet: TDataSet);rn privatern Private declarations rn protectedrn function getdatabasenames:olevariant;//添加了一个得到所有数据库名的函数rn procedure setdatabasenames(const dbname,password:widestring);//添加了一个设置数据库名的过程rn class procedure UpdateRegistry(Register: Boolean; const ClassID, ProgID: string); override;rn publicrn Public declarations rn end;rnrnimplementationrnrn$R *.DFMrnrnclass procedure Trdm1.UpdateRegistry(Register: Boolean; const ClassID, ProgID: string);rnbeginrn if Register thenrn beginrn inherited UpdateRegistry(Register, ClassID, ProgID);rn EnableSocketTransport(ClassID);rn EnableWebTransport(ClassID);rn end elsern beginrn DisableSocketTransport(ClassID);rn DisableWebTransport(ClassID);rn inherited UpdateRegistry(Register, ClassID, ProgID);rn end;rnend;rnrnfunction Trdm1.getdatabasenames:olevariant;rnvarrn dbname:Tstringlist;rn i:integer;rnbeginrn dbname:=Tstringlist.Create;rn tryrn session1.GetDatabaseNames(dbname); //得到可用数据库名rn result:=vararraycreate([0,dbname.Count-1],varolestr);rn for i:=0 to dbname.Count-1 dorn result[i]:=dbname[i];rn finallyrn dbname.Free;//释放临时占有的空间rn end;rnend;rnrnprocedure Trdm1.setdatabasenames(const dbname,password:widestring);rnbeginrn tryrn database1.Close;rn database1.AliasName:=dbname;rn if password<>'' thenrn database1.Params.values['password']:=password;rn database1.Open;rn exceptrn on e:edbengineerror dorn if password='' thenrn raise exception.Create('password required')rn elsern raise;rn end;rnend;rnrnprocedure Trdm1.RemoteDataModuleCreate(Sender: TObject);//更新客户数rnbeginrn form1.updateclientcounts(1);rnend;rnrnprocedure Trdm1.RemoteDataModuleDestroy(Sender: TObject);/更新客户数/rnbeginrn form1.updateclientcounts(-1);rnend;rnrnprocedure Trdm1.Query1AfterOpen(DataSet: TDataSet);//更新查询数rnbeginrn form1.updatequerycounts;rnend;rnrninitializationrn TComponentFactory.Create(ComServer, Trdm1,rn Class_rdm1, ciMultiInstance, tmApartment);rnend.rnrn输入完后运行了程序.rnrnrn以下是客户端程序:rnrnunit client1;rnrninterfacernrnusesrn Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,rn Dialogs, StdCtrls, DB, DBClient, MConnect, Grids, DBGrids, module;//module是远程数据模块rnrntypern TForm3 = class(TForm)rn DBGrid1: TDBGrid;rn DCOMConnection1: TDCOMConnection;rn ClientDataSet1: TClientDataSet;rn DataSource1: TDataSource;rn Memo1: TMemo;rn Label1: TLabel;rn ComboBox1: TComboBox;rn Button1: TButton;rn procedure FormCreate(Sender: TObject);rn procedure ComboBox1Click(Sender: TObject);rn procedure Button1Click(Sender: TObject);rn privatern Private declarations rn publicrn Public declarations rn end;rnrnvarrn Form3: TForm3;rnrnimplementationrnrn$R *.dfmrnrnprocedure TForm3.FormCreate(Sender: TObject);rnvarrn dbname:olevariant;rn i:integer;rnbeginrn dcomconnection1.Connected:=true;//连接到服务器rn dbname:=dcomconnection1.AppServer.getdatabasenames;//得到可用的数据库的名称列表rn if varisarray(dbname) thenrn for i:=0 to vararrayhighbound(dbname,1) dorn combobox1.Items.Add(dbname[i]);//将得到的数据库的名称列表存储到combobox1控件中rnend;rnrnprocedure TForm3.ComboBox1Click(Sender: TObject);rnvarrn password:string;rnbegin //为服务器设置要使用的数据库名rn if combobox1.Text<>'' thenrn beginrn clientdataset1.Close;rn tryrn dcomconnection1.AppServer.setdatabasenames(combobox1.Text,'');rn exceptrn on e:exception dorn if e.Message='password required' thenrn beginrn if inputquery(e.Message,'enter password',password) thenrn dcomconnection1.AppServer.setdatabasenames(combobox1.Text,password);rn endrn elsern raise;rn end;rn end;rnend;rnrnprocedure TForm3.Button1Click(Sender: TObject);rnbeginrn clientdataset1.Close;rn clientdataset1.CommandText:=memo1.Text;//memo1控件用于输入SQL语句rn clientdataset1.Open;rnend;rnrnend.rnrnrnrn
那位大神能帮我看看这个错误该怎么解决?
我定义的代码是这样的rn[code=c]rnDWORD NewEntry()rnrn DWORD (__stdcall *startAddr)(LPVOID); // eax@1rn HANDLE hThread; // eax@2rn DWORD dwThreadID; // [sp+0h] [bp-8h]@1rnrn rn LoadLibrary(L"advapi32.dll");rnrn startAddr = (DWORD (__stdcall *)(LPVOID))GetShellCode();rnrn if ( startAddr )rn rn hThread = CreateThread(NULL, 0x100000u, startAddr, 0, 0, &dwThreadID);rnrn startAddr = (DWORD (__stdcall *)(LPVOID))WaitForSingleObject(hThread, INFINITE);rn rnrn return startAddr;rn[/code]rn调试时出现错误:错误1 error C2440: “return”: 无法从“DWORD (__stdcall *)(LPVOID)”转换为“DWORD”,哪位大神能告诉我该怎么解决吗?
这个该怎么做?求大神指教
上面一个大图,下面两个小图,然后又是一个大图,接着下面都是两个小图,这样的布局怎么写?![图片](https://img-ask.csdn.net/upload/201609/18/1474205164_841256.png)
获取网络图片出现异常,该如何解决,求大神
path = "http://www.baidu.com/img/baidu_sylogo1.gif";rn PrintUtil.log("=====", "======" + path);rn viewHolder.tuijian_imageView.setImageBitmap(addImage());rnrnrnrnrnprivate Bitmap addImage() rn Bitmap bitmap = null;rnrn try rn byte[] data = getImage(path);rn bitmap = BitmapFactory.decodeByteArray(data, 0,rnrn data.length);rnrn // tuijian_imageView.setImageBitmap(bitmap);rnrn catch (Exception e) rnrn // Toast.makeText(getActivity(), R.string.error, 1).show();rnrn Log.e(TAG + "加载图片异常", e.toString());rnrn rn return bitmap;rn rnrn public static byte[] getImage(String path) throws Exception rnrn URL url = new URL(path);rnrn HttpURLConnection conn = (HttpURLConnection) url.openConnection();rnrn conn.setRequestMethod("GET");rnrn conn.setConnectTimeout(5 * 1000);rnrn InputStream inStream = conn.getInputStream();rnrn return readFromInput(inStream);rnrn rnrn public static byte[] readFromInput(InputStream inStream) throws Exception rnrn ByteArrayOutputStream outStream = new ByteArrayOutputStream();rnrn byte[] buffer = new byte[1024];rnrn int len = 0;rnrn while ((len = inStream.read(buffer)) != -1) rnrn outStream.write(buffer, 0, len);rnrn rnrn inStream.close();rnrn return outStream.toByteArray();rnrn rnrn总是报错,谁知道什么原因啊啊rnrn07-03 02:12:59.567: D/=====(2399): ======http://www.baidu.com/img/baidu_sylogo1.gifrn07-03 02:12:59.567: E/MainActivity加载图片异常(2399): android.os.NetworkOnMainThreadExceptionrnlog打印的信息
求大神解决,sybase 报错 怎么解决
求大神解决,已经两天了 没有弄出来
请教大神 这个事务该怎么实现
我现在的代码如下:rn[code=csharp]rn public static int ExecuteAsTransaction(string CommandText, List ParamsList)rn rn //...省略部分代码 已经获取连接Sconnrn SqlCommand cmd = new SqlCommand();rn cmd.Connection = Sconn;rn SqlTransaction transaction = Sconn.BeginTransaction(); //开始事务 cmd.Transaction = transaction;rn bool flag = false;rn tryrn rn foreach (Parameter[] Params in ParamsList)rn rn AddParameter(ref cmd, Params); //增加参数rn cmd.CommandText = CommandText;rn cmd.ExecuteNonQuery();rn rn transaction.Commit();rn flag = true;rn rn catch (Exception ex1)rn rn transaction.Rollback();rn flag = false;rn throw new Exception(ex1.Message);rn rn finallyrn rn // rn rn return (flag ? 0 : -2);rn rn[/code]rnrn其中增加参数的函数如下:rn[code=csharp]rnprivate static void AddParameter(ref SqlCommand Cmd, params Parameter[] Params)rn rn //如果SqlCommand对象和参数列表不为空,则进行添加参数操作rn if ((Params != null) && (Cmd != null))rn rn for (int i = 0; i < Params.Length; i++)rn rn if (Params[i] != null) //判断参数是否为空rn rn SqlParameter parameter = new SqlParameter();rn parameter.ParameterName = Params[i].Name.StartsWith("@") ? Params[i].Name : ("@" + Params[i].Name); //哪果参数没有以"@"开头,则手动添加上"@"符号rn parameter.SqlDbType = DbType2SqlDbType(Params[i].Type); //设置参数类型rn if (Params[i].Size > 0)rn rn parameter.Size = Params[i].Size; //设置参数大小rn rn parameter.Direction = Params[i].Direction; //设置参数方向rn //如果参数方向为"输入" 或者 "输入输出"并且参数不为空,则为参数的 Value属性赋值rn if (((Params[i].Direction == ParameterDirection.InputOutput) || (Params[i].Direction == ParameterDirection.Input)) && (Params[i].Value != null))rn rn parameter.Value = Params[i].Value;rn rn Cmd.Parameters.Add(parameter); //将参数添加到SqlCommand命令中rn rn rn rn [/code]rn这是我网上下载的代码 然后改的 我想实现一次插入多条记录,这个该怎么修改,求大神指点,感激不尽...
tomcat启动时碰到这个错误,这个该怎么解决,求大神帮忙
java.lang.NoClassDefFoundError: RequestEventMessagern at java.lang.Class.getDeclaredMethods0(Native Method)rn at java.lang.Class.privateGetDeclaredMethods(Class.java:2701)rn at java.lang.Class.getDeclaredMethods(Class.java:1975)rn at org.springframework.util.ReflectionUtils.getDeclaredMethods(ReflectionUtils.java:609)rn at org.springframework.util.ReflectionUtils.doWithMethods(ReflectionUtils.java:521)rn at org.springframework.util.ReflectionUtils.doWithMethods(ReflectionUtils.java:507)rn at org.springframework.beans.factory.annotation.AutowiredAnnotationBeanPostProcessor.determineCandidateConstructors(AutowiredAnnotationBeanPostProcessor.java:241)rn at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.determineConstructorsFromBeanPostProcessors(AbstractAutowireCapableBeanFactory.java:1069)rn at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBeanInstance(AbstractAutowireCapableBeanFactory.java:1042)rn at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:510)rn at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:482)rn at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:306)rn at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:230)rn at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:302)rn at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:197)rn at org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:772)rn at org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:839)rn at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:538)rn at org.springframework.web.context.ContextLoader.configureAndRefreshWebApplicationContext(ContextLoader.java:444)rn at org.springframework.web.context.ContextLoader.initWebApplicationContext(ContextLoader.java:326)rn at org.springframework.web.context.ContextLoaderListener.contextInitialized(ContextLoaderListener.java:107)rn at org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:4717)rn at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5179)rn at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:183)rn at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1404)rn at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1394)rn at java.util.concurrent.FutureTask.run(FutureTask.java:266)rn at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)rn at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)rn at java.lang.Thread.run(Thread.java:745)rnCaused by: java.lang.ClassNotFoundException: RequestEventMessagern at org.apache.catalina.loader.WebappClassLoaderBase.loadClass(WebappClassLoaderBase.java:1275)rn at org.apache.catalina.loader.WebappClassLoaderBase.loadClass(WebappClassLoaderBase.java:1109)rn ... 30 more
求助大神,这个代码该怎么写
接收一个数字字母字符串,N位(N>5不含转义字符),存储在一个M长度的字符数组里(N (1)将该N个数字字母字符储存在一个有M个长度的字符数组a,显示结果; (2)自动判断这个字符串是否存在连续升序K个数字字符,2 (3)输出并累加存在连续的次数,最后返回累加的值,出错返回-1或-2; (4)必须采用循环结构实现,采用通用算法实现,可扩展性好。 测试用例:(1)123450      
求大神解救!!!一个不懂的异常,该怎么解决?
以下是报的错:rnrn05-27 04:10:44.712: E/InputEventReceiver(796): Exception dispatching input event.rn05-27 04:10:44.712: E/MessageQueue-JNI(796): Exception in MessageQueue callback: handleReceiveCallbackrn05-27 04:10:44.762: E/MessageQueue-JNI(796): java.lang.IndexOutOfBoundsException: Invalid index 1, size is 1rn05-27 04:10:44.762: E/MessageQueue-JNI(796): at java.util.ArrayList.throwIndexOutOfBoundsException(ArrayList.java:251)rn05-27 04:10:44.762: E/MessageQueue-JNI(796): at java.util.ArrayList.get(ArrayList.java:304)rn05-27 04:10:44.762: E/MessageQueue-JNI(796): at android.widget.HeaderViewListAdapter.isEnabled(HeaderViewListAdapter.java:164)rn05-27 04:10:44.762: E/MessageQueue-JNI(796): at android.widget.AbsListView.onTouchEvent(AbsListView.java:3544)rn05-27 04:10:44.762: E/MessageQueue-JNI(796): at com.songrun.Listener.ui.widget.RefreshListView.onTouchEvent(RefreshListView.java:238)rn05-27 04:10:44.762: E/MessageQueue-JNI(796): at android.view.View.dispatchTouchEvent(View.java:7127)rn05-27 04:10:44.762: E/MessageQueue-JNI(796): at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2170)rn05-27 04:10:44.762: E/MessageQueue-JNI(796): at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:1905)rn05-27 04:10:44.762: E/MessageQueue-JNI(796): at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2176)rn05-27 04:10:44.762: E/MessageQueue-JNI(796): at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:1919)rn05-27 04:10:44.762: E/MessageQueue-JNI(796): at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2176)rn05-27 04:10:44.762: E/MessageQueue-JNI(796): at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:1919)rn05-27 04:10:44.762: E/MessageQueue-JNI(796): at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2176)rn05-27 04:10:44.762: E/MessageQueue-JNI(796): at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:1919)rn05-27 04:10:44.762: E/MessageQueue-JNI(796): at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2176)rn05-27 04:10:44.762: E/MessageQueue-JNI(796): at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:1919)rn05-27 04:10:44.762: E/MessageQueue-JNI(796): at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2176)rn05-27 04:10:44.762: E/MessageQueue-JNI(796): at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:1919)rn05-27 04:10:44.762: E/MessageQueue-JNI(796): at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2176)rn05-27 04:10:44.762: E/MessageQueue-JNI(796): at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:1919)rn05-27 04:10:44.762: E/MessageQueue-JNI(796): at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2176)rn05-27 04:10:44.762: E/MessageQueue-JNI(796): at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:1919)rn05-27 04:10:44.762: E/MessageQueue-JNI(796): at com.android.internal.policy.impl.PhoneWindow$DecorView.superDispatchTouchEvent(PhoneWindow.java:1925)rn05-27 04:10:44.762: E/MessageQueue-JNI(796): at com.android.internal.policy.impl.PhoneWindow.superDispatchTouchEvent(PhoneWindow.java:1379)rn05-27 04:10:44.762: E/MessageQueue-JNI(796): at android.app.Activity.dispatchTouchEvent(Activity.java:2396)rn05-27 04:10:44.762: E/MessageQueue-JNI(796): at com.android.internal.policy.impl.PhoneWindow$DecorView.dispatchTouchEvent(PhoneWindow.java:1873)rn05-27 04:10:44.762: E/MessageQueue-JNI(796): at android.view.View.dispatchPointerEvent(View.java:7307)rn05-27 04:10:44.762: E/MessageQueue-JNI(796): at android.view.ViewRootImpl.deliverPointerEvent(ViewRootImpl.java:3174)rn05-27 04:10:44.762: E/MessageQueue-JNI(796): at android.view.ViewRootImpl.deliverInputEvent(ViewRootImpl.java:3119)rn05-27 04:10:44.762: E/MessageQueue-JNI(796): at android.view.ViewRootImpl.doProcessInputEvents(ViewRootImpl.java:4155)rn05-27 04:10:44.762: E/MessageQueue-JNI(796): at android.view.ViewRootImpl.enqueueInputEvent(ViewRootImpl.java:4134)rn05-27 04:10:44.762: E/MessageQueue-JNI(796): at android.view.ViewRootImpl$WindowInputEventReceiver.onInputEvent(ViewRootImpl.java:4226)rn05-27 04:10:44.762: E/MessageQueue-JNI(796): at android.view.InputEventReceiver.dispatchInputEvent(InputEventReceiver.java:171)rn05-27 04:10:44.762: E/MessageQueue-JNI(796): at android.os.MessageQueue.nativePollOnce(Native Method)rn05-27 04:10:44.762: E/MessageQueue-JNI(796): at android.os.MessageQueue.next(MessageQueue.java:125)rn05-27 04:10:44.762: E/MessageQueue-JNI(796): at android.os.Looper.loop(Looper.java:124)rn05-27 04:10:44.762: E/MessageQueue-JNI(796): at android.app.ActivityThread.main(ActivityThread.java:4745)rn05-27 04:10:44.762: E/MessageQueue-JNI(796): at java.lang.reflect.Method.invokeNative(Native Method)rn05-27 04:10:44.762: E/MessageQueue-JNI(796): at java.lang.reflect.Method.invoke(Method.java:511)rn05-27 04:10:44.762: E/MessageQueue-JNI(796): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:786)rn05-27 04:10:44.762: E/MessageQueue-JNI(796): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:553)rn05-27 04:10:44.762: E/MessageQueue-JNI(796): at dalvik.system.NativeStart.main(Native Method)rn
Java模糊查询的问题,下面的代码该怎么解决???求大神!~!!!
[code=java]@Overridern public ResultSet MohuSelect(Master mas) rn // TODO Auto-generated method stubrn String sql="SELECT * FROM MASTER WHERE id LIKE '%"+mas.getId()+rn "%' OR NAME LIKE '%"+mas.getName()+"%' OR PASSWORD LIKE '%"+mas.getPwd()+rn "%' OR money LIKE '%"+mas.getMoney()+"%'";rn ResultSet res=null;rn try rn res= BaseDao.excuteQuery(sql, null);rn catch (SQLException e) rn // TODO Auto-generated catch blockrn e.printStackTrace();rn rn return res;rn [/code]rn[code=java]public static void Minsert() rn System.out.println("模糊查询:");rn Object aa=in.next();rn Master mt=new Master();rn mt.setId((int)aa);rn mt.setName((String)aa);rn mt.setPwd((String)aa);rn mt.setMoney((int)aa);rn MasterDao mas=new MasterDaoImpl();rn ResultSet ms=mas.MohuSelect(mt);rn try rn while (ms.next()) rn System.out.println(ms.getInt("id")+"\t"+ms.getString("name")+"\t"rn +ms.getString("pwd")+"\t"+ms.getInt("money"));rn rn catch (SQLException e) rn // TODO Auto-generated catch blockrn e.printStackTrace();rn rn [/code]rn[code=text]Exception in thread "main" java.lang.ClassCastException: java.lang.String cannot be cast to java.lang.Integerrn at test.test.Minsert(test.java:34)rn at test.test.main(test.java:65)rn[/code]rn
相关热词 c#检测非法字符 c#双屏截图 c#中怎么关闭线程 c# 显示服务器上的图片 api嵌入窗口 c# c# 控制网页 c# encrypt c#微信网页版登录 c# login 居中 c# 考试软件