Hack Forums
[.NET] CodeDom Compiling Errors - Printable Version

+- Hack Forums (https://hackforums.net)
+-- Forum: Tech (https://hackforums.net/forumdisplay.php?fid=444)
+--- Forum: Coding (https://hackforums.net/forumdisplay.php?fid=151)
+---- Forum: Software Development (https://hackforums.net/forumdisplay.php?fid=118)
+---- Thread: [.NET] CodeDom Compiling Errors (/showthread.php?tid=2817747)



CodeDom Compiling Errors - Percocet - Aug 28, 2012

OK, so it's not because the strings are too long, I've already split them before I tried to compile it...

Now, when I try to compile it gives me some error messageboxes...

One says this:

"Error: Variable declaration without an 'As' clause; type of Object assumed."

Then I get one that says:

"Error: Name 'Process' is not declared."

That one is kind of simple but I still can't remember what to do to fix it...

Now, I get like 10 of these error messages:

"Error: 'Windows' is not a member of 'System.Environment.SpecialFolder'."

That one I can't seem to figure out, because in the console application I used to fix errors it didn't give me any problems. If you actually type it out, there is an option for 'Windows' in SpecialFolder, so I don't know why it's throwing this error.


So, please help... I know some problems are simple for you but I never really deeply studied the namespaces.


* - tweety - Aug 28, 2012

In your original stub's .sln, at the top turn option strict on. For the as clause you need to declare a function like this:

PHP Code

<?php 
Private Shared Function DoStuff(Byval DoingThings As Boolean) As Boolean 

For the process, you need to import/reference it in. I believe codedom compiles with strict on I think and uses old methods, however do not quote me on this.


* - Percocet - Aug 28, 2012

OK, the process error is gone, now I'm just left with the other 2.

And @Tweetie - I can't do that because I'm using CodeDom to compile it from a resource text file. Basically my crypter will need nothing, because it just builds from resources...


* - tweety - Aug 28, 2012

(Aug 28, 2012 07:32 AM)๖ۣۜExample Wrote:  OK, the process error is gone, now I'm just left with the other 2.

And @Tweetie - I can't do that because I'm using CodeDom to compile it from a resource text file. Basically my crypter will need nothing, because it just builds from resources...

I meant copy and paste your stub source into an IDE so you have Intellisense as well as Syntax highlighting. The other two can be fixed by adding in 'As [Insert Data type here]' at the end of each function declaration.


* - Percocet - Aug 28, 2012

(Aug 28, 2012 07:41 AM)Tweetie Wrote:  I meant copy and paste your stub source into an IDE so you have Intellisense as well as Syntax highlighting. The other two can be fixed by adding in 'As [Insert Data type here]' at the end of each function declaration.

Sorry... I'm really tired right now and only got key parts of your post...

All my functions have that at the end...


* - tweety - Aug 28, 2012

(Aug 28, 2012 07:43 AM)๖ۣۜExample Wrote:  Sorry... I'm really tired right now and only got key parts of your post...

All my functions have that at the end...

What are the other error's you are facing? I understand you are tired so just PM me your TV and I can help you while you kick back, get a drink, cup of coffee maybe and some snacks :)

EDIT: May I request for you to remove your stub code? I dislike people leaching and it will protect your stub.


* - Percocet - Aug 28, 2012

(Aug 28, 2012 07:48 AM)Tweetie Wrote:  What are the other error's you are facing? I understand you are tired so just PM me your TV and I can help you while you kick back, get a drink, cup of coffee maybe and some snacks :)

PMing you in a sec.

And it's only the two messageboxes now...

The "Error: Variable declaration without an 'As' clause; type of Object assumed." one and the "Error: 'Windows' is not a member of 'System.Environment.SpecialFolder'." one.


* - tweety - Aug 28, 2012

(Aug 28, 2012 07:49 AM)๖ۣۜExample Wrote:  PMing you in a sec.

And it's only the two messageboxes now...

The "Error: Variable declaration without an 'As' clause; type of Object assumed." one and the "Error: 'Windows' is not a member of 'System.Environment.SpecialFolder'." one.

Just waiting for your PM now, I think I know why it's throwing the errors.


* - MĨĿÃň97 - Aug 28, 2012

Download this: https://hackforums.net/showthread.php?tid=2794844
Copy / Paste code from CodeDom source... You will see where is error...


* - Support. - Aug 28, 2012

(Aug 28, 2012 07:49 AM)๖ۣۜExample Wrote:  PMing you in a sec.

And it's only the two messageboxes now...

The "Error: Variable declaration without an 'As' clause; type of Object assumed." one and the "Error: 'Windows' is not a member of 'System.Environment.SpecialFolder'." one.

When using Codedom, if your using a loop like

for X% =1 to whatever, you have to declare it fully. Like a real programming language. :P
For X as Integer = 1 to blahhhh

& The other is simple enough,