开发者

My embedded resource has mysteriously vanished from the assembly, vb.net vs2010

开发者_运维百科

I have an application that has a .sql file in it. The sql file is set to Embedded Resource. When I run the following code, I get an empty string array indicating there are no embedded resources.

However this project has been working fine previously.

Any ideas?

Dim p As String() = Assembly.GetExecutingAssembly().GetManifestResourceNames()


Try this:

Dim names as String() = Assembly.GetAssembly(typeof(<any type name of current assembly>)).GetManifestResourceNames()


Figures. I tried various things, then rebuilt / built my solution after each one, but it wasn't until I specifically selected Clean Solution that the problem was fixed.

I guess this is a quirk of our 2010 release which still hasn't been updated to RC.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜