मैं स्नैरल को सूचनाएं भेजने के लिए Snarl C# API का उपयोग कर रहा हूं।मुझे त्रुटि क्यों मिल रही है CS0246: प्रकार या नामस्थान नाम नहीं मिला?
अब मैं SnarlNetwork.cs
नामक फ़ाइल में ऊपर यूआरएल की सामग्री और मेरी test.cs
फ़ाइल की सामग्री बचाया है कर रहे हैं:
using SnarlNetworkProtocol;
using System;
class test
{
public static void Main(String[] args)
{
SNP snarl_object = new SNP();
string hostname = "localhost";
string hostport = "9887";
string appName = "Spotify";
bool val = snarl_object.register(hostname, hostport, appName);
if (val == true)
{
string title = "hello";
string message = "world";
string timeout = "5";
bool newval = snarl_object.notify(hostname, hostport, appName, null, title, message, timeout);
if (newval == true)
{
Console.WriteLine("sucessfull");
}
}
}
}
अब जब मैं का उपयोग कर csc test.cs
मैं मेरी test.cs फ़ाइल संकलन करने की कोशिश निम्न त्रुटि:
C:\Users\Noob\csharp>csc test.cs
Microsoft (R) Visual C# 2008 Compiler version 3.5.30729.4926
for Microsoft (R) .NET Framework version 3.5
Copyright (C) Microsoft Corporation. All rights reserved.
test.cs(1,7): error CS0246: The type or namespace name 'SnarlNetworkProtocol' could not be found (are you missing a using directive or an assembly reference?)
तो, क्या मैं गलत यहाँ कर रहा हूँ क्योंकि मेरे हिसाब से मैं किसी भी using directive
लापता नहीं कर रहा हूँ।
धन्यवाद। इसने काम कर दिया। – RanRag
उत्तर के रूप में चिह्नित करें? –
@ जेम्सस्ड: मैं लेकिन स्टैक ओवरफ्लो कहूंगा, 'आप 2 मिनट में जवाब स्वीकार कर सकते हैं' – RanRag